Bug 52011 - JSC bindings should use RuntimeEnabledFeatures
Summary: JSC bindings should use RuntimeEnabledFeatures
Status: REOPENED
Alias: None
Product: WebKit
Classification: Unclassified
Component: WebCore JavaScript (show other bugs)
Version: 528+ (Nightly build)
Hardware: PC OS X 10.5
: P2 Enhancement
Assignee: Nobody
URL:
Keywords: InRadar
: 91199 (view as bug list)
Depends on: 116147
Blocks:
  Show dependency treegraph
 
Reported: 2011-01-06 12:58 PST by Joe Mason
Modified: 2013-05-15 09:35 PDT (History)
11 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Joe Mason 2011-01-06 12:58:37 PST
Only the V8 bindings generate code to enable/disable Javascript features that have the EnabledAtRuntime attribute, even though the RuntimeEnabledFeatures class is in bindings/generic so it's available to JSC.  This would allow attributes to be completely removed if they are disabled (simply returning "undefined" is not good enough because they will still be visible in iteration).

This needs at least:

- code added to CodeGeneratorJS.pm to parallel that in CodeGeneratorV8.pm that checks EnabledAtRuntime (or better yet move these checks 
into common helpers)
- possibly added to the other CodeGenerator scripts as well?
- existing uses of RuntimeEnabledFeatures that are wrapped in "#if USE(V8)" need to be audited to see if they should now be unconditional
- RuntimeEnabledFeatures needs to be added to the build for all platforms using JSC
Comment 1 David Kilzer (:ddkilzer) 2012-10-18 11:51:38 PDT
<rdar://problem/10155019>
Comment 2 Kent Tamura 2012-11-28 21:45:40 PST
*** Bug 91199 has been marked as a duplicate of this bug. ***
Comment 3 Ryosuke Niwa 2013-05-15 09:19:55 PDT

*** This bug has been marked as a duplicate of bug 116147 ***
Comment 4 Chris Dumez 2013-05-15 09:32:08 PDT
(In reply to comment #3)
> 
> *** This bug has been marked as a duplicate of bug 116147 ***

Actually, I think we can keep the other one open make add a dependency. My patch only adds support for global constructors. Work will still be needed to extend that to regular attributes and operations.
Comment 5 Ryosuke Niwa 2013-05-15 09:35:45 PDT
Okay.