llvm-for-llvmta/tools/clang/test/SemaTemplate/member-inclass-init-value-d...

19 lines
224 B
C++
Raw Normal View History

2022-04-25 13:02:35 +02:00
// RUN: %clang_cc1 -emit-llvm-only %s
// PR10290
template<int Flags> struct foo {
int value = Flags && 0;
};
void test() {
foo<4> bar;
}
struct S {
S(int n);
};
template<typename> struct T {
S s = 0;
};
T<int> t;