[PATCH] D43581: [clang-tidy/google] Fix the Objective-C global variable declaration check 🔧

Stephane Moore via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Thu Feb 22 12:18:55 PST 2018


stephanemoore added a comment.

In https://reviews.llvm.org/D43581#1016327, @Wizard wrote:

> In https://reviews.llvm.org/D43581#1016318, @stephanemoore wrote:
>
> > In https://reviews.llvm.org/D43581#1016300, @Wizard wrote:
> >
> > > Please update the warning info to indicate that prefix 'k' is not the only option for constants. Something like:
> > >  "const global variable '%0' must have an appropriate prefix or a name which starts with 'k[A-Z]'"
> >
> >
> > Is the latest warning info satisfactory? I believe I updated it after adding you as a reviewer.
>
>
> Hmm I feel it is a bit unfriendly to show users a rather complicated regex in the info, but I will leave it to you. Not a big problem.


At a glance this seems unconventional but could we have the warning link to the Google Objective-C style guide for guidance on an appropriate prefix? Is that allowed for diagnostic messages? I can revert if that is considered inappropriate.


Repository:
  rCTE Clang Tools Extra

https://reviews.llvm.org/D43581





More information about the cfe-commits mailing list