Bug 88954

Summary: Constant booleans in IDL files should not be cast to jsNumber
Product: WebKit Reporter: justinlin
Component: WebCore JavaScriptAssignee: Nobody <webkit-unassigned>
Status: UNCONFIRMED    
Severity: Normal CC: abarth, barraclough, code.vineet, haraken, japhet, jochen, webkit.review.bot
Priority: P3    
Version: 528+ (Nightly build)   
Hardware: Unspecified   
OS: Unspecified   
Attachments:
Description Flags
Patch
none
Patch darin: review-

justinlin
Reported 2012-06-12 21:36:37 PDT
The JS CodeGenerator casts const booleans specified in IDL files to jsNumber. It should not do that.
Attachments
Patch (1.60 KB, patch)
2012-06-15 23:48 PDT, justinlin
no flags
Patch (1.62 KB, patch)
2012-06-15 23:53 PDT, justinlin
darin: review-
justinlin
Comment 1 2012-06-15 23:48:01 PDT
WebKit Review Bot
Comment 2 2012-06-15 23:50:31 PDT
Attachment 147954 [details] did not pass style-queue: Failed to run "['Tools/Scripts/check-webkit-style', '--diff-files', u'Source/WebCore/ChangeLog', u'Source/WebCor..." exit_code: 1 Source/WebCore/ChangeLog:4: Line contains tab character. [whitespace/tab] [5] Total errors found: 1 in 2 files If any of these errors are false positives, please file a bug against check-webkit-style.
justinlin
Comment 3 2012-06-15 23:53:57 PDT
Darin Adler
Comment 4 2012-06-15 23:55:04 PDT
Comment on attachment 147956 [details] Patch Looks fine, but needs test coverage in run-bindings-tests.
Darin Adler
Comment 5 2012-06-15 23:55:27 PDT
Comment on attachment 147956 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=147956&action=review > Source/WebCore/bindings/scripts/CodeGeneratorJS.pm:2232 > + push(@implContent, " return jsBoolean(" . $constant->value . ");\n"); Needs UNUSED_PARAM for the same reason the jsNumber branch does.
Note You need to log in before you can comment on or make changes to this bug.