[clang] [clang] adds explanation for why std::is_const is false (PR #235587)
via cfe-commits
cfe-commits at lists.llvm.org
Thu Nov 5 17:03:53 PST 2026
================
@@ -895,15 +895,15 @@ static_assert(__is_abstract(U));
namespace is_const_tests {
-static_assert(__is_const(void()));
+static_assert(__is_const(const void()));
// expected-error at -1 {{static assertion failed due to requirement '__is_const(void ())'}} \
// expected-note at -1 {{'void ()' is not const}} \
----------------
NomaTyx wrote:
sigh, my bad for working really tired. I ran the tests without realizing that expected-note matches substrings, so a longer note will still pass. Not sure how this one escaped me though.
https://github.com/llvm/llvm-project/pull/235587
More information about the cfe-commits
mailing list