Page Menu
Home
Phabricator
Search
Configure Global Search
Log In
Files
F15310312
D10656.id25594.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Size
707 B
Referenced Files
None
Subscribers
None
D10656.id25594.diff
View Options
diff --git a/src/lint/linter/ArcanistXHPASTLinter.php b/src/lint/linter/ArcanistXHPASTLinter.php
--- a/src/lint/linter/ArcanistXHPASTLinter.php
+++ b/src/lint/linter/ArcanistXHPASTLinter.php
@@ -2553,6 +2553,11 @@
$keywords[] = head($invocation->getTokens());
}
+ $class_declarations = $root->selectDescendantsOfType('n_CLASS_DECLARATION');
+ foreach ($class_declarations as $declaration) {
+ $keywords[] = head($declaration->getTokens());
+ }
+
// NOTE: Although PHP generally allows arbitrary casing for all language
// keywords, it's exceedingly rare for anyone to type, e.g., "CLASS" or
// "cLaSs" in the wild. This list just attempts to cover unconventional
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Fri, Mar 7, 8:54 AM (2 w, 12 h ago)
Storage Engine
blob
Storage Format
Encrypted (AES-256-CBC)
Storage Handle
7328596
Default Alt Text
D10656.id25594.diff (707 B)
Attached To
Mode
D10656: Fix `LINT_KEYWORD_CASING` for `class` keyword
Attached
Detach File
Event Timeline
Log In to Comment