Bug 32225 - [check-webkit-style] S_OK is a fine identifier
Summary: [check-webkit-style] S_OK is a fine identifier
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Tools / Tests (show other bugs)
Version: 528+ (Nightly build)
Hardware: All All
: P2 Normal
Assignee: Shinichiro Hamaji
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2009-12-07 09:14 PST by Adam Barth
Modified: 2009-12-07 21:59 PST (History)
2 users (show)

See Also:


Attachments
Patch v1 (2.15 KB, patch)
2009-12-07 21:15 PST, Shinichiro Hamaji
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Adam Barth 2009-12-07 09:14:41 PST
WebCore/platform/text/wince/TextCodecWince.cpp:125:  S_OK is incorrectly named.
Don't use underscores in your identifier names.  [readability/naming] [4]

https://bugs.webkit.org/show_bug.cgi?id=32169#c2

That's a false positive.
Comment 1 Shinichiro Hamaji 2009-12-07 21:15:39 PST
Created attachment 44458 [details]
Patch v1
Comment 2 WebKit Review Bot 2009-12-07 21:18:03 PST
style-queue ran check-webkit-style on attachment 44458 [details] without any errors.
Comment 3 Shinichiro Hamaji 2009-12-07 21:20:06 PST
This happened because the style checker considered it is the
declaration of S_OK.

if (mli && S_OK == mli->EnumCodePages(MIMECONTF_BROWSER, &enumInterface)) {

Note that we should warn about the following statement.

if (int & S_OK = intValue) {

My patch checks the character after the first '='.
Comment 4 Shinichiro Hamaji 2009-12-07 21:58:51 PST
Comment on attachment 44458 [details]
Patch v1

Clearing flags on attachment: 44458

Committed r51835: <http://trac.webkit.org/changeset/51835>
Comment 5 Shinichiro Hamaji 2009-12-07 21:59:00 PST
All reviewed patches have been landed.  Closing bug.