[PATCH] D51832: [clang-tidy/checks] Update objc-property-declaration check to allow arbitrary acronyms and initialisms 🔧
Ben Hamilton via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Mon Sep 10 08:16:36 PDT 2018
benhamilton accepted this revision.
benhamilton added a comment.
This revision is now accepted and ready to land.
This is fine, but please update the comments (and docs?) to make it clear that we no longer enforce camelCase but allow aRBiTraRYcAsE now.
================
Comment at: clang-tidy/objc/PropertyDeclarationCheck.cpp:28-31
// For StandardProperty the naming style is 'lowerCamelCase'.
// For CategoryProperty especially in categories of system class,
// to avoid naming conflict, the suggested naming style is
// 'abc_lowerCamelCase' (adding lowercase prefix followed by '_').
----------------
These comments are no longer accurate.
================
Comment at: clang-tidy/objc/PropertyDeclarationCheck.cpp:73-74
+ //
+ // Disallow names of this form:
+ // LongString
std::string StartMatcher = UsedInMatcher ? "::" : "^";
----------------
Just to be clear, this also allows things like aRbITRaRyCapS, right? We should comment that this is explicitly by design.
================
Comment at: clang-tidy/objc/PropertyDeclarationCheck.cpp:113-115
// the property name should be in Lower Camel Case like
// 'lowerCamelCase'
+ unless(matchesName(validPropertyNameRegex(true))))
----------------
This comment is no longer accurate.
Repository:
rCTE Clang Tools Extra
https://reviews.llvm.org/D51832
More information about the cfe-commits
mailing list