[cfe-commits] r80273 - in /cfe/trunk: lib/Sema/SemaDecl.cpp test/SemaTemplate/instantiate-friend-class.cpp
Eli Friedman
eli.friedman at gmail.com
Thu Aug 27 11:44:05 PDT 2009
Author: efriedma
Date: Thu Aug 27 13:44:04 2009
New Revision: 80273
URL: http://llvm.org/viewvc/llvm-project?rev=80273&view=rev
Log:
Back out bad piece of r80272. Will look at fixing this a different way.
Modified:
cfe/trunk/lib/Sema/SemaDecl.cpp
cfe/trunk/test/SemaTemplate/instantiate-friend-class.cpp
Modified: cfe/trunk/lib/Sema/SemaDecl.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Sema/SemaDecl.cpp?rev=80273&r1=80272&r2=80273&view=diff
==============================================================================
--- cfe/trunk/lib/Sema/SemaDecl.cpp (original)
+++ cfe/trunk/lib/Sema/SemaDecl.cpp Thu Aug 27 13:44:04 2009
@@ -4311,10 +4311,7 @@
New->setLexicalDeclContext(CurContext);
// Set the access specifier.
- // FIXME: This used to be skipped for friend tag decls, but it led to an
- // assertion in Decl::CheckAccessDeclContext(); once various issues with
- // friend class decls are sorted out, this should be revisited.
- if (!Invalid)
+ if (!Invalid && TUK != TUK_Friend)
SetMemberAccessSpecifier(New, PrevDecl, AS);
if (TUK == TUK_Definition)
Modified: cfe/trunk/test/SemaTemplate/instantiate-friend-class.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/test/SemaTemplate/instantiate-friend-class.cpp?rev=80273&r1=80272&r2=80273&view=diff
==============================================================================
--- cfe/trunk/test/SemaTemplate/instantiate-friend-class.cpp (original)
+++ cfe/trunk/test/SemaTemplate/instantiate-friend-class.cpp Thu Aug 27 13:44:04 2009
@@ -1,4 +1,6 @@
// RUN: clang-cc -fsyntax-only -verify %s
+// XFAIL
+// PR4794
template <class T> class X
{
More information about the cfe-commits
mailing list