Kouhei Ueno would like Yutaka Hirano and Kentaro Hara to review this change.
[ES6 modules] Document ModuleScript TraceWrapper paths
Bug: 594639, 725816, 732270
Change-Id: I7b83a77beb3806d53adb1e15baa184646a61a4f6
---
M third_party/WebKit/Source/core/dom/ModuleScript.h
1 file changed, 12 insertions(+), 8 deletions(-)
diff --git a/third_party/WebKit/Source/core/dom/ModuleScript.h b/third_party/WebKit/Source/core/dom/ModuleScript.h
index b45010d..5f4a22c 100644
--- a/third_party/WebKit/Source/core/dom/ModuleScript.h
+++ b/third_party/WebKit/Source/core/dom/ModuleScript.h
@@ -137,14 +137,18 @@
// https://html.spec.whatwg.org/multipage/webappapis.html#concept-module-script-pre-instantiation-error
//
// |record_| and |preinstantiation_error_| are TraceWrappers()ed and kept
- // alive via the path of
- // DOMWindow -> Modulator/ModulatorImpl -> ModuleMap -> ModuleMap::Entry
- // -> ModuleScript, or
- // Modulator/ModulatorImpl -> ModuleTreeLinkerRegistry -> ModuleTreeLinker
- // -> ModuleScript, or
- // ScriptLoader -> PendingScript -> ModulePendingScript ->
- // ModulePendingScriptTreeClient -> ModuleScript.
- // All the classes/references on the path above should be
+ // alive via one or more of following reference graphs:
+ // * non-inline module script case
+ // DOMWindow -> Modulator/ModulatorImpl -> ModuleMap -> ModuleMap::Entry
+ // -> ModuleScript
+ // * inline module script case, before the PendingScript is created.
+ // DOMWindow -> Modulator/ModulatorImpl -> ModuleTreeLinkerRegistry
+ // -> ModuleTreeLinker -> ModuleScript
+ // * inline module script case, after the PendingScript is created.
+ // HTMLScriptElement -> ScriptLoader -> PendingScript -> ModulePendingScript
+ // -> ModulePendingScriptTreeClient -> ModuleScript.
+ //
+ // All the classes/references on the graphs above should be
// TraceWrapperBase/TraceWrapperMember<>/etc.,
TraceWrapperV8Reference<v8::Value> preinstantiation_error_;
To view, visit change 547380. To unsubscribe, visit settings.
Kouhei Ueno posted comments on this change.
Patch set 1:
Follow up on https://chromium-review.googlesource.com/c/547157/
Kentaro Hara posted comments on this change.
Patch set 1:Code-Review +1
LGTM
Kouhei Ueno posted comments on this change.
Patch set 1:Commit-Queue +2
Commit Bot merged this change.
[ES6 modules] Document ModuleScript TraceWrapper paths
Bug: 594639, 725816, 732270
Change-Id: I7b83a77beb3806d53adb1e15baa184646a61a4f6
Reviewed-on: https://chromium-review.googlesource.com/547380
Reviewed-by: Kentaro Hara <har...@chromium.org>
Commit-Queue: Kouhei Ueno <kou...@chromium.org>
Cr-Commit-Position: refs/heads/master@{#482235}