|
|
Created:
3 years, 7 months ago by kouhei (in TOK) Modified:
3 years, 7 months ago CC:
chromium-reviews, blink-reviews Target Ref:
refs/heads/master Project:
chromium Visibility:
Public. |
Description[ES6 modules] ModuleTreeLinker::FetchDescendants should not assume urls isn't empty.
Before this CL, we assumed "urls" in ModuleTreeLinker::FetchDescendants() to be non-empty
if record.[[RequestedModules]] is not empty.
However, this isn't always the case, as the resolved url may be in the ancestor list.
This CL removes the DCHECK based on this assumption, and complete the algorithm in that case.
TEST=ModuleTreeLinkerTest.FetchDependencyOfCyclicGraph
BUG=594639
Review-Url: https://codereview.chromium.org/2852963002
Cr-Commit-Position: refs/heads/master@{#468554}
Committed: https://chromium.googlesource.com/chromium/src/+/d087434ab42e298587480260ee4cafbfd002e614
Patch Set 1 #
Total comments: 4
Patch Set 2 : commentfix #
Messages
Total messages: 24 (14 generated)
The CQ bit was checked by kouhei@chromium.org to run a CQ dry run
Dry run: CQ is trying da patch. Follow status at: https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
kouhei@chromium.org changed reviewers: + hiroshige@chromium.org, kinuko@chromium.org, module-dev@chromium.org
Description was changed from ========== [ES6 modules] ModuleTreeLinker::FetchDescendants should not assume urls isn't empty. Before this CL, we assumed "urls" in ModuleTreeLinker::FetchDescendants() to be non-empty if record.[[RequestedModules]] is not empty. However, this isn't always the case, as the resolved url may be in the ancestor list. This CL removes the DCHECK based on this assumption, and complete the algorithm in that case. TEST=ModuleTreeLinkerTest.FetchDependencyOfCyclicGraph BUG=594639 ========== to ========== [ES6 modules] ModuleTreeLinker::FetchDescendants should not assume urls isn't empty. Before this CL, we assumed "urls" in ModuleTreeLinker::FetchDescendants() to be non-empty if record.[[RequestedModules]] is not empty. However, this isn't always the case, as the resolved url may be in the ancestor list. This CL removes the DCHECK based on this assumption, and complete the algorithm in that case. TEST=ModuleTreeLinkerTest.FetchDependencyOfCyclicGraph BUG=594639 ==========
kouhei@chromium.org changed reviewers: + yhirano@chromium.org
The CQ bit was unchecked by commit-bot@chromium.org
Dry run: This issue passed the CQ dry run.
lgtm https://codereview.chromium.org/2852963002/diff/1/third_party/WebKit/Source/c... File third_party/WebKit/Source/core/loader/modulescript/ModuleTreeLinker.cpp (right): https://codereview.chromium.org/2852963002/diff/1/third_party/WebKit/Source/c... third_party/WebKit/Source/core/loader/modulescript/ModuleTreeLinker.cpp:288: // Step 5, when "urls" is empty, or... Could you clarify this (Line 288, and Line 299) is not a text from the spec?
lgtm https://codereview.chromium.org/2852963002/diff/1/third_party/WebKit/Source/c... File third_party/WebKit/Source/core/loader/modulescript/ModuleTreeLinker.cpp (right): https://codereview.chromium.org/2852963002/diff/1/third_party/WebKit/Source/c... third_party/WebKit/Source/core/loader/modulescript/ModuleTreeLinker.cpp:290: // this algorithm with module script. If line 289 is true line 288 should be true too, so connecting these by 'or...' seems a bit strange to me. 'If "urls" is empty, that happens when record.[[RequestedModules]] is empty in Step 2, or when resolved URL was already in the ancestor list, asynchronously complete this algorithm with module script' ? (If these are not exact spec text)
https://codereview.chromium.org/2852963002/diff/1/third_party/WebKit/Source/c... File third_party/WebKit/Source/core/loader/modulescript/ModuleTreeLinker.cpp (right): https://codereview.chromium.org/2852963002/diff/1/third_party/WebKit/Source/c... third_party/WebKit/Source/core/loader/modulescript/ModuleTreeLinker.cpp:290: // this algorithm with module script. On 2017/05/01 22:27:02, kinuko wrote: > If line 289 is true line 288 should be true too, so connecting these by 'or...' > seems a bit strange to me. > > 'If "urls" is empty, that happens when record.[[RequestedModules]] is empty in > Step 2, or when resolved URL was already in the ancestor list, asynchronously > complete this algorithm with module script' > > ? (If these are not exact spec text) [optional] My preference is e.g.: Step 2. If record.[[RequestedModules]] is empty, asynchronously complete this algorithm with module script. [spec text] Also, if record.[[RequestedModules]] is not empty but |urls| is empty here, we can immediately proceed to Instantiate() because we don't have to do or wait for anything in Step 5. [non-spec text] (and perhaps placing this if block before Line 278).
The CQ bit was checked by kouhei@chromium.org
The patchset sent to the CQ was uploaded after l-g-t-m from hiroshige@chromium.org, kinuko@chromium.org Link to the patchset: https://codereview.chromium.org/2852963002/#ps20001 (title: "commentfix")
CQ is trying da patch. Follow status at: https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
https://codereview.chromium.org/2852963002/diff/1/third_party/WebKit/Source/c... File third_party/WebKit/Source/core/loader/modulescript/ModuleTreeLinker.cpp (right): https://codereview.chromium.org/2852963002/diff/1/third_party/WebKit/Source/c... third_party/WebKit/Source/core/loader/modulescript/ModuleTreeLinker.cpp:290: // this algorithm with module script. On 2017/05/01 23:16:12, hiroshige wrote: > On 2017/05/01 22:27:02, kinuko wrote: > > If line 289 is true line 288 should be true too, so connecting these by > 'or...' > > seems a bit strange to me. > > > > 'If "urls" is empty, that happens when record.[[RequestedModules]] is empty in > > Step 2, or when resolved URL was already in the ancestor list, asynchronously > > complete this algorithm with module script' > > > > ? (If these are not exact spec text) > > [optional] My preference is e.g.: > Step 2. If record.[[RequestedModules]] is empty, asynchronously > complete this algorithm with module script. [spec text] > Also, if record.[[RequestedModules]] is not empty but |urls| is > empty here, we can immediately proceed to Instantiate() because > we don't have to do or wait for anything in Step 5. [non-spec text] > (and perhaps placing this if block before Line 278). Done.
The CQ bit was unchecked by commit-bot@chromium.org
Try jobs failed on following builders: linux_chromium_rel_ng on master.tryserver.chromium.linux (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.linux/builders/linux_chromium_...)
The CQ bit was checked by kouhei@chromium.org
CQ is trying da patch. Follow status at: https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
CQ is committing da patch. Bot data: {"patchset_id": 20001, "attempt_start_ts": 1493695910564350, "parent_rev": "2c36828dfc0bef3e7792bdd6e13fdb199b5d97fd", "commit_rev": "d087434ab42e298587480260ee4cafbfd002e614"}
CQ is committing da patch. Bot data: {"patchset_id": 20001, "attempt_start_ts": 1493695910564350, "parent_rev": "2c36828dfc0bef3e7792bdd6e13fdb199b5d97fd", "commit_rev": "d087434ab42e298587480260ee4cafbfd002e614"}
Message was sent while issue was closed.
Description was changed from ========== [ES6 modules] ModuleTreeLinker::FetchDescendants should not assume urls isn't empty. Before this CL, we assumed "urls" in ModuleTreeLinker::FetchDescendants() to be non-empty if record.[[RequestedModules]] is not empty. However, this isn't always the case, as the resolved url may be in the ancestor list. This CL removes the DCHECK based on this assumption, and complete the algorithm in that case. TEST=ModuleTreeLinkerTest.FetchDependencyOfCyclicGraph BUG=594639 ========== to ========== [ES6 modules] ModuleTreeLinker::FetchDescendants should not assume urls isn't empty. Before this CL, we assumed "urls" in ModuleTreeLinker::FetchDescendants() to be non-empty if record.[[RequestedModules]] is not empty. However, this isn't always the case, as the resolved url may be in the ancestor list. This CL removes the DCHECK based on this assumption, and complete the algorithm in that case. TEST=ModuleTreeLinkerTest.FetchDependencyOfCyclicGraph BUG=594639 Review-Url: https://codereview.chromium.org/2852963002 Cr-Commit-Position: refs/heads/master@{#468554} Committed: https://chromium.googlesource.com/chromium/src/+/d087434ab42e298587480260ee4c... ==========
Message was sent while issue was closed.
Committed patchset #2 (id:20001) as https://chromium.googlesource.com/chromium/src/+/d087434ab42e298587480260ee4c... |