DescriptionStop using plain Arrays internally in built-in functions.
In built-in code we use arrays for internal computations.
This makes it possible to affect the built-in code by putting getters
or setters on the Array prototype chain.
This adds a new internal Array constructor that creates Arrays with
a very simplistic prototype chain that doesn't include any publicly
visible objects. These Arrays shoudl ofcourse never leak outside the
builtins, since that would expose the prototype object.
The prototype object contains only the array functions that we use:
push, pop and join (and not even a toString, so it doesn't stringify
well).
Also change uses of .call to %_CallFunction.
BUG=1206
Committed: http://code.google.com/p/v8/source/detail?r=7040
Patch Set 1 #Patch Set 2 : Changed implementation of ArrayMap to something hopefully a little faster. #
Total comments: 7
Patch Set 3 : Addressed review comments. #Patch Set 4 : Added toString. #Patch Set 5 : Changed header in bootstrapper.cc #
Messages
Total messages: 4 (0 generated)
|