Bug 77165

Summary: JSC idl code generator generates bad code for [CachedAttribute] attributes
Product: WebKit Reporter: Pablo Flouret <pf>
Component: New BugsAssignee: Nobody <webkit-unassigned>
Status: RESOLVED FIXED    
Severity: Normal CC: abarth, haraken, japhet, oliver, webkit.review.bot
Priority: P2    
Version: 528+ (Nightly build)   
Hardware: Unspecified   
OS: Unspecified   
Bug Depends on:    
Bug Blocks: 76035    
Attachments:
Description Flags
Patch none

Description Pablo Flouret 2012-01-26 17:22:51 PST
JSC idl code generator generates bad code for [CachedAttribute] attributes
Comment 1 Pablo Flouret 2012-01-26 17:29:03 PST
Created attachment 124223 [details]
Patch
Comment 2 Oliver Hunt 2012-01-26 17:44:50 PST
Comment on attachment 124223 [details]
Patch

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

> Source/WebCore/bindings/scripts/CodeGeneratorJS.pm:3000
> +        return "$value ? $value->deserialize(exec, castedThis->globalObject(), 0) : jsNull()";

what is the additional argument here for?
Comment 3 Pablo Flouret 2012-01-26 17:47:33 PST
(In reply to comment #2)
> (From update of attachment 124223 [details])
> View in context: https://bugs.webkit.org/attachment.cgi?id=124223&action=review
> 
> > Source/WebCore/bindings/scripts/CodeGeneratorJS.pm:3000
> > +        return "$value ? $value->deserialize(exec, castedThis->globalObject(), 0) : jsNull()";
> 
> what is the additional argument here for?

MessagePortArray*

MessageEvent (the only one declaring CachedAttributes so far) uses a custom getter, so i imagine that's why this has gone unnoticed.
Comment 4 WebKit Review Bot 2012-01-26 18:25:15 PST
Comment on attachment 124223 [details]
Patch

Clearing flags on attachment: 124223

Committed r106077: <http://trac.webkit.org/changeset/106077>
Comment 5 WebKit Review Bot 2012-01-26 18:25:19 PST
All reviewed patches have been landed.  Closing bug.