Debian Codegraph @

clang/test/SemaCXX/requires-nested-non-constant.cpp

raw
1 // RUN: %clang_cc1 -std=c++23 -fsyntax-only -verify %s
2
3 template <class C> class A {
4 void f() {
5 auto result = []() constexpr {
6 return requires (int x) { // expected-note {{declared here}}
7 requires (x > 0) && (x < 10); // expected-error {{substitution into constraint expression resulted in a non-constant expression}} \
8 // expected-note {{while checking the satisfaction of nested requirement requested here}} \
9 // expected-note {{function parameter 'x' with unknown value cannot be used in a constant expression}}
10 };
11 }();
12 }
13 };