diff --git a/Tools/javascript/v8_shell.cxx b/Tools/javascript/v8_shell.cxx index aac1284bd..7830c0bdb 100644 --- a/Tools/javascript/v8_shell.cxx +++ b/Tools/javascript/v8_shell.cxx @@ -119,6 +119,9 @@ V8Shell::~V8Shell() {} bool V8Shell::RunScript(const std::string& scriptPath) { std::string source = ReadFile(scriptPath); + v8::Isolate* isolate = v8::Isolate::New(); + v8::Isolate::Scope isolate_scope(isolate); + SWIGV8_HANDLESCOPE(); SwigV8Context context = CreateShellContext();