Bug 89198

Summary: Web Inspector: too many hardcoded strings in InspectorBackendDispatcher.
Product: WebKit Reporter: Ilya Tikhonovsky <loislo>
Component: Web Inspector (Deprecated)Assignee: Nobody <webkit-unassigned>
Status: RESOLVED FIXED    
Severity: Normal CC: alph, apavlov, bweinstein, joepeck, keishi, loislo, pfeldman, pmuellr, prybin, rik, timothy, yurys
Priority: P2    
Version: 528+ (Nightly build)   
Hardware: All   
OS: All   
Attachments:
Description Flags
Patch
none
Patch yurys: review+

Description Ilya Tikhonovsky 2012-06-15 05:25:09 PDT
EOM
Comment 1 Peter Rybin 2012-07-05 16:19:19 PDT
Created attachment 150997 [details]
Patch
Comment 2 Yury Semikhatsky 2012-07-05 23:17:27 PDT
Comment on attachment 150997 [details]
Patch

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

> Source/WebCore/inspector/CodeGeneratorInspector.py:1981
> +        size_t length = ARRAY_SIZE(commandNames);

It should be WTF_ARRAY_LENGTH(commandNames), not sure why compiler didn't complain about it. Is ARRAY_SIZE defined somewhere in WebKit, I only see 2 places (http://code.google.com/p/chromium/source/search?q=define%5CsARRAY_SIZE+file%3AWebKit&origq=define%5CsARRAY_SIZE+file%3AWebKit&btnG=Search+Trunk), none of which should be visible here?
Comment 3 Peter Rybin 2012-07-13 03:37:25 PDT
Created attachment 152207 [details]
Patch
Comment 4 Peter Rybin 2012-07-13 03:44:06 PDT
Comment on attachment 150997 [details]
Patch

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

>> Source/WebCore/inspector/CodeGeneratorInspector.py:1981
>> +        size_t length = ARRAY_SIZE(commandNames);
> 
> It should be WTF_ARRAY_LENGTH(commandNames), not sure why compiler didn't complain about it. Is ARRAY_SIZE defined somewhere in WebKit, I only see 2 places (http://code.google.com/p/chromium/source/search?q=define%5CsARRAY_SIZE+file%3AWebKit&origq=define%5CsARRAY_SIZE+file%3AWebKit&btnG=Search+Trunk), none of which should be visible here?

Actually I made my own -- didn't know the right name for search. Replaced.
Comment 5 Ilya Tikhonovsky 2012-07-13 07:30:30 PDT
Committed r122574: <http://trac.webkit.org/changeset/122574>