]> granicus.if.org Git - clang/commitdiff
Change the 'declared at' diagnostic to say 'declared here'.
authorAnders Carlsson <andersca@mac.com>
Fri, 23 Apr 2010 02:20:12 +0000 (02:20 +0000)
committerAnders Carlsson <andersca@mac.com>
Fri, 23 Apr 2010 02:20:12 +0000 (02:20 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@102163 91177308-0d34-0410-b5e6-96231b3b80d8

include/clang/Basic/DiagnosticSemaKinds.td
test/CXX/dcl.dcl/basic.namespace/namespace.udecl/p4.cpp
test/Sema/block-misc.c
test/SemaCXX/default-assignment-operator.cpp
test/SemaCXX/default-constructor-initializers.cpp
test/SemaCXX/illegal-member-initialization.cpp
test/SemaCXX/overloaded-operator.cpp
test/SemaCXX/value-initialization.cpp
test/SemaObjC/property-typecheck-1.m

index 945d046df5db4c70e8aca17a8e5a00b8bf5dbe03..04586f4a7ba535781c18a56f2edfe24e8ddd06f9 100644 (file)
@@ -297,7 +297,7 @@ def warn_implements_nscopying : Warning<
 def warn_multiple_method_decl : Warning<"multiple methods named %0 found">;
 def warn_accessor_property_type_mismatch : Warning<
   "type of property %0 does not match type of accessor %1">;
-def note_declared_at : Note<"declared at">;
+def note_declared_at : Note<"declared here">;
 def err_setter_type_void : Error<"type of setter must be void">;
 def err_duplicate_method_decl : Error<"duplicate declaration of method %0">;
 def warn_missing_atend : Warning<"'@end' is missing in implementation context">;
index 23da98ce7ee6dae87420f71c337e5595a828f4f5..a43d9e019ed334f00fb8ccdedb88923f114fc584 100644 (file)
@@ -166,7 +166,7 @@ namespace test3 {
 
   template <class T> struct C : A<T> {
     using typename A<T>::type;
-    using typename A<T>::hiding; // expected-note {{declared at}} \
+    using typename A<T>::hiding; // expected-note {{declared here}} \
                                  // expected-error {{'typename' keyword used on a non-type}}
     using typename A<T>::union_member; // expected-error {{'typename' keyword used on a non-type}}
     using typename A<T>::enumerator; // expected-error {{'typename' keyword used on a non-type}}
index accd4bac14708842a4254c16aa4b590c19772e11..92be5b1898489176a19bc6d97d0905e507dd5a99 100644 (file)
@@ -202,8 +202,8 @@ L0:
 // radr://7438948
 void test20() {
   int n = 7;
-  int vla[n]; // expected-note {{declared at}}
-  int (*vm)[n] = 0; // expected-note {{declared at}}
+  int vla[n]; // expected-note {{declared here}}
+  int (*vm)[n] = 0; // expected-note {{declared here}}
   vla[1] = 4341;
   ^{
     (void)vla[1];  // expected-error {{cannot refer to declaration with a variably modified type inside block}}
@@ -213,8 +213,8 @@ void test20() {
 
 // radr://7438948
 void test21() {
-  int a[7]; // expected-note {{declared at}}
-  __block int b[10]; // expected-note {{declared at}}
+  int a[7]; // expected-note {{declared here}}
+  __block int b[10]; // expected-note {{declared here}}
   a[1] = 1;
   ^{
     (void)a[1]; // expected-error {{cannot refer to declaration with an array type inside block}}
index d9cb6fc8e56ca85ce1657812d1bb44bf126ed704..81e7059257a734a3c6c7709b0a09ea78231bfe1c 100644 (file)
@@ -2,14 +2,14 @@
 
 class Base { // expected-error {{cannot define the implicit default assignment operator for 'Base', because non-static reference member 'ref' can't use default assignment operator}} \
   // expected-warning{{class 'Base' does not declare any constructor to initialize its non-modifiable members}}
-  int &ref;  // expected-note {{declared at}} \
+  int &ref;  // expected-note {{declared here}} \
   // expected-note{{reference member 'ref' will never be initialized}}
 };
 
 class X  : Base {  // // expected-error {{cannot define the implicit default assignment operator for 'X', because non-static const member 'cint' can't use default assignment operator}}
 public:
   X();
-  const int cint;  // expected-note {{declared at}}
+  const int cint;  // expected-note {{declared here}}
 }; 
 
 struct Y  : X { 
@@ -74,7 +74,7 @@ void i() {
 
 class E1 { // expected-error{{cannot define the implicit default assignment operator for 'E1', because non-static const member 'a' can't use default assignment operator}}
 public:
-  const int a; // expected-note{{declared at}}
+  const int a; // expected-note{{declared here}}
   E1() : a(0) {}  
 
 };
index b40b133a55412435966a58595f6f34475dd2c35b..757332df0b058056bcf663c506faa49422b50cd9 100644 (file)
@@ -16,7 +16,7 @@ X3 x3; // expected-note {{first required here}}
 struct X4 { // expected-error {{must explicitly initialize the member 'x2'}} \
             // expected-error {{must explicitly initialize the reference member 'rx2'}}
   X2 x2;       // expected-note {{member is declared here}}
-  X2 & rx2; // expected-note {{declared at}}
+  X2 & rx2; // expected-note {{declared here}}
 };
 
 X4 x4; // expected-note {{first required here}}
@@ -46,8 +46,8 @@ Y4 y4;
 
 struct Z1 { // expected-error {{must explicitly initialize the reference member 'z'}} \
             // expected-error {{must explicitly initialize the const member 'c1'}}
-  int& z;       // expected-note {{declared at}}
-  const int c1; // expected-note {{declared at}}
+  int& z;       // expected-note {{declared here}}
+  const int c1; // expected-note {{declared here}}
   volatile int v1;
 };
 
index 775f65194dc0a7c51a33f74599c1d1798502e9b1..87069efaacc7468d675bce84f7b5f6310a727b6b 100644 (file)
@@ -14,10 +14,10 @@ struct X {
                 // expected-error {{constructor for 'X' must explicitly initialize the const member 'cvalue'}} \
                 // expected-error {{constructor for 'X' must explicitly initialize the reference member 'b'}} \
                 // expected-error {{constructor for 'X' must explicitly initialize the const member 'cb'}}
-   int &value; // expected-note{{declared at}}
-   const int cvalue; // expected-note{{declared at}}
-   B& b; // expected-note{{declared at}}
-   const B cb; // expected-note{{declared at}}
+   int &value; // expected-note{{declared here}}
+   const int cvalue; // expected-note{{declared here}}
+   B& b; // expected-note{{declared here}}
+   const B cb; // expected-note{{declared here}}
 };
 
 
index 82f000b805de680f5a2fa86c1bbc3cc550f9b898..f9d341f3d116ed339f11ed7fd5712f2e5107075c 100644 (file)
@@ -259,7 +259,7 @@ bool x(BB y, BB z) { return y != z; }
 
 
 struct AX { 
-  AX& operator ->();    // expected-note {{declared at}}
+  AX& operator ->();    // expected-note {{declared here}}
   int b;
 }; 
 
@@ -269,14 +269,14 @@ void m() {
 }
 
 struct CircA {
-  struct CircB& operator->(); // expected-note {{declared at}}
+  struct CircB& operator->(); // expected-note {{declared here}}
   int val;
 };
 struct CircB {
-  struct CircC& operator->(); // expected-note {{declared at}}
+  struct CircC& operator->(); // expected-note {{declared here}}
 };
 struct CircC {
-  struct CircA& operator->(); // expected-note {{declared at}}
+  struct CircA& operator->(); // expected-note {{declared here}}
 };
 
 void circ() {
index 00bd1aaa40bd6efee572022d9a63f0c85ceff65f..10520fb8bba460531e4847db412a41b04993df72 100644 (file)
@@ -2,7 +2,7 @@
 
 struct A { // expected-error {{implicit default constructor for 'A' must explicitly initialize the const member 'i'}} \
   // expected-warning{{struct 'A' does not declare any constructor to initialize its non-modifiable members}}
-     const int i;      // expected-note {{declared at}} \
+     const int i;      // expected-note {{declared here}} \
   // expected-note{{const member 'i' will never be initialized}}
      virtual void f() { } 
 };
index fc53b590b8b27bed21f7220c2badee4697f44034..f86e047799917279bda7e3dea9d54079d085daf9 100644 (file)
@@ -1,7 +1,7 @@
 // RUN: %clang_cc1 -fsyntax-only -verify %s
 
 @interface A
--(float) x;    // expected-note {{declared at}}
+-(float) x;    // expected-note {{declared here}}
 @property int x; // expected-warning {{type of property 'x' does not match type of accessor 'x'}}
 @end
 
@@ -38,7 +38,7 @@ typedef void (F)(void);
 @class SSyncSet_iDisk;
 
 @interface SPeer_iDisk_remote1 : SPeer
-- (SSyncSet_iDisk*) syncSet; // expected-note {{declared at}}
+- (SSyncSet_iDisk*) syncSet; // expected-note {{declared here}}
 @end
 
 @interface SPeer_iDisk_local
@@ -76,7 +76,7 @@ typedef void (F)(void);
 @property (readonly) NSArray* pieces;  // expected-warning {{type of property 'pieces' does not match type of accessor 'pieces'}}
 @property (readonly) NSMutableArray* first; 
 
-- (NSMutableArray*) pieces; // expected-note {{declared at}} // expected-note {{declared at}}
+- (NSMutableArray*) pieces; // expected-note {{declared here}} // expected-note {{declared here}}
 - (NSArray*) first;
 @end