summaryrefslogtreecommitdiffstats
path: root/clang/test
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2008-11-23 22:46:27 +0000
committerChris Lattner <sabre@nondot.org>2008-11-23 22:46:27 +0000
commite6447ef98952cb38c8fcde42523406bb9dd7359a (patch)
tree2f3b9ecd22775030a38982c450b4a63b0655de93 /clang/test
parent88dcd2a1ab2f4cc87c7d4192f21c9323f5b3960c (diff)
downloadbcm5719-llvm-e6447ef98952cb38c8fcde42523406bb9dd7359a.tar.gz
bcm5719-llvm-e6447ef98952cb38c8fcde42523406bb9dd7359a.zip
make some objc redefinition warnings more consistent: call definitions
"definitions", not declarations. Point out the location of the original definition. llvm-svn: 59919
Diffstat (limited to 'clang/test')
-rw-r--r--clang/test/SemaObjC/alias-test-2.m4
-rw-r--r--clang/test/SemaObjC/check-dup-objc-decls-1.m8
-rw-r--r--clang/test/SemaObjC/class-def-test-1.m4
-rw-r--r--clang/test/SemaObjC/forward-class-1.m4
-rw-r--r--clang/test/SemaObjC/protocol-test-2.m4
-rw-r--r--clang/test/SemaObjC/undef-superclass-1.m4
6 files changed, 14 insertions, 14 deletions
diff --git a/clang/test/SemaObjC/alias-test-2.m b/clang/test/SemaObjC/alias-test-2.m
index 5f3bfcbba75..bdaeefe5a36 100644
--- a/clang/test/SemaObjC/alias-test-2.m
+++ b/clang/test/SemaObjC/alias-test-2.m
@@ -3,13 +3,13 @@
// Note: GCC doesn't produce any of the following errors.
@interface Super @end // expected-error {{previous definition is here}}
-@interface MyWpModule @end
+@interface MyWpModule @end // expected-note {{previous definition is here}}
@compatibility_alias MyAlias MyWpModule;
@compatibility_alias AliasForSuper Super;
-@interface MyAlias : AliasForSuper // expected-error {{duplicate interface declaration for class 'MyWpModule'}}
+@interface MyAlias : AliasForSuper // expected-error {{duplicate interface definition for class 'MyWpModule'}}
@end
@implementation MyAlias : AliasForSuper // expected-error {{conflicting super class name 'Super'}}
diff --git a/clang/test/SemaObjC/check-dup-objc-decls-1.m b/clang/test/SemaObjC/check-dup-objc-decls-1.m
index a634d0e6da4..28c6068afd0 100644
--- a/clang/test/SemaObjC/check-dup-objc-decls-1.m
+++ b/clang/test/SemaObjC/check-dup-objc-decls-1.m
@@ -29,11 +29,11 @@ void Gorf() // expected-error {{redefinition of 'Gorf' as different kind of symb
@protocol P -im1; @end
@protocol Q -im2; @end
-@interface A<P> @end
-@interface A<Q> @end // expected-error {{duplicate interface declaration for class 'A'}}
+@interface A<P> @end // expected-note {{previous definition is here}}
+@interface A<Q> @end // expected-error {{duplicate interface definition for class 'A'}}
-@protocol PP<P> @end
-@protocol PP<Q> @end // expected-error {{duplicate protocol declaration of 'PP'}}
+@protocol PP<P> @end // expected-note {{previous definition is here}}
+@protocol PP<Q> @end // expected-error {{duplicate protocol definition of 'PP'}}
@interface A(Cat)<P> @end // expected-note {{previous definition is here}}
@interface A(Cat)<Q> @end // expected-warning {{duplicate definition of category 'Cat' on interface 'A'}}
diff --git a/clang/test/SemaObjC/class-def-test-1.m b/clang/test/SemaObjC/class-def-test-1.m
index 3dc687b99a6..cf0ef53cae2 100644
--- a/clang/test/SemaObjC/class-def-test-1.m
+++ b/clang/test/SemaObjC/class-def-test-1.m
@@ -10,9 +10,9 @@ typedef int INTF; // expected-error {{previous definition is here}}
@interface OBJECT @end // expected-error {{previous definition is here}}
-@interface INTF1 : OBJECT @end
+@interface INTF1 : OBJECT @end // expected-note {{previous definition is here}}
-@interface INTF1 : OBJECT @end // expected-error {{duplicate interface declaration for class 'INTF1'}}
+@interface INTF1 : OBJECT @end // expected-error {{duplicate interface definition for class 'INTF1'}}
typedef int OBJECT; // expected-error {{previous definition is here}} \
expected-error {{redefinition of 'OBJECT' as different kind of symbol}}
diff --git a/clang/test/SemaObjC/forward-class-1.m b/clang/test/SemaObjC/forward-class-1.m
index 2b9369ba5f8..5eb36e704ae 100644
--- a/clang/test/SemaObjC/forward-class-1.m
+++ b/clang/test/SemaObjC/forward-class-1.m
@@ -14,11 +14,11 @@
@interface INTF1 : FOO
@end
-@interface INTF2 : INTF1
+@interface INTF2 : INTF1 // expected-note {{previous definition is here}}
@end
@class INTF1, INTF2;
-@interface INTF2 : INTF1 // expected-error {{duplicate interface declaration for class 'INTF2'}}
+@interface INTF2 : INTF1 // expected-error {{duplicate interface definition for class 'INTF2'}}
@end
diff --git a/clang/test/SemaObjC/protocol-test-2.m b/clang/test/SemaObjC/protocol-test-2.m
index 1a7fc9ce3cc..e5fff2da630 100644
--- a/clang/test/SemaObjC/protocol-test-2.m
+++ b/clang/test/SemaObjC/protocol-test-2.m
@@ -15,10 +15,10 @@
@protocol p1 @end
-@protocol PROTO<p1>
+@protocol PROTO<p1> // expected-note {{previous definition is here}}
@end
-@protocol PROTO<p1> // expected-error {{duplicate protocol declaration of 'PROTO'}}
+@protocol PROTO<p1> // expected-error {{duplicate protocol definition of 'PROTO'}}
@end
@protocol PROTO3<p1, p1>
diff --git a/clang/test/SemaObjC/undef-superclass-1.m b/clang/test/SemaObjC/undef-superclass-1.m
index 7e12463654f..ba233f8c4e6 100644
--- a/clang/test/SemaObjC/undef-superclass-1.m
+++ b/clang/test/SemaObjC/undef-superclass-1.m
@@ -7,7 +7,7 @@
@interface SUPER @end
-@interface INTF1 : SUPER
+@interface INTF1 : SUPER // expected-note {{previous definition is here}}
@end
@interface INTF2 : INTF1
@@ -16,7 +16,7 @@
@interface INTF3 : Y // expected-error {{cannot find interface declaration for 'Y', superclass of 'INTF3'}}
@end
-@interface INTF1 // expected-error {{duplicate interface declaration for class 'INTF1'}}
+@interface INTF1 // expected-error {{duplicate interface definition for class 'INTF1'}}
@end
@implementation SUPER
OpenPOWER on IntegriCloud