[PATCH] D42464: add prefix with '_' support for property name. Corresponding apple dev doc: https://developer.apple.com/library/content/qa/qa1908/_index.html

2018-01-31 Thread Haojian Wu via Phabricator via cfe-commits
hokein added inline comments. Comment at: clang-tidy/objc/PropertyDeclarationCheck.cpp:115 + +bool prefixedPropertyNameMatches(const llvm::StringRef , + const std::vector ) { benhamilton wrote: > Wizard wrote: > > hokein wrote: >

[PATCH] D42464: add prefix with '_' support for property name. Corresponding apple dev doc: https://developer.apple.com/library/content/qa/qa1908/_index.html

2018-01-29 Thread Yan Zhang via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rCTE323722: add prefix with _ support for property name. Corresponding apple dev doc… (authored by Wizard, committed by ). Changed prior to commit: https://reviews.llvm.org/D42464?vs=131904=131907#toc

[PATCH] D42464: add prefix with '_' support for property name. Corresponding apple dev doc: https://developer.apple.com/library/content/qa/qa1908/_index.html

2018-01-29 Thread Yan Zhang via Phabricator via cfe-commits
Wizard updated this revision to Diff 131904. Wizard added a comment. merge changes and add EscapedAcronyms to store the actual acronyms during runtime. Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D42464 Files: clang-tidy/objc/PropertyDeclarationCheck.cpp

[PATCH] D42464: add prefix with '_' support for property name. Corresponding apple dev doc: https://developer.apple.com/library/content/qa/qa1908/_index.html

2018-01-29 Thread Ben Hamilton via Phabricator via cfe-commits
benhamilton accepted this revision. benhamilton added a comment. Thanks! Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D42464 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D42464: add prefix with '_' support for property name. Corresponding apple dev doc: https://developer.apple.com/library/content/qa/qa1908/_index.html

2018-01-29 Thread Yan Zhang via Phabricator via cfe-commits
Wizard updated this revision to Diff 131877. Wizard marked 2 inline comments as done. Wizard added a comment. add more tests Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D42464 Files: clang-tidy/objc/PropertyDeclarationCheck.cpp

[PATCH] D42464: add prefix with '_' support for property name. Corresponding apple dev doc: https://developer.apple.com/library/content/qa/qa1908/_index.html

2018-01-29 Thread Yan Zhang via Phabricator via cfe-commits
Wizard updated this revision to Diff 131869. Wizard added a comment. resolve comments and fix some logic Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D42464 Files: clang-tidy/objc/PropertyDeclarationCheck.cpp docs/clang-tidy/checks/objc-property-declaration.rst

[PATCH] D42464: add prefix with '_' support for property name. Corresponding apple dev doc: https://developer.apple.com/library/content/qa/qa1908/_index.html

2018-01-29 Thread Ben Hamilton via Phabricator via cfe-commits
benhamilton requested changes to this revision. benhamilton added inline comments. This revision now requires changes to proceed. Comment at: clang-tidy/objc/PropertyDeclarationCheck.cpp:115 + +bool prefixedPropertyNameMatches(const llvm::StringRef , +

[PATCH] D42464: add prefix with '_' support for property name. Corresponding apple dev doc: https://developer.apple.com/library/content/qa/qa1908/_index.html

2018-01-28 Thread Yan Zhang via Phabricator via cfe-commits
Wizard updated this revision to Diff 131741. Wizard added a comment. resolve comments Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D42464 Files: clang-tidy/objc/PropertyDeclarationCheck.cpp docs/clang-tidy/checks/objc-property-declaration.rst

[PATCH] D42464: add prefix with '_' support for property name. Corresponding apple dev doc: https://developer.apple.com/library/content/qa/qa1908/_index.html

2018-01-26 Thread Haojian Wu via Phabricator via cfe-commits
hokein added inline comments. Comment at: clang-tidy/objc/PropertyDeclarationCheck.cpp:115 + +bool prefixedPropertyNameMatches(const llvm::StringRef , + const std::vector ) { Wizard wrote: > hokein wrote: > > no need to pass const

[PATCH] D42464: add prefix with '_' support for property name. Corresponding apple dev doc: https://developer.apple.com/library/content/qa/qa1908/_index.html

2018-01-25 Thread Yan Zhang via Phabricator via cfe-commits
Wizard updated this revision to Diff 131511. Wizard marked 8 inline comments as done. Wizard added a comment. update some documents and comments Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D42464 Files: clang-tidy/objc/PropertyDeclarationCheck.cpp

[PATCH] D42464: add prefix with '_' support for property name. Corresponding apple dev doc: https://developer.apple.com/library/content/qa/qa1908/_index.html

2018-01-25 Thread Yan Zhang via Phabricator via cfe-commits
Wizard added inline comments. Comment at: clang-tidy/objc/PropertyDeclarationCheck.cpp:93 + [](const std::string ) { return llvm::Regex::escape(s); }); // Allow any of these names: // foo hokein wrote: > Does the comment still make sense?

[PATCH] D42464: add prefix with '_' support for property name. Corresponding apple dev doc: https://developer.apple.com/library/content/qa/qa1908/_index.html

2018-01-25 Thread Haojian Wu via Phabricator via cfe-commits
hokein added inline comments. Comment at: clang-tidy/objc/PropertyDeclarationCheck.cpp:28 +enum NamingStyle { + StandardProperty = 1, + CategoryProperty = 2, Please add documentation describing what these properties are. Comment at:

[PATCH] D42464: add prefix with '_' support for property name. Corresponding apple dev doc: https://developer.apple.com/library/content/qa/qa1908/_index.html

2018-01-24 Thread Yan Zhang via Phabricator via cfe-commits
Wizard marked 7 inline comments as done. Wizard added inline comments. Comment at: clang-tidy/objc/PropertyDeclarationCheck.cpp:120 + auto RegexExp = llvm::Regex( + llvm::StringRef(validPropertyNameRegex(Acronyms).replace(0, 2, "^"))); + return

[PATCH] D42464: add prefix with '_' support for property name. Corresponding apple dev doc: https://developer.apple.com/library/content/qa/qa1908/_index.html

2018-01-24 Thread Yan Zhang via Phabricator via cfe-commits
Wizard updated this revision to Diff 131368. Wizard marked an inline comment as done. Wizard added a comment. check for class extentsion Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D42464 Files: clang-tidy/objc/PropertyDeclarationCheck.cpp

[PATCH] D42464: add prefix with '_' support for property name. Corresponding apple dev doc: https://developer.apple.com/library/content/qa/qa1908/_index.html

2018-01-24 Thread Yan Zhang via Phabricator via cfe-commits
Wizard added inline comments. Comment at: clang-tidy/objc/PropertyDeclarationCheck.cpp:102 +bool hasCategoryPropertyPrefix(const llvm::StringRef ) { + for (size_t i = 0; i < PropertyName.size() - 1; ++i) { +if (PropertyName[i] == '_') { benhamilton wrote: >

[PATCH] D42464: add prefix with '_' support for property name. Corresponding apple dev doc: https://developer.apple.com/library/content/qa/qa1908/_index.html

2018-01-24 Thread Ben Hamilton via Phabricator via cfe-commits
benhamilton added inline comments. Comment at: clang-tidy/objc/PropertyDeclarationCheck.cpp:52 /// FIXME: provide fix for snake_case to snakeCase -FixItHint generateFixItHint(const ObjCPropertyDecl *Decl) { - if (isupper(Decl->getName()[0])) { -auto NewName =

[PATCH] D42464: add prefix with '_' support for property name. Corresponding apple dev doc: https://developer.apple.com/library/content/qa/qa1908/_index.html

2018-01-23 Thread Yan Zhang via Phabricator via cfe-commits
Wizard created this revision. Herald added subscribers: cfe-commits, klimek. Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D42464 Files: clang-tidy/objc/PropertyDeclarationCheck.cpp docs/clang-tidy/checks/objc-property-declaration.rst