From: Fariborz Jahanian Date: Fri, 29 Jun 2012 18:43:30 +0000 (+0000) Subject: objc diagnostic: pass IdentifierInfo* to the diagnostic system X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=20e7d992140cc6bc94f2e65f3638346527150756;p=clang objc diagnostic: pass IdentifierInfo* to the diagnostic system to produce quotes instead of adding qoute to the test. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@159450 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/include/clang/Basic/DiagnosticSemaKinds.td b/include/clang/Basic/DiagnosticSemaKinds.td index 0b3a8ed698..805c2dd088 100644 --- a/include/clang/Basic/DiagnosticSemaKinds.td +++ b/include/clang/Basic/DiagnosticSemaKinds.td @@ -635,8 +635,8 @@ def warn_auto_synthesizing_protocol_property :Warning< " declared in a protocol">, InGroup>; def warn_autosynthesis_property_ivar_match :Warning< - "autosynthesized property '%0' will use %select{|synthesized}1 instance variable " - "'%2', not existing instance variable '%3'">, + "autosynthesized property %0 will use %select{|synthesized}1 instance variable " + "%2, not existing instance variable %3">, InGroup>; def warn_missing_explicit_synthesis : Warning < "auto property synthesis is synthesizing property not explicitly synthesized">, diff --git a/lib/Sema/SemaObjCProperty.cpp b/lib/Sema/SemaObjCProperty.cpp index 1794f6618a..aace5ec11b 100644 --- a/lib/Sema/SemaObjCProperty.cpp +++ b/lib/Sema/SemaObjCProperty.cpp @@ -829,8 +829,8 @@ Decl *Sema::ActOnPropertyImplDecl(Scope *S, if (originalIvar) { Diag(PropertyDiagLoc, diag::warn_autosynthesis_property_ivar_match) - << property->getName() << (Ivar == 0) << PropertyIvar->getName() - << originalIvar->getName(); + << propertyId << (Ivar == 0) << PropertyIvar + << originalIvar->getIdentifier(); Diag(property->getLocation(), diag::note_property_declare); Diag(originalIvar->getLocation(), diag::note_ivar_decl); }