diff options
author | Fariborz Jahanian <fjahanian@apple.com> | 2009-05-13 00:47:33 +0000 |
---|---|---|
committer | Fariborz Jahanian <fjahanian@apple.com> | 2009-05-13 00:47:33 +0000 |
commit | 09d04e5097034d8dfb9fcfceb457f6924cdd2417 (patch) | |
tree | 7aa9fffdbfb3de99c8194eccc23eed99ccb6bcf1 | |
parent | 93dfdb1299ef740df854f4a745dc87e5e43f0c30 (diff) |
Changed wording of warning when attribute is on
method definition.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@71615 91177308-0d34-0410-b5e6-96231b3b80d8
-rw-r--r-- | include/clang/Basic/DiagnosticSemaKinds.td | 2 | ||||
-rw-r--r-- | test/SemaObjC/attr-deprecated.m | 2 | ||||
-rw-r--r-- | test/SemaObjC/method-attributes.m | 4 |
3 files changed, 4 insertions, 4 deletions
diff --git a/include/clang/Basic/DiagnosticSemaKinds.td b/include/clang/Basic/DiagnosticSemaKinds.td index 466f5495eb..8cd5e42883 100644 --- a/include/clang/Basic/DiagnosticSemaKinds.td +++ b/include/clang/Basic/DiagnosticSemaKinds.td @@ -1732,7 +1732,7 @@ def error_private_ivar_access : Error<"instance variable %0 is private">; def error_protected_ivar_access : Error<"instance variable %0 is protected">; def warn_maynot_respond : Warning<"%0 may not respond to %1">; def warn_attribute_method_def : Warning< - "method attribute may be specified on method declarations only">; + "method attribute can only be specified on method declarations">; } diff --git a/test/SemaObjC/attr-deprecated.m b/test/SemaObjC/attr-deprecated.m index 3741510e11..e385a977f5 100644 --- a/test/SemaObjC/attr-deprecated.m +++ b/test/SemaObjC/attr-deprecated.m @@ -9,7 +9,7 @@ @implementation A + (void)F __attribute__((deprecated)) -{ // expected-warning {{method attribute may be specified on method declarations only}} +{ // expected-warning {{method attribute can only be specified on method declarations}} [self F]; // no warning, since the caller is also deprecated. } diff --git a/test/SemaObjC/method-attributes.m b/test/SemaObjC/method-attributes.m index 354950c49c..c4d4fba25d 100644 --- a/test/SemaObjC/method-attributes.m +++ b/test/SemaObjC/method-attributes.m @@ -19,13 +19,13 @@ @end @implementation INTF -- (int) foo: (int)arg1 __attribute__((deprecated)){ // expected-warning {{method attribute may be specified}} +- (int) foo: (int)arg1 __attribute__((deprecated)){ // expected-warning {{method attribute can only be specified}} return 10; } - (int) foo1: (int)arg1 { return 10; } -- (int) foo2: (int)arg1 __attribute__((deprecated)) { // expected-warning {{method attribute may be specified}} +- (int) foo2: (int)arg1 __attribute__((deprecated)) { // expected-warning {{method attribute can only be specified}} return 10; } @end |