Bug 125732

Summary: Some Set and Map prototype functions have incorrect function lengths
Product: WebKit Reporter: Joseph Pecoraro <joepeck>
Component: JavaScriptCoreAssignee: Nobody <webkit-unassigned>
Severity: Normal CC: commit-queue, joepeck, oliver
Priority: P2    
Version: 528+ (Nightly build)   
Hardware: Unspecified   
OS: Unspecified   
Description Flags
[PATCH] Proposed Fix
[PATCH] Proposed Fix none

Description Joseph Pecoraro 2013-12-13 21:42:55 PST
Caught while reading through SetPrototype.cpp. Looks like a few of the prototype functions have an unexpected function length. `add` should be 1 since it takes a param, `clear` should be 0 since it doesn't take a param.
Comment 1 Joseph Pecoraro 2013-12-13 21:43:57 PST
Created attachment 219235 [details]
[PATCH] Proposed Fix
Comment 2 Joseph Pecoraro 2013-12-13 21:51:08 PST
Looking through JSC_NATIVE_FUNCTION calls, these are suspect as well:

67:    JSC_NATIVE_FUNCTION(vm.propertyNames->keys, mapProtoFuncKeys, DontEnum, 2);
68:    JSC_NATIVE_FUNCTION(vm.propertyNames->values, mapProtoFuncValues, DontEnum, 2);
69:    JSC_NATIVE_FUNCTION(vm.propertyNames->entries, mapProtoFuncEntries, DontEnum, 2);
70:    JSC_NATIVE_FUNCTION(vm.propertyNames->iteratorPrivateName, mapProtoFuncEntries, DontEnum, 2);

Should probably all be 0, eh? I'll address these as well.
Comment 3 Joseph Pecoraro 2013-12-13 22:02:27 PST
Created attachment 219236 [details]
[PATCH] Proposed Fix
Comment 4 WebKit Commit Bot 2013-12-13 23:50:36 PST
Comment on attachment 219236 [details]
[PATCH] Proposed Fix

Clearing flags on attachment: 219236

Committed r160592: <http://trac.webkit.org/changeset/160592>
Comment 5 WebKit Commit Bot 2013-12-13 23:50:38 PST
All reviewed patches have been landed.  Closing bug.