Also check new_target_is_base() bit when comparing two maps for equivalence.

BUG=chromium:580506
LOG=N

Review URL: https://codereview.chromium.org/1631673002

Cr-Commit-Position: refs/heads/master@{#33497}
This commit is contained in:
ishell 2016-01-25 08:43:29 -08:00 committed by Commit bot
parent 03d59ca709
commit ac03ef02d6
3 changed files with 24 additions and 0 deletions

View File

@ -12250,6 +12250,7 @@ bool CheckEquivalent(Map* first, Map* second) {
first->bit_field() == second->bit_field() &&
first->is_extensible() == second->is_extensible() &&
first->is_strong() == second->is_strong() &&
first->new_target_is_base() == second->new_target_is_base() &&
first->is_hidden_prototype() == second->is_hidden_prototype();
}

View File

@ -1034,6 +1034,7 @@
'regress/regress-crbug-572590': [SKIP],
'regress/regress-crbug-573857': [SKIP],
'regress/regress-crbug-575080': [SKIP],
'regress/regress-crbug-580506': [SKIP],
'regress/regress-deopt-gcb': [SKIP],
'regress/regress-deopt-gc': [SKIP],
'regress/regress-deopt-in-array-literal-spread': [SKIP],

View File

@ -0,0 +1,22 @@
// Copyright 2016 the V8 project authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
// Flags: --allow-natives-syntax
(function() {
'use strict';
class A extends Function {
constructor(...args) {
super(...args);
this.a = 42;
}
}
var v1 = new A("'use strict';");
function f(func) {
func.__defineSetter__('a', function() { });
}
var v2 = new A();
f(v2);
f(v1);
})();