[libcxx-commits] [libcxx] [libc++] Mostly Implement P1885R12: `<text_encoding>` (PR #141312)
Hristo Hristov via libcxx-commits
libcxx-commits at lists.llvm.org
Sat Nov 15 22:09:41 PST 2025
================
@@ -0,0 +1,31 @@
+//===----------------------------------------------------------------------===//
+//
+// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
+// See https://llvm.org/LICENSE.txt for license information.
+// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
+//
+//===----------------------------------------------------------------------===//
+
+// REQUIRES: std-at-least-c++26
+
+// UNSUPPORTED: no-localization
+
+// <text_encoding>
+
+#include <text_encoding>
+
+int main(int, char**) {
+ std::text_encoding te = std::text_encoding();
+ // expected-warning at +1 {{ignoring return value of function declared with 'nodiscard' attribute}}
----------------
H-G-Hristov wrote:
nodiscard tests are libc++ specific and should be placed in tests/libcxx
https://github.com/llvm/llvm-project/pull/141312
More information about the libcxx-commits
mailing list