Skip to content

Commit b557cd3

Browse files
authored
[clang][bytecode][NFC] Add a c++11 test case (#152104)
This test case breaks when ignoring trivial CXXConstructExprs of array types, so make sure we don't do that.
1 parent e0df5f8 commit b557cd3

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

clang/test/AST/ByteCode/cxx11.cpp

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -309,3 +309,12 @@ int somefunc() {
309309
// both-note {{reference to 'non_global' is not a constant expression}}
310310
}
311311

312+
namespace PR19010 {
313+
struct Empty {};
314+
struct Empty2 : Empty {};
315+
struct Test : Empty2 {
316+
constexpr Test() {}
317+
Empty2 array[2];
318+
};
319+
void test() { constexpr Test t; }
320+
}

0 commit comments

Comments
 (0)