Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(578)

Unified Diff: sky/engine/bindings/core/v8/ScriptController.cpp

Issue 688033003: Fix line numbers in JavaScript stack traces (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: Remove unnecessary Created 6 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « sky/engine/bindings/core/v8/ScriptController.h ('k') | sky/engine/bindings/core/v8/V8PerContextData.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: sky/engine/bindings/core/v8/ScriptController.cpp
diff --git a/sky/engine/bindings/core/v8/ScriptController.cpp b/sky/engine/bindings/core/v8/ScriptController.cpp
index ab0bb10a21bb47c3b2192644bfa519e2d2f6cae8..9a75bbe2bb038cef53aeb3e4ed9b3fe5f971aaad 100644
--- a/sky/engine/bindings/core/v8/ScriptController.cpp
+++ b/sky/engine/bindings/core/v8/ScriptController.cpp
@@ -329,7 +329,7 @@ void ScriptController::executeScriptInIsolatedWorld(int worldID, const Vector<Sc
}
}
-void ScriptController::executeModuleScript(Document& document, const String& source)
+void ScriptController::executeModuleScript(Document& document, const String& source, const TextPosition& textPosition)
{
v8::HandleScope handleScope(m_isolate);
v8::Handle<v8::Context> context = toV8Context(m_frame, DOMWrapperWorld::mainWorld());
@@ -345,14 +345,17 @@ void ScriptController::executeModuleScript(Document& document, const String& sou
tryCatch.SetVerbose(true);
V8ScriptModule module;
+ module.resourceName = document.url().string();
+ module.textPosition = textPosition;
module.receiver = toV8(&document, context->Global(), m_isolate);
+ module.source = source;
if (HTMLImport* parent = document.import()) {
for (HTMLImport* child = parent->firstChild(); child; child = child->next()) {
if (HTMLLinkElement* link = static_cast<HTMLImportChild*>(child)->link()) {
String name = link->as();
if (!name.isEmpty()) {
- module.formalDependenciesAndSource.append(v8String(m_isolate, name));
+ module.formalDependencies.append(name);
v8::Handle<v8::Value> actual;
if (child->document())
actual = child->document()->exports().v8Value();
@@ -364,7 +367,6 @@ void ScriptController::executeModuleScript(Document& document, const String& sou
}
}
- module.formalDependenciesAndSource.append(v8String(m_isolate, source));
V8ScriptRunner::runModule(m_isolate, m_frame->document(), module);
}
« no previous file with comments | « sky/engine/bindings/core/v8/ScriptController.h ('k') | sky/engine/bindings/core/v8/V8PerContextData.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698