Skip to content

Commit 1520afd

Browse files
targosaddaleax
authored andcommitted
deps: update V8 to 5.4.500.43
PR-URL: #9697 Reviewed-By: Ben Noordhuis <[email protected]> Reviewed-By: Colin Ihrig <[email protected]> Reviewed-By: Matteo Collina <[email protected]> Reviewed-By: Anna Henningsen <[email protected]>
1 parent 19ca6cd commit 1520afd

File tree

7 files changed

+41
-3
lines changed

7 files changed

+41
-3
lines changed

deps/v8/include/v8-version.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
#define V8_MAJOR_VERSION 5
1212
#define V8_MINOR_VERSION 4
1313
#define V8_BUILD_NUMBER 500
14-
#define V8_PATCH_LEVEL 41
14+
#define V8_PATCH_LEVEL 43
1515

1616
// Use 1 for candidates and 0 otherwise.
1717
// (Boolean macro values are not supported by all preprocessors.)

deps/v8/src/debug/debug.cc

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1701,6 +1701,11 @@ MaybeHandle<Object> Debug::PromiseHasUserDefinedRejectHandler(
17011701

17021702

17031703
void Debug::OnException(Handle<Object> exception, Handle<Object> promise) {
1704+
// We cannot generate debug events when JS execution is disallowed.
1705+
// TODO(5530): Reenable debug events within DisallowJSScopes once relevant
1706+
// code (MakeExceptionEvent and ProcessDebugEvent) have been moved to C++.
1707+
if (!AllowJavascriptExecution::IsAllowed(isolate_)) return;
1708+
17041709
Isolate::CatchType catch_type = isolate_->PredictExceptionCatcher();
17051710

17061711
// Don't notify listener of exceptions that are internal to a desugaring.

deps/v8/src/lookup.cc

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -308,6 +308,11 @@ void LookupIterator::PrepareTransitionToDataProperty(
308308
PropertyAttributes attributes, Object::StoreFromKeyed store_mode) {
309309
DCHECK(receiver.is_identical_to(GetStoreTarget()));
310310
if (state_ == TRANSITION) return;
311+
312+
if (!IsElement() && name()->IsPrivate()) {
313+
attributes = static_cast<PropertyAttributes>(attributes | DONT_ENUM);
314+
}
315+
311316
DCHECK(state_ != LookupIterator::ACCESSOR ||
312317
(GetAccessors()->IsAccessorInfo() &&
313318
AccessorInfo::cast(*GetAccessors())->is_special_data_property()));
@@ -447,6 +452,9 @@ void LookupIterator::TransitionToAccessorProperty(
447452
// handled via a trap. Adding properties to primitive values is not
448453
// observable.
449454
Handle<JSObject> receiver = GetStoreTarget();
455+
if (!IsElement() && name()->IsPrivate()) {
456+
attributes = static_cast<PropertyAttributes>(attributes | DONT_ENUM);
457+
}
450458

451459
if (!IsElement() && !receiver->map()->is_dictionary_map()) {
452460
Handle<Map> old_map(receiver->map(), isolate_);

deps/v8/src/property.h

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,7 @@ class Descriptor BASE_EMBEDDED {
3636

3737
void Init(Handle<Name> key, Handle<Object> value, PropertyDetails details) {
3838
DCHECK(key->IsUniqueName());
39+
DCHECK_IMPLIES(key->IsPrivate(), !details.IsEnumerable());
3940
key_ = key;
4041
value_ = value;
4142
details_ = details;
@@ -44,6 +45,7 @@ class Descriptor BASE_EMBEDDED {
4445
Descriptor(Handle<Name> key, Handle<Object> value, PropertyDetails details)
4546
: key_(key), value_(value), details_(details) {
4647
DCHECK(key->IsUniqueName());
48+
DCHECK_IMPLIES(key->IsPrivate(), !details_.IsEnumerable());
4749
}
4850

4951
Descriptor(Handle<Name> key, Handle<Object> value,
@@ -53,6 +55,7 @@ class Descriptor BASE_EMBEDDED {
5355
value_(value),
5456
details_(attributes, type, representation, field_index) {
5557
DCHECK(key->IsUniqueName());
58+
DCHECK_IMPLIES(key->IsPrivate(), !details_.IsEnumerable());
5659
}
5760

5861
friend class DescriptorArray;
Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
// Copyright 2016 the V8 project authors. All rights reserved.
2+
// Use of this source code is governed by a BSD-style license that can be
3+
// found in the LICENSE file.
4+
5+
// Flags: --stack-size=100
6+
7+
Debug = debug.Debug
8+
9+
function overflow() {
10+
return overflow();
11+
}
12+
13+
Debug.setBreakOnException();
14+
assertThrows(overflow, RangeError);

deps/v8/test/mjsunit/harmony/private.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -278,8 +278,8 @@ function TestKeyDescriptor(obj) {
278278
assertEquals(i|0, desc.value)
279279
assertTrue(desc.configurable)
280280
assertEquals(i % 2 == 0, desc.writable)
281-
assertEquals(i % 2 == 0, desc.enumerable)
282-
assertEquals(i % 2 == 0,
281+
assertEquals(false, desc.enumerable)
282+
assertEquals(false,
283283
Object.prototype.propertyIsEnumerable.call(obj, symbols[i]))
284284
}
285285
}
Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
// Copyright 2016 the V8 project authors. All rights reserved.
2+
// Use of this source code is governed by a BSD-style license that can be
3+
// found in the LICENSE file.
4+
5+
class A {}
6+
class B {}
7+
Object.assign(B, A);
8+
assertEquals("class B {}", B.toString());

0 commit comments

Comments
 (0)