"cannot find definition of 'Class'")
DIAG(warn_previous_alias_decl, WARNING,
"previously declared alias is ignored")
-DIAG(warn_previous_declaration, WARNING,
- "previous declaration is here")
DIAG(err_conflicting_aliasing_type, ERROR,
"conflicting types for alias %0")
DIAG(err_statically_allocated_object, ERROR,
// Look for previous declaration of alias name
Decl *ADecl = LookupDecl(AliasName, Decl::IDNS_Ordinary, TUScope);
if (ADecl) {
- if (isa<ObjCCompatibleAliasDecl>(ADecl)) {
+ if (isa<ObjCCompatibleAliasDecl>(ADecl))
Diag(AliasLocation, diag::warn_previous_alias_decl);
- Diag(ADecl->getLocation(), diag::warn_previous_declaration);
- }
- else {
+ else
Diag(AliasLocation, diag::err_conflicting_aliasing_type) << AliasName;
- Diag(ADecl->getLocation(), diag::note_previous_declaration);
- }
+ Diag(ADecl->getLocation(), diag::note_previous_declaration);
return 0;
}
// Check for class declaration
if (CDecl == 0) {
Diag(ClassLocation, diag::warn_undef_interface) << ClassName;
if (CDeclU)
- Diag(CDeclU->getLocation(), diag::warn_previous_declaration);
+ Diag(CDeclU->getLocation(), diag::note_previous_declaration);
return 0;
}
@class class2; // expected-note {{previous declaration is here}}
@class class3;
-typedef int I; // expected-warning {{previous declaration is here}}
+typedef int I; // expected-note {{previous declaration is here}}
@compatibility_alias alias1 I; // expected-warning {{cannot find interface declaration for 'I'}}