// RUN: %clang_cc1 -fsyntax-only -verify -Wno-objc-root-class %s
float Foo; // expected-error {{redefinition of 'Foo' as different kind of symbol}}
@class Bar; // expected-note {{previous definition is here}}
typedef int Bar; // expected-error {{redefinition of 'Bar' as different kind of symbol}}
typedef int OBJECT; // expected-note {{previous definition is here}}
@class OBJECT ; // expected-error {{redefinition of 'OBJECT' as different kind of symbol}}
typedef int Gorf; // expected-note {{previous definition is here}}
// expected-error {{redefinition of 'Gorf' as different kind of symbol}} expected-note {{previous definition is here}}
void
@protocol P -im1; @end
@protocol Q -im2; @end
// expected-note {{previous definition is here}}
// expected-error {{duplicate interface definition for class 'A'}}
// expected-note {{previous definition is here}}
// expected-warning {{duplicate protocol definition of 'PP'}}
// expected-note {{previous definition is here}}
// expected-warning {{duplicate definition of category 'Cat' on interface 'A'}}
// rdar 7626768
@class NSString;
NSString * TestBaz; // expected-note {{previous definition is here}}
NSString * const TestBaz; // expected-error {{redefinition of 'TestBaz' with a different type}}