Skip to content

Commit 39095ef

Browse files
committed
add todo for ModuleConcatenationPlugin for loop bugfix
1 parent 9f37b49 commit 39095ef

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

lib/optimize/ModuleConcatenationPlugin.js

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -281,6 +281,10 @@ class ModuleConcatenationPlugin {
281281
for (const reason of newModule.reasons) {
282282
reason.dependency.module = newModule;
283283
}
284+
// TODO: remove when LTS node version contains fixed v8 version
285+
// @see https://github.com/webpack/webpack/pull/6613
286+
// Turbofan does not correctly inline for-of loops with polymorphic input arrays.
287+
// Work around issue by using a standard for loop and assigning dep.module.reasons
284288
for (let i = 0; i < newModule.dependencies.length; i++) {
285289
let dep = newModule.dependencies[i];
286290
if (dep.module) {

0 commit comments

Comments
 (0)