From: Douglas Gregor Date: Wed, 14 Oct 2009 21:33:19 +0000 (+0000) Subject: Check the implicit instantiation of a static data member of a class X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=9ada570e77bdd8334a86528b07e5569d00750b3c;p=clang Check the implicit instantiation of a static data member of a class template that has no out-of-line definition. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@84141 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/test/CXX/temp/temp.spec/temp.explicit/p1-emit.cpp b/test/CXX/temp/temp.spec/temp.explicit/p1-emit.cpp index f2282a2395..3938509961 100644 --- a/test/CXX/temp/temp.spec/temp.explicit/p1-emit.cpp +++ b/test/CXX/temp/temp.spec/temp.explicit/p1-emit.cpp @@ -19,8 +19,11 @@ template int X::member1; template int X::member2; // For implicit instantiation of -long& get(bool Cond) { +long& get(bool Cond1, bool Cond2) { // CHECK: @_ZN1XIlE7member1E = weak global i64 0 // CHECK: @_ZN1XIlE7member2E = weak global i64 17 - return Cond? X::member1 : X::member2; -} \ No newline at end of file + // CHECK: @_ZN1XIlE7member3E = external global i64 + return Cond1? X::member1 + : Cond2? X::member2 + : X::member3; +}