| Index: src/messages.js
|
| diff --git a/src/messages.js b/src/messages.js
|
| index 4a8143e611162a447436ecb64aefb670e10c14fb..d07b54fda48ea249e5db8e437384f5a14e4e451a 100644
|
| --- a/src/messages.js
|
| +++ b/src/messages.js
|
| @@ -826,10 +826,12 @@ function CallSiteGetMethodName() {
|
| return ownName;
|
| }
|
| var name = null;
|
| - for (var prop in this.receiver) {
|
| + var property_names = %GetPropertyNamesNoSideEffect(this.receiver);
|
| + for (var i = 0; i < property_names.length; i++) {
|
| + var prop = property_names[i];
|
| if (%_CallFunction(this.receiver, prop, ObjectLookupGetter) === this.fun ||
|
| %_CallFunction(this.receiver, prop, ObjectLookupSetter) === this.fun ||
|
| - %GetDataProperty(this.receiver, prop) === this.fun) {
|
| + %GetDataProperty(this.receiver, TO_STRING_INLINE(prop)) === this.fun) {
|
| // If we find more than one match bail out to avoid confusion.
|
| if (name) {
|
| return null;
|
| @@ -1130,6 +1132,8 @@ function captureStackTrace(obj, cons_opt) {
|
| // The 'stack' property of the receiver is set as data property. If
|
| // the receiver is the same as holder, this accessor pair is replaced.
|
| var setter = function(v) {
|
| + // If the receiver is the holder, release the raw stack trace.
|
| + if (this == obj) stack = void 0;
|
| %DefineOrRedefineDataProperty(this, 'stack', v, NONE);
|
| };
|
|
|
| @@ -1282,11 +1286,11 @@ function SetUpStackOverflowBoilerplate() {
|
| holder = %GetPrototype(holder);
|
| if (holder == null) return MakeSyntaxError('illegal_access', []);
|
| }
|
| - var stack = %GetOverflowedStackTrace(holder);
|
| + var stack = %GetOverflowStackTrace(holder);
|
| if (IS_STRING(stack)) return stack;
|
| if (IS_ARRAY(stack)) {
|
| var result = FormatStackTrace(error_string, GetStackFrames(stack));
|
| - %SetOverflowedStackTrace(holder, result);
|
| + %SetOverflowStackTrace(holder, result);
|
| return result;
|
| }
|
| return void 0;
|
| @@ -1296,9 +1300,9 @@ function SetUpStackOverflowBoilerplate() {
|
| // The 'stack' property of the receiver is set as data property. If
|
| // the receiver is the same as holder, this accessor pair is replaced.
|
| function setter(v) {
|
| + // Attempt to release the overflow stack trace stored as hidden property.
|
| + if (IS_ERROR(this)) %SetOverflowStackTrace(this, void 0);
|
| %DefineOrRedefineDataProperty(this, 'stack', v, NONE);
|
| - // Release the stack trace that is stored as hidden property, if exists.
|
| - %SetOverflowedStackTrace(this, void 0);
|
| }
|
|
|
| %DefineOrRedefineAccessorProperty(
|
|
|