зеркало из https://github.com/microsoft/clang-1.git
When name lookup finds a module-private Objective-C class declaration,
check whether any previous declarations of the class were visible. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@146680 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Родитель
7723fec9b4
Коммит
d63348c338
|
@ -1063,6 +1063,8 @@ static NamedDecl *getPreviousDeclaration(NamedDecl *D) {
|
|||
return FD->getPreviousDeclaration();
|
||||
if (RedeclarableTemplateDecl *RTD = dyn_cast<RedeclarableTemplateDecl>(D))
|
||||
return RTD->getPreviousDeclaration();
|
||||
if (ObjCInterfaceDecl *ID = dyn_cast<ObjCInterfaceDecl>(D))
|
||||
return ID->getPreviousDeclaration();
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
|
|
@ -7,9 +7,7 @@ B *b1; // expected-error{{unknown type name 'B'}}
|
|||
|
||||
__import_module__ decldef.Decl;
|
||||
|
||||
// FIXME: No link between @interface (which we can't see) and @class
|
||||
// (which we can).
|
||||
// A *a2;
|
||||
A *a2;
|
||||
B *b;
|
||||
|
||||
void testB() {
|
||||
|
|
Загрузка…
Ссылка в новой задаче