Bug 123528 - Teach the style checker about ENUM_CLASS
Summary: Teach the style checker about ENUM_CLASS
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Tools / Tests (show other bugs)
Version: 528+ (Nightly build)
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Alexey Proskuryakov
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2013-10-30 13:47 PDT by Alexey Proskuryakov
Modified: 2013-10-30 21:09 PDT (History)
4 users (show)

See Also:


Attachments
proposed patch (6.29 KB, patch)
2013-10-30 16:25 PDT, Alexey Proskuryakov
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Alexey Proskuryakov 2013-10-30 13:47:35 PDT
Complaints in <https://bugs.webkit.org/show_bug.cgi?id=123462#c4> were wrong.
Comment 1 Alexey Proskuryakov 2013-10-30 16:25:22 PDT
Created attachment 215570 [details]
proposed patch
Comment 2 Andy Estes 2013-10-30 17:01:44 PDT
Comment on attachment 215570 [details]
proposed patch

View in context: https://bugs.webkit.org/attachment.cgi?id=215570&action=review

r=me

> Tools/Scripts/webkitpy/style/checkers/cpp.py:1196
> +        expr_enum_start = r'\s*(?:enum(?:\s+[a-zA-Z0-9]+)?|ENUM_CLASS\s*\([a-zA-Z0-9]+\))\s*\{?\s*'

Does the ([a-zA-Z0-9]+\) need to be non-capturing? Not sure it matters since only named groups are used.
Comment 3 Alexey Proskuryakov 2013-10-30 19:24:56 PDT
It's not a group - the parentheses are escaped :)
Comment 4 Andy Estes 2013-10-30 20:34:55 PDT
(In reply to comment #3)
> It's not a group - the parentheses are escaped :)

Indeed :/
Comment 5 WebKit Commit Bot 2013-10-30 21:09:20 PDT
Comment on attachment 215570 [details]
proposed patch

Clearing flags on attachment: 215570

Committed r158342: <http://trac.webkit.org/changeset/158342>
Comment 6 WebKit Commit Bot 2013-10-30 21:09:23 PDT
All reviewed patches have been landed.  Closing bug.