xref: /llvm-project/clang/test/Parser/gh30908-scope-balance-on-invalid-var-direct-init-2.cpp (revision 46944210ebd93765b068eeba22bd3e337099af3e)
1 // RUN: %clang_cc1 -fsyntax-only -verify %s
2 
3 #include <non-exist-header> // expected-error {{file not found}}
4 
5 class S {};
6 
7 template <typename T>
8 class E {
9 public:
E(S * scope)10   E(S* scope) {}
11   S &getS();
12 };
13 
14 class Z {
15  private:
16   static E<Z> e;
17   static S& s();
18 };
19 
20 E<Z> Z::e(&__UNKNOWN_ID__);
21 
s()22 S& Z::s() { return Z::e.getS(); }
23