@@ -63,6 +63,7 @@ using v8::Uint8Array;
63
63
using v8::UnboundScript;
64
64
using v8::Value;
65
65
using v8::WeakCallbackInfo;
66
+ using v8::WeakCallbackType;
66
67
67
68
// The vm module executes code in a sandboxed environment with a different
68
69
// global object than the rest of the code. This is achieved by applying
@@ -103,7 +104,7 @@ ContextifyContext::ContextifyContext(
103
104
// Allocation failure or maximum call stack size reached
104
105
if (context_.IsEmpty ())
105
106
return ;
106
- context_.SetWeak (this , WeakCallback, v8:: WeakCallbackType::kParameter );
107
+ context_.SetWeak (this , WeakCallback, WeakCallbackType::kParameter );
107
108
}
108
109
109
110
@@ -420,7 +421,7 @@ void ContextifyContext::PropertyDefinerCallback(
420
421
return ;
421
422
422
423
Local<Context> context = ctx->context ();
423
- v8:: Isolate* isolate = context->GetIsolate ();
424
+ Isolate* isolate = context->GetIsolate ();
424
425
425
426
auto attributes = PropertyAttribute::None;
426
427
bool is_declared =
@@ -453,13 +454,13 @@ void ContextifyContext::PropertyDefinerCallback(
453
454
454
455
if (desc.has_get () || desc.has_set ()) {
455
456
PropertyDescriptor desc_for_sandbox (
456
- desc.has_get () ? desc.get () : v8:: Undefined (isolate).As <Value>(),
457
- desc.has_set () ? desc.set () : v8:: Undefined (isolate).As <Value>());
457
+ desc.has_get () ? desc.get () : Undefined (isolate).As <Value>(),
458
+ desc.has_set () ? desc.set () : Undefined (isolate).As <Value>());
458
459
459
460
define_prop_on_sandbox (&desc_for_sandbox);
460
461
} else {
461
462
Local<Value> value =
462
- desc.has_value () ? desc.value () : v8:: Undefined (isolate).As <Value>();
463
+ desc.has_value () ? desc.value () : Undefined (isolate).As <Value>();
463
464
464
465
if (desc.has_writable ()) {
465
466
PropertyDescriptor desc_for_sandbox (value, desc.writable ());
0 commit comments