Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
N
next.js
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Alex
next.js
Commits
0219ed9e
Commit
0219ed9e
authored
Jan 30, 2026
by
Tobias Koppers
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Turbopack: Tree Shaking imports only internal
parent
2ce415f4
Show whitespace changes
Inline
Side-by-side
Showing
62 changed files
with
474 additions
and
453 deletions
+474
-453
imports.rs
...opack/crates/turbopack-ecmascript/src/analyzer/imports.rs
+3
-6
base.rs
...ck/crates/turbopack-ecmascript/src/references/esm/base.rs
+10
-5
export.rs
.../crates/turbopack-ecmascript/src/references/esm/export.rs
+14
-10
graph.rs
...opack/crates/turbopack-ecmascript/src/tree_shake/graph.rs
+33
-87
merge.rs
...opack/crates/turbopack-ecmascript/src/tree_shake/merge.rs
+2
-2
mod.rs
turbopack/crates/turbopack-ecmascript/src/tree_shake/mod.rs
+33
-29
module.rs
...crates/turbopack-ecmascript/src/tree_shake/part/module.rs
+106
-41
output.md
...rbopack-ecmascript/tests/tree-shaker/analyzer/1/output.md
+8
-8
output.md
...rbopack-ecmascript/tests/tree-shaker/analyzer/2/output.md
+8
-8
output.md
...rbopack-ecmascript/tests/tree-shaker/analyzer/3/output.md
+6
-6
output.md
...ipt/tests/tree-shaker/analyzer/amphtml-document/output.md
+2
-2
output.md
...ecmascript/tests/tree-shaker/analyzer/app-route/output.md
+12
-12
output.md
...ript/tests/tree-shaker/analyzer/combined-export/output.md
+4
-4
output.md
...k-ecmascript/tests/tree-shaker/analyzer/complex/output.md
+8
-8
output.md
...ascript/tests/tree-shaker/analyzer/export-named/output.md
+2
-2
output.md
...-ecmascript/tests/tree-shaker/analyzer/failed-1/output.md
+6
-6
output.md
...-ecmascript/tests/tree-shaker/analyzer/failed-2/output.md
+16
-16
output.md
...-ecmascript/tests/tree-shaker/analyzer/failed-3/output.md
+4
-4
output.md
...-ecmascript/tests/tree-shaker/analyzer/grouping/output.md
+4
-4
output.md
...ascript/tests/tree-shaker/analyzer/ipc-evaluate/output.md
+2
-2
output.md
...ecmascript/tests/tree-shaker/analyzer/ipc-index/output.md
+4
-4
output.md
...ecmascript/tests/tree-shaker/analyzer/let-bug-1/output.md
+4
-4
output.md
...ck-ecmascript/tests/tree-shaker/analyzer/logger/output.md
+4
-4
output.md
...k-ecmascript/tests/tree-shaker/analyzer/mui-sys/output.md
+26
-26
output.md
...ascript/tests/tree-shaker/analyzer/multi-export/output.md
+4
-4
output.md
...ck-ecmascript/tests/tree-shaker/analyzer/nanoid/output.md
+10
-10
output.md
...script/tests/tree-shaker/analyzer/next-response/output.md
+2
-2
output.md
...script/tests/tree-shaker/analyzer/nextjs-tracer/output.md
+10
-10
output.md
...cmascript/tests/tree-shaker/analyzer/node-fetch/output.md
+2
-2
output.md
...ecmascript/tests/tree-shaker/analyzer/otel-core/output.md
+4
-4
output.md
...script/tests/tree-shaker/analyzer/route-handler/output.md
+4
-4
output.md
...cmascript/tests/tree-shaker/analyzer/route-kind/output.md
+2
-2
output.md
...-ecmascript/tests/tree-shaker/analyzer/shared-2/output.md
+6
-6
output.md
...ts/tree-shaker/analyzer/shared-and-side-effects/output.md
+4
-4
output.md
...pt/tests/tree-shaker/analyzer/shared-regression/output.md
+6
-6
output.md
...script/tests/tree-shaker/analyzer/simple-vars-1/output.md
+4
-4
output.md
...ck-ecmascript/tests/tree-shaker/analyzer/simple/output.md
+4
-4
output.md
...cript/tests/tree-shaker/analyzer/template-pages/output.md
+24
-24
output.md
...script/tests/tree-shaker/analyzer/test-config-1/output.md
+8
-8
output.md
...ack-ecmascript/tests/tree-shaker/analyzer/tla-1/output.md
+4
-4
output.md
...-ecmascript/tests/tree-shaker/analyzer/typeof-1/output.md
+2
-2
output.md
...mascript/tests/tree-shaker/analyzer/write-order/output.md
+6
-6
bf321_tests_snapshot_basic-tree-shake_dynamic-import_input_lib_63494f91.js
...hot_basic-tree-shake_dynamic-import_input_lib_63494f91.js
+8
-8
bf321_tests_snapshot_basic-tree-shake_dynamic-import_input_lib_63494f91.js.map
...basic-tree-shake_dynamic-import_input_lib_63494f91.js.map
+0
-0
bf321_tests_snapshot_basic-tree-shake_dynamic-import_input_lib_ee638b2a.js
...hot_basic-tree-shake_dynamic-import_input_lib_ee638b2a.js
+1
-1
780ce_turbopack-tests_tests_snapshot_basic-tree-shake_export-namespace_input_2100e737._.js
...hot_basic-tree-shake_export-namespace_input_2100e737._.js
+6
-6
780ce_turbopack-tests_tests_snapshot_basic-tree-shake_export-namespace_input_2100e737._.js.map
...basic-tree-shake_export-namespace_input_2100e737._.js.map
+0
-0
ad3e4_tests_snapshot_basic-tree-shake_export-namespace_input_index_fee7c584.js
...basic-tree-shake_export-namespace_input_index_fee7c584.js
+2
-2
bf321_tests_snapshot_basic-tree-shake_export-namespace_input_index_fee7c584.js.map
...c-tree-shake_export-namespace_input_index_fee7c584.js.map
+0
-0
780ce_turbopack-tests_tests_snapshot_basic-tree-shake_import-namespace_input_31731fc7._.js
...hot_basic-tree-shake_import-namespace_input_31731fc7._.js
+5
-5
780ce_turbopack-tests_tests_snapshot_basic-tree-shake_import-namespace_input_31731fc7._.js.map
...basic-tree-shake_import-namespace_input_31731fc7._.js.map
+1
-1
ad3e4_tests_snapshot_basic-tree-shake_import-namespace_input_index_928c6c80.js
...basic-tree-shake_import-namespace_input_index_928c6c80.js
+2
-2
bf321_tests_snapshot_basic-tree-shake_import-namespace_input_index_928c6c80.js.map
...c-tree-shake_import-namespace_input_index_928c6c80.js.map
+0
-0
ad3e4_tests_snapshot_basic-tree-shake_require-side-effect_input_index_ec5c94a4.js
...ic-tree-shake_require-side-effect_input_index_ec5c94a4.js
+2
-2
bf321_tests_snapshot_basic-tree-shake_require-side-effect_input_a2766cda._.js
..._basic-tree-shake_require-side-effect_input_a2766cda._.js
+8
-8
bf321_tests_snapshot_basic-tree-shake_require-side-effect_input_a2766cda._.js.map
...ic-tree-shake_require-side-effect_input_a2766cda._.js.map
+0
-0
bf321_tests_snapshot_basic-tree-shake_require-side-effect_input_index_ec5c94a4.js.map
...ree-shake_require-side-effect_input_index_ec5c94a4.js.map
+0
-0
ad3e4_tests_snapshot_basic-tree-shake_tree-shake-test-1_input_index_a09a504d.js
...asic-tree-shake_tree-shake-test-1_input_index_a09a504d.js
+2
-2
bf321_tests_snapshot_basic-tree-shake_tree-shake-test-1_input_index_88b827c6.js
...asic-tree-shake_tree-shake-test-1_input_index_88b827c6.js
+8
-8
bf321_tests_snapshot_basic-tree-shake_tree-shake-test-1_input_index_88b827c6.js.map
...-tree-shake_tree-shake-test-1_input_index_88b827c6.js.map
+0
-0
bf321_tests_snapshot_basic-tree-shake_tree-shake-test-1_input_index_a09a504d.js.map
...-tree-shake_tree-shake-test-1_input_index_a09a504d.js.map
+0
-0
lib.rs
turbopack/crates/turbopack/src/lib.rs
+2
-2
No files found.
turbopack/crates/turbopack-ecmascript/src/analyzer/imports.rs
View file @
0219ed9e
...
@@ -21,7 +21,7 @@ use crate::{
...
@@ -21,7 +21,7 @@ use crate::{
SpecifiedModuleType
,
SpecifiedModuleType
,
analyzer
::{
ConstantValue
,
ObjectPart
},
analyzer
::{
ConstantValue
,
ObjectPart
},
magic_identifier
,
magic_identifier
,
tree_shake
::
{
PartId
,
find_turbopack_part_id_in_asserts
}
,
tree_shake
::
find_turbopack_part_id_in_asserts
,
};
};
#[turbo_tasks
::
value]
#[turbo_tasks
::
value]
...
@@ -831,11 +831,8 @@ fn parse_directives(
...
@@ -831,11 +831,8 @@ fn parse_directives(
fn
parse_with
(
with
:
Option
<&
ObjectLit
>
)
->
Option
<
ImportedSymbol
>
{
fn
parse_with
(
with
:
Option
<&
ObjectLit
>
)
->
Option
<
ImportedSymbol
>
{
find_turbopack_part_id_in_asserts
(
with
?
)
.map
(|
v
|
match
v
{
find_turbopack_part_id_in_asserts
(
with
?
)
.map
(|
v
|
match
v
{
PartId
::
Internal
(
index
,
true
)
=>
ImportedSymbol
::
PartEvaluation
(
index
),
(
index
,
true
)
=>
ImportedSymbol
::
PartEvaluation
(
index
),
PartId
::
Internal
(
index
,
false
)
=>
ImportedSymbol
::
Part
(
index
),
(
index
,
false
)
=>
ImportedSymbol
::
Part
(
index
),
PartId
::
ModuleEvaluation
=>
ImportedSymbol
::
ModuleEvaluation
,
PartId
::
Export
(
e
)
=>
ImportedSymbol
::
Symbol
(
e
.as_str
()
.into
()),
PartId
::
Exports
=>
ImportedSymbol
::
Exports
,
})
})
}
}
...
...
turbopack/crates/turbopack-ecmascript/src/references/esm/base.rs
View file @
0219ed9e
...
@@ -14,6 +14,7 @@ use turbo_tasks::{ResolvedVc, ValueToString, Vc};
...
@@ -14,6 +14,7 @@ use turbo_tasks::{ResolvedVc, ValueToString, Vc};
use
turbo_tasks_fs
::
FileSystemPath
;
use
turbo_tasks_fs
::
FileSystemPath
;
use
turbopack_core
::{
use
turbopack_core
::{
chunk
::{
ChunkingContext
,
ChunkingType
,
ChunkingTypeOption
,
ModuleChunkItemIdExt
},
chunk
::{
ChunkingContext
,
ChunkingType
,
ChunkingTypeOption
,
ModuleChunkItemIdExt
},
context
::
ProcessResult
,
issue
::{
issue
::{
Issue
,
IssueExt
,
IssueSeverity
,
IssueSource
,
IssueStage
,
OptionIssueSource
,
Issue
,
IssueExt
,
IssueSeverity
,
IssueSource
,
IssueStage
,
OptionIssueSource
,
OptionStyledString
,
StyledString
,
OptionStyledString
,
StyledString
,
...
@@ -434,11 +435,15 @@ impl ModuleReference for EsmAssetReference {
...
@@ -434,11 +435,15 @@ impl ModuleReference for EsmAssetReference {
&&
module
.is_match
(
TURBOPACK_PART_IMPORT_SOURCE
)
&&
module
.is_match
(
TURBOPACK_PART_IMPORT_SOURCE
)
{
{
if
let
Some
(
part
)
=
&
self
.export_name
{
if
let
Some
(
part
)
=
&
self
.export_name
{
return
Ok
(
*
ModuleResolveResult
::
module
(
ResolvedVc
::
upcast
(
let
ProcessResult
::
Module
(
module_part
)
=
EcmascriptModulePartAsset
::
select_part
(
*
self
.module
,
part
.clone
())
*
EcmascriptModulePartAsset
::
select_part
(
*
self
.module
,
part
.clone
())
.await
?
.to_resolved
()
else
{
.await
?
,
bail!
(
)));
"ModulePart::Internal should always return a module part in
\
select_part"
);
};
return
Ok
(
*
ModuleResolveResult
::
module
(
module_part
));
}
}
bail!
(
"export_name is required for part import"
)
bail!
(
"export_name is required for part import"
)
}
}
...
...
turbopack/crates/turbopack-ecmascript/src/references/esm/export.rs
View file @
0219ed9e
...
@@ -18,6 +18,7 @@ use turbo_tasks::{
...
@@ -18,6 +18,7 @@ use turbo_tasks::{
};
};
use
turbopack_core
::{
use
turbopack_core
::{
chunk
::{
ChunkingContext
,
ModuleChunkItemIdExt
},
chunk
::{
ChunkingContext
,
ModuleChunkItemIdExt
},
context
::
ProcessResult
,
ident
::
AssetIdent
,
ident
::
AssetIdent
,
issue
::{
IssueExt
,
IssueSeverity
,
StyledString
,
analyze
::
AnalyzeIssue
},
issue
::{
IssueExt
,
IssueSeverity
,
StyledString
,
analyze
::
AnalyzeIssue
},
module
::{
Module
,
ModuleSideEffects
},
module
::{
Module
,
ModuleSideEffects
},
...
@@ -310,19 +311,22 @@ async fn find_export_from_reexports(
...
@@ -310,19 +311,22 @@ async fn find_export_from_reexports(
if
let
Some
(
module
)
=
ResolvedVc
::
try_downcast_type
::
<
EcmascriptModulePartAsset
>
(
module
)
if
let
Some
(
module
)
=
ResolvedVc
::
try_downcast_type
::
<
EcmascriptModulePartAsset
>
(
module
)
&&
matches!
(
module
.await
?
.part
,
ModulePart
::
Exports
)
&&
matches!
(
module
.await
?
.part
,
ModulePart
::
Exports
)
{
{
let
module_part
=
EcmascriptModulePartAsset
::
select_part
(
let
ProcessResult
::
Module
(
module_part
)
=
*
EcmascriptModulePartAsset
::
select_part
(
*
module
.await
?
.full_module
,
*
module
.await
?
.full_module
,
ModulePart
::
export
(
export_name
.clone
()),
ModulePart
::
export
(
export_name
.clone
()),
);
)
.await
?
else
{
bail!
(
"ModulePart::export should always return a module part in select_part"
);
};
if
let
Some
(
module_part
)
=
ResolvedVc
::
try_downcast
::
<
Box
<
dyn
EcmascriptChunkPlaceable
>>
(
module_part
)
{
// TODO This sounds like a bit hack! Refactor!
// If we apply this logic to EcmascriptModuleAsset, we will resolve everything in the
// If we apply this logic to EcmascriptModuleAsset, we will resolve everything in the
// target module.
// target module.
if
(
ResolvedVc
::
try_downcast_type
::
<
EcmascriptModuleAsset
>
(
if
(
ResolvedVc
::
try_downcast_type
::
<
EcmascriptModuleAsset
>
(
module_part
))
.is_none
()
{
module_part
.to_resolved
()
.await
?
,
return
Ok
(
find_export_from_reexports
(
*
module_part
,
export_name
));
))
}
.is_none
()
{
return
Ok
(
find_export_from_reexports
(
module_part
,
export_name
));
}
}
}
}
...
...
turbopack/crates/turbopack-ecmascript/src/tree_shake/graph.rs
View file @
0219ed9e
...
@@ -24,7 +24,6 @@ use swc_core::{
...
@@ -24,7 +24,6 @@ use swc_core::{
utils
::{
ExprCtx
,
ExprExt
,
find_pat_ids
,
quote_ident
},
utils
::{
ExprCtx
,
ExprExt
,
find_pat_ids
,
quote_ident
},
},
},
};
};
use
turbo_rcstr
::
RcStr
;
use
turbo_tasks
::
FxIndexSet
;
use
turbo_tasks
::
FxIndexSet
;
use
super
::{
use
super
::{
...
@@ -254,7 +253,7 @@ pub(super) struct SplitModuleResult {
...
@@ -254,7 +253,7 @@ pub(super) struct SplitModuleResult {
pub
entrypoints
:
FxHashMap
<
Key
,
u32
>
,
pub
entrypoints
:
FxHashMap
<
Key
,
u32
>
,
/// Dependency between parts.
/// Dependency between parts.
pub
part_deps
:
FxHashMap
<
u32
,
Vec
<
PartId
>>
,
pub
part_deps
:
FxHashMap
<
u32
,
Vec
<
(
u32
,
bool
)
>>
,
pub
modules
:
Vec
<
Module
>
,
pub
modules
:
Vec
<
Module
>
,
pub
star_reexports
:
Vec
<
ExportAll
>
,
pub
star_reexports
:
Vec
<
ExportAll
>
,
...
@@ -295,7 +294,7 @@ impl DepGraph {
...
@@ -295,7 +294,7 @@ impl DepGraph {
)
->
SplitModuleResult
{
)
->
SplitModuleResult
{
let
groups
=
self
.finalize
(
data
);
let
groups
=
self
.finalize
(
data
);
let
mut
outputs
=
FxHashMap
::
default
();
let
mut
outputs
=
FxHashMap
::
default
();
let
mut
part_deps
=
FxHashMap
::
<
_
,
Vec
<
PartId
>>
::
default
();
let
mut
part_deps
=
FxHashMap
::
<
_
,
Vec
<
(
u32
,
bool
)
>>
::
default
();
let
star_reexports
:
Vec
<
_
>
=
data
let
star_reexports
:
Vec
<
_
>
=
data
.values
()
.values
()
...
@@ -396,10 +395,7 @@ impl DepGraph {
...
@@ -396,10 +395,7 @@ impl DepGraph {
&&
*
dep
!=
ix
as
u32
&&
*
dep
!=
ix
as
u32
&&
part_deps_done
.insert
(
*
dep
)
&&
part_deps_done
.insert
(
*
dep
)
{
{
part_deps
part_deps
.entry
(
ix
as
u32
)
.or_default
()
.push
((
*
dep
,
true
));
.entry
(
ix
as
u32
)
.or_default
()
.push
(
PartId
::
Internal
(
*
dep
,
true
));
chunk
chunk
.body
.body
...
@@ -408,9 +404,7 @@ impl DepGraph {
...
@@ -408,9 +404,7 @@ impl DepGraph {
specifiers
:
vec!
[],
specifiers
:
vec!
[],
src
:
Box
::
new
(
TURBOPACK_PART_IMPORT_SOURCE
.into
()),
src
:
Box
::
new
(
TURBOPACK_PART_IMPORT_SOURCE
.into
()),
type_only
:
false
,
type_only
:
false
,
with
:
Some
(
Box
::
new
(
create_turbopack_part_id_assert
(
with
:
Some
(
Box
::
new
(
create_turbopack_part_id_assert
(
*
dep
,
true
))),
PartId
::
Internal
(
*
dep
,
true
),
))),
phase
:
Default
::
default
(),
phase
:
Default
::
default
(),
})));
})));
}
}
...
@@ -439,7 +433,7 @@ impl DepGraph {
...
@@ -439,7 +433,7 @@ impl DepGraph {
src
:
Some
(
Box
::
new
(
TURBOPACK_PART_IMPORT_SOURCE
.into
())),
src
:
Some
(
Box
::
new
(
TURBOPACK_PART_IMPORT_SOURCE
.into
())),
type_only
:
false
,
type_only
:
false
,
with
:
Some
(
Box
::
new
(
create_turbopack_part_id_assert
(
with
:
Some
(
Box
::
new
(
create_turbopack_part_id_assert
(
PartId
::
Export
(
export
.as_str
()
.into
())
,
ix
as
u32
,
false
,
))),
))),
}),
}),
));
));
...
@@ -477,7 +471,6 @@ impl DepGraph {
...
@@ -477,7 +471,6 @@ impl DepGraph {
required_vars
.swap_remove
(
var
);
required_vars
.swap_remove
(
var
);
let
dep_part_id
=
PartId
::
Export
(
export
.as_str
()
.into
());
let
specifiers
=
vec!
[
ImportSpecifier
::
Named
(
ImportNamedSpecifier
{
let
specifiers
=
vec!
[
ImportSpecifier
::
Named
(
ImportNamedSpecifier
{
span
:
DUMMY_SP
,
span
:
DUMMY_SP
,
local
:
var
.clone
()
.into
(),
local
:
var
.clone
()
.into
(),
...
@@ -485,10 +478,7 @@ impl DepGraph {
...
@@ -485,10 +478,7 @@ impl DepGraph {
is_type_only
:
false
,
is_type_only
:
false
,
})];
})];
part_deps
part_deps
.entry
(
ix
as
u32
)
.or_default
()
.push
((
dep
,
true
));
.entry
(
ix
as
u32
)
.or_default
()
.push
(
dep_part_id
.clone
());
chunk
chunk
.body
.body
...
@@ -497,7 +487,7 @@ impl DepGraph {
...
@@ -497,7 +487,7 @@ impl DepGraph {
specifiers
,
specifiers
,
src
:
Box
::
new
(
TURBOPACK_PART_IMPORT_SOURCE
.into
()),
src
:
Box
::
new
(
TURBOPACK_PART_IMPORT_SOURCE
.into
()),
type_only
:
false
,
type_only
:
false
,
with
:
Some
(
Box
::
new
(
create_turbopack_part_id_assert
(
dep
_part_id
))),
with
:
Some
(
Box
::
new
(
create_turbopack_part_id_assert
(
dep
,
true
))),
phase
:
Default
::
default
(),
phase
:
Default
::
default
(),
})));
})));
}
}
...
@@ -537,7 +527,7 @@ impl DepGraph {
...
@@ -537,7 +527,7 @@ impl DepGraph {
part_deps
part_deps
.entry
(
ix
as
u32
)
.entry
(
ix
as
u32
)
.or_default
()
.or_default
()
.push
(
PartId
::
Internal
(
*
import_dep
,
true
));
.push
((
*
import_dep
,
true
));
chunk
.body
.push
(
ModuleItem
::
ModuleDecl
(
ModuleDecl
::
Import
(
chunk
.body
.push
(
ModuleItem
::
ModuleDecl
(
ModuleDecl
::
Import
(
ImportDecl
{
ImportDecl
{
...
@@ -546,7 +536,8 @@ impl DepGraph {
...
@@ -546,7 +536,8 @@ impl DepGraph {
src
:
Box
::
new
(
TURBOPACK_PART_IMPORT_SOURCE
.into
()),
src
:
Box
::
new
(
TURBOPACK_PART_IMPORT_SOURCE
.into
()),
type_only
:
false
,
type_only
:
false
,
with
:
Some
(
Box
::
new
(
create_turbopack_part_id_assert
(
with
:
Some
(
Box
::
new
(
create_turbopack_part_id_assert
(
PartId
::
Internal
(
*
import_dep
,
true
),
*
import_dep
,
true
,
))),
))),
phase
:
Default
::
default
(),
phase
:
Default
::
default
(),
},
},
...
@@ -581,10 +572,7 @@ impl DepGraph {
...
@@ -581,10 +572,7 @@ impl DepGraph {
is_type_only
:
false
,
is_type_only
:
false
,
})];
})];
part_deps
part_deps
.entry
(
ix
as
u32
)
.or_default
()
.push
((
dep
,
false
));
.entry
(
ix
as
u32
)
.or_default
()
.push
(
PartId
::
Internal
(
dep
,
false
));
chunk
chunk
.body
.body
...
@@ -593,9 +581,7 @@ impl DepGraph {
...
@@ -593,9 +581,7 @@ impl DepGraph {
specifiers
,
specifiers
,
src
:
Box
::
new
(
TURBOPACK_PART_IMPORT_SOURCE
.into
()),
src
:
Box
::
new
(
TURBOPACK_PART_IMPORT_SOURCE
.into
()),
type_only
:
false
,
type_only
:
false
,
with
:
Some
(
Box
::
new
(
create_turbopack_part_id_assert
(
PartId
::
Internal
(
with
:
Some
(
Box
::
new
(
create_turbopack_part_id_assert
(
dep
,
false
))),
dep
,
false
,
)))),
phase
:
Default
::
default
(),
phase
:
Default
::
default
(),
})));
})));
}
}
...
@@ -613,10 +599,7 @@ impl DepGraph {
...
@@ -613,10 +599,7 @@ impl DepGraph {
continue
;
continue
;
}
}
part_deps
part_deps
.entry
(
ix
as
u32
)
.or_default
()
.push
((
dep
,
true
));
.entry
(
ix
as
u32
)
.or_default
()
.push
(
PartId
::
Internal
(
dep
,
true
));
chunk
chunk
.body
.body
...
@@ -625,9 +608,7 @@ impl DepGraph {
...
@@ -625,9 +608,7 @@ impl DepGraph {
specifiers
:
vec!
[],
specifiers
:
vec!
[],
src
:
Box
::
new
(
TURBOPACK_PART_IMPORT_SOURCE
.into
()),
src
:
Box
::
new
(
TURBOPACK_PART_IMPORT_SOURCE
.into
()),
type_only
:
false
,
type_only
:
false
,
with
:
Some
(
Box
::
new
(
create_turbopack_part_id_assert
(
PartId
::
Internal
(
with
:
Some
(
Box
::
new
(
create_turbopack_part_id_assert
(
dep
,
true
))),
dep
,
true
,
)))),
phase
:
Default
::
default
(),
phase
:
Default
::
default
(),
})));
})));
}
}
...
@@ -729,16 +710,7 @@ impl DepGraph {
...
@@ -729,16 +710,7 @@ impl DepGraph {
// Currently we need to have `Key::ModuleEvaluation` in the outputs
// Currently we need to have `Key::ModuleEvaluation` in the outputs
// even if it is empty.
// even if it is empty.
if
module_evaluation_ix
.is_none
()
{
if
module_evaluation_ix
.is_some
()
{
outputs
.insert
(
Key
::
ModuleEvaluation
,
modules
.len
()
as
u32
);
module_evaluation_ix
=
Some
(
modules
.len
()
as
u32
);
modules
.push
(
Module
{
span
:
DUMMY_SP
,
body
:
vec!
[],
shebang
:
None
,
});
}
// Push `export {}` to the module evaluation to make it module.
// Push `export {}` to the module evaluation to make it module.
modules
[
module_evaluation_ix
.unwrap
()
as
usize
]
modules
[
module_evaluation_ix
.unwrap
()
as
usize
]
.body
.body
...
@@ -751,6 +723,7 @@ impl DepGraph {
...
@@ -751,6 +723,7 @@ impl DepGraph {
with
:
None
,
with
:
None
,
},
},
)));
)));
}
if
!
star_reexports
.is_empty
()
{
if
!
star_reexports
.is_empty
()
{
let
mut
module
=
Module
::
dummy
();
let
mut
module
=
Module
::
dummy
();
...
@@ -1646,56 +1619,29 @@ impl DepGraph {
...
@@ -1646,56 +1619,29 @@ impl DepGraph {
const
ASSERT_CHUNK_KEY
:
&
str
=
"__turbopack_part__"
;
const
ASSERT_CHUNK_KEY
:
&
str
=
"__turbopack_part__"
;
#[derive(Debug,
Clone)]
pub
(
crate
)
fn
create_turbopack_part_id_assert
(
dep
:
u32
,
is_for_eval
:
bool
)
->
ObjectLit
{
pub
(
crate
)
enum
PartId
{
ModuleEvaluation
,
Exports
,
Export
(
RcStr
),
/// `(part_id, is_for_eval)`
Internal
(
u32
,
bool
),
}
pub
(
crate
)
fn
create_turbopack_part_id_assert
(
dep
:
PartId
)
->
ObjectLit
{
// We can't use quote! as `with` is not standard yet
// We can't use quote! as `with` is not standard yet
ObjectLit
{
ObjectLit
{
span
:
DUMMY_SP
,
span
:
DUMMY_SP
,
props
:
vec!
[
PropOrSpread
::
Prop
(
Box
::
new
(
Prop
::
KeyValue
(
KeyValueProp
{
props
:
vec!
[
PropOrSpread
::
Prop
(
Box
::
new
(
Prop
::
KeyValue
(
KeyValueProp
{
key
:
PropName
::
Ident
(
IdentName
::
new
(
ASSERT_CHUNK_KEY
.into
(),
DUMMY_SP
)),
key
:
PropName
::
Ident
(
IdentName
::
new
(
ASSERT_CHUNK_KEY
.into
(),
DUMMY_SP
)),
value
:
match
dep
{
value
:
{
PartId
::
ModuleEvaluation
=>
"module evaluation"
.into
(),
PartId
::
Exports
=>
"exports"
.into
(),
PartId
::
Export
(
e
)
=>
format!
(
"export {e}"
)
.into
(),
PartId
::
Internal
(
dep
,
is_for_eval
)
=>
{
let
v
=
dep
as
f64
;
let
v
=
dep
as
f64
;
if
is_for_eval
{
v
}
else
{
-
v
}
if
is_for_eval
{
v
}
else
{
-
v
}
.into
()
}
.into
(),
},
},
})))],
})))],
}
}
}
}
pub
(
crate
)
fn
find_turbopack_part_id_in_asserts
(
asserts
:
&
ObjectLit
)
->
Option
<
PartId
>
{
pub
(
crate
)
fn
find_turbopack_part_id_in_asserts
(
asserts
:
&
ObjectLit
)
->
Option
<
(
u32
,
bool
)
>
{
asserts
.props
.iter
()
.find_map
(|
prop
|
match
prop
{
asserts
.props
.iter
()
.find_map
(|
prop
|
match
prop
{
PropOrSpread
::
Prop
(
box
Prop
::
KeyValue
(
KeyValueProp
{
PropOrSpread
::
Prop
(
box
Prop
::
KeyValue
(
KeyValueProp
{
key
:
PropName
::
Ident
(
key
),
key
:
PropName
::
Ident
(
key
),
value
:
box
Expr
::
Lit
(
Lit
::
Num
(
chunk_id
)),
value
:
box
Expr
::
Lit
(
Lit
::
Num
(
chunk_id
)),
}))
if
&*
key
.sym
==
ASSERT_CHUNK_KEY
=>
Some
(
PartId
::
Internal
(
}))
if
&*
key
.sym
==
ASSERT_CHUNK_KEY
=>
Some
((
chunk_id
.value
.abs
()
as
u32
,
chunk_id
.value
.abs
()
as
u32
,
chunk_id
.value
.is_sign_positive
(),
chunk_id
.value
.is_sign_positive
(),
)),
)),
PropOrSpread
::
Prop
(
box
Prop
::
KeyValue
(
KeyValueProp
{
key
:
PropName
::
Ident
(
key
),
value
:
box
Expr
::
Lit
(
Lit
::
Str
(
s
)),
}))
if
&*
key
.sym
==
ASSERT_CHUNK_KEY
=>
match
s
.value
.as_str
()
?
{
"module evaluation"
=>
Some
(
PartId
::
ModuleEvaluation
),
"exports"
=>
Some
(
PartId
::
Exports
),
_
if
s
.value
.starts_with
(
"export "
)
=>
{
Some
(
PartId
::
Export
(
s
.value
.as_str
()
?
[
7
..
]
.into
()))
}
_
=>
None
,
},
_
=>
None
,
_
=>
None
,
})
})
}
}
...
...
turbopack/crates/turbopack-ecmascript/src/tree_shake/merge.rs
View file @
0219ed9e
...
@@ -5,7 +5,7 @@ use swc_core::{
...
@@ -5,7 +5,7 @@ use swc_core::{
ecma
::
ast
::{
Module
,
ModuleDecl
,
ModuleItem
},
ecma
::
ast
::{
Module
,
ModuleDecl
,
ModuleItem
},
};
};
use
super
::
{
PartId
,
graph
::
find_turbopack_part_id_in_asserts
}
;
use
super
::
graph
::
find_turbopack_part_id_in_asserts
;
/// A loader used to merge module items after splitting.
/// A loader used to merge module items after splitting.
pub
trait
Load
{
pub
trait
Load
{
...
@@ -53,7 +53,7 @@ where
...
@@ -53,7 +53,7 @@ where
.as_deref
()
.as_deref
()
.and_then
(
find_turbopack_part_id_in_asserts
);
.and_then
(
find_turbopack_part_id_in_asserts
);
if
let
Some
(
PartId
::
Internal
(
part_id
,
_
))
=
part_id
{
if
let
Some
((
part_id
,
_
))
=
part_id
{
if
self
.done
.insert
((
import
.src.value
.clone
(),
part_id
))
{
if
self
.done
.insert
((
import
.src.value
.clone
(),
part_id
))
{
if
let
Some
(
dep
)
=
self
.loader
.load
(
&
import
.src.value
,
part_id
)
?
{
if
let
Some
(
dep
)
=
self
.loader
.load
(
&
import
.src.value
,
part_id
)
?
{
let
mut
dep
=
self
.merge_recursively
(
dep
)
?
;
let
mut
dep
=
self
.merge_recursively
(
dep
)
?
;
...
...
turbopack/crates/turbopack-ecmascript/src/tree_shake/mod.rs
View file @
0219ed9e
...
@@ -17,9 +17,7 @@ use turbo_tasks::{FxIndexSet, ResolvedVc, ValueToString, Vc};
...
@@ -17,9 +17,7 @@ use turbo_tasks::{FxIndexSet, ResolvedVc, ValueToString, Vc};
use
turbopack_core
::{
ident
::
AssetIdent
,
resolve
::
ModulePart
,
source
::
Source
};
use
turbopack_core
::{
ident
::
AssetIdent
,
resolve
::
ModulePart
,
source
::
Source
};
use
self
::
graph
::{
DepGraph
,
ItemData
,
ItemId
,
ItemIdGroupKind
,
Mode
,
SplitModuleResult
};
use
self
::
graph
::{
DepGraph
,
ItemData
,
ItemId
,
ItemIdGroupKind
,
Mode
,
SplitModuleResult
};
pub
(
crate
)
use
self
::
graph
::{
pub
(
crate
)
use
self
::
graph
::{
create_turbopack_part_id_assert
,
find_turbopack_part_id_in_asserts
};
PartId
,
create_turbopack_part_id_assert
,
find_turbopack_part_id_in_asserts
,
};
use
crate
::{
use
crate
::{
EcmascriptModuleAsset
,
EcmascriptParsable
,
analyzer
::
graph
::
EvalContext
,
parse
::
ParseResult
,
EcmascriptModuleAsset
,
EcmascriptParsable
,
analyzer
::
graph
::
EvalContext
,
parse
::
ParseResult
,
};
};
...
@@ -450,7 +448,7 @@ pub(crate) enum SplitResult {
...
@@ -450,7 +448,7 @@ pub(crate) enum SplitResult {
modules
:
Vec
<
ResolvedVc
<
ParseResult
>>
,
modules
:
Vec
<
ResolvedVc
<
ParseResult
>>
,
#[turbo_tasks(trace_ignore)]
#[turbo_tasks(trace_ignore)]
deps
:
FxHashMap
<
u32
,
Vec
<
PartId
>>
,
deps
:
FxHashMap
<
u32
,
Vec
<
(
u32
,
bool
)
>>
,
#[turbo_tasks(debug_ignore,
trace_ignore)]
#[turbo_tasks(debug_ignore,
trace_ignore)]
star_reexports
:
Vec
<
ExportAll
>
,
star_reexports
:
Vec
<
ExportAll
>
,
...
@@ -642,6 +640,7 @@ pub(crate) async fn part_of_module(
...
@@ -642,6 +640,7 @@ pub(crate) async fn part_of_module(
.collect
::
<
Vec
<
_
>>
();
.collect
::
<
Vec
<
_
>>
();
export_names
.sort
();
export_names
.sort
();
if
let
Some
(
evaluation_id
)
=
entrypoints
.get
(
&
Key
::
ModuleEvaluation
)
{
module
module
.body
.body
.push
(
ModuleItem
::
ModuleDecl
(
ModuleDecl
::
Import
(
ImportDecl
{
.push
(
ModuleItem
::
ModuleDecl
(
ModuleDecl
::
Import
(
ImportDecl
{
...
@@ -650,10 +649,12 @@ pub(crate) async fn part_of_module(
...
@@ -650,10 +649,12 @@ pub(crate) async fn part_of_module(
src
:
Box
::
new
(
TURBOPACK_PART_IMPORT_SOURCE
.into
()),
src
:
Box
::
new
(
TURBOPACK_PART_IMPORT_SOURCE
.into
()),
type_only
:
false
,
type_only
:
false
,
with
:
Some
(
Box
::
new
(
create_turbopack_part_id_assert
(
with
:
Some
(
Box
::
new
(
create_turbopack_part_id_assert
(
PartId
::
ModuleEvaluation
,
*
evaluation_id
,
true
,
))),
))),
phase
:
Default
::
default
(),
phase
:
Default
::
default
(),
})));
})));
}
let
specifiers
=
export_names
let
specifiers
=
export_names
.into_iter
()
.into_iter
()
...
@@ -671,6 +672,7 @@ pub(crate) async fn part_of_module(
...
@@ -671,6 +672,7 @@ pub(crate) async fn part_of_module(
})
})
.collect
::
<
Vec
<
_
>>
();
.collect
::
<
Vec
<
_
>>
();
if
let
Some
(
exports_id
)
=
entrypoints
.get
(
&
Key
::
Exports
)
{
module
module
.body
.body
.push
(
ModuleItem
::
ModuleDecl
(
ModuleDecl
::
ExportNamed
(
.push
(
ModuleItem
::
ModuleDecl
(
ModuleDecl
::
ExportNamed
(
...
@@ -680,10 +682,12 @@ pub(crate) async fn part_of_module(
...
@@ -680,10 +682,12 @@ pub(crate) async fn part_of_module(
src
:
Some
(
Box
::
new
(
TURBOPACK_PART_IMPORT_SOURCE
.into
())),
src
:
Some
(
Box
::
new
(
TURBOPACK_PART_IMPORT_SOURCE
.into
())),
type_only
:
false
,
type_only
:
false
,
with
:
Some
(
Box
::
new
(
create_turbopack_part_id_assert
(
with
:
Some
(
Box
::
new
(
create_turbopack_part_id_assert
(
PartId
::
Exports
,
*
exports_id
,
false
,
))),
))),
},
},
)));
)));
}
module
.body
.extend
(
star_reexports
.iter
()
.map
(|
export_all
|
{
module
.body
.extend
(
star_reexports
.iter
()
.map
(|
export_all
|
{
ModuleItem
::
ModuleDecl
(
ModuleDecl
::
ExportAll
(
export_all
.clone
()))
ModuleItem
::
ModuleDecl
(
ModuleDecl
::
ExportAll
(
export_all
.clone
()))
...
...
turbopack/crates/turbopack-ecmascript/src/tree_shake/part/module.rs
View file @
0219ed9e
use
anyhow
::
Result
;
use
anyhow
::
{
Result
,
bail
}
;
use
turbo_rcstr
::{
RcStr
,
rcstr
};
use
turbo_rcstr
::{
RcStr
,
rcstr
};
use
turbo_tasks
::{
ResolvedVc
,
Vc
};
use
turbo_tasks
::{
ResolvedVc
,
Vc
};
use
turbopack_core
::{
use
turbopack_core
::{
chunk
::{
AsyncModuleInfo
,
ChunkableModule
,
ChunkingContext
,
EvaluatableAsset
},
chunk
::{
AsyncModuleInfo
,
ChunkableModule
,
ChunkingContext
,
EvaluatableAsset
},
context
::
ProcessResult
,
ident
::
AssetIdent
,
ident
::
AssetIdent
,
module
::{
Module
,
ModuleSideEffects
},
module
::{
Module
,
ModuleSideEffects
},
module_graph
::
ModuleGraph
,
module_graph
::
ModuleGraph
,
...
@@ -116,6 +117,13 @@ impl EcmascriptModulePartAsset {
...
@@ -116,6 +117,13 @@ impl EcmascriptModulePartAsset {
/// of the module.
/// of the module.
#[turbo_tasks
::
function]
#[turbo_tasks
::
function]
fn
new_raw
(
module
:
ResolvedVc
<
EcmascriptModuleAsset
>
,
part
:
ModulePart
)
->
Vc
<
Self
>
{
fn
new_raw
(
module
:
ResolvedVc
<
EcmascriptModuleAsset
>
,
part
:
ModulePart
)
->
Vc
<
Self
>
{
debug_assert!
(
matches!
(
part
,
// The generated facade
ModulePart
::
Facade
|
// The internal part
ModulePart
::
Internal
(
..
)
));
Self
{
Self
{
full_module
:
module
,
full_module
:
module
,
part
,
part
,
...
@@ -128,10 +136,7 @@ impl EcmascriptModulePartAsset {
...
@@ -128,10 +136,7 @@ impl EcmascriptModulePartAsset {
module
:
ResolvedVc
<
EcmascriptModuleAsset
>
,
module
:
ResolvedVc
<
EcmascriptModuleAsset
>
,
part
:
ModulePart
,
part
:
ModulePart
,
)
->
Result
<
Vc
<
Self
>>
{
)
->
Result
<
Vc
<
Self
>>
{
if
matches!
(
if
matches!
(
part
,
ModulePart
::
Internal
(
..
)
|
ModulePart
::
Facade
)
{
part
,
ModulePart
::
Internal
(
..
)
|
ModulePart
::
Facade
|
ModulePart
::
Exports
)
{
return
Ok
(
Self
::
new_raw
(
*
module
,
part
));
return
Ok
(
Self
::
new_raw
(
*
module
,
part
));
}
}
...
@@ -144,39 +149,65 @@ impl EcmascriptModulePartAsset {
...
@@ -144,39 +149,65 @@ impl EcmascriptModulePartAsset {
#[turbo_tasks
::
function]
#[turbo_tasks
::
function]
pub
async
fn
select_part
(
pub
async
fn
select_part
(
module
:
Vc
<
EcmascriptModuleAsset
>
,
module
:
Resolved
Vc
<
EcmascriptModuleAsset
>
,
part
:
ModulePart
,
part
:
ModulePart
,
)
->
Result
<
Vc
<
Box
<
dyn
EcmascriptChunkPlaceable
>
>>
{
)
->
Result
<
Vc
<
ProcessResult
>>
{
let
SplitResult
::
Ok
{
entrypoints
,
..
}
=
&*
split_module
(
module
)
.await
?
else
{
let
SplitResult
::
Ok
{
entrypoints
,
..
}
=
&*
split_module
(
*
module
)
.await
?
else
{
return
Ok
(
Vc
::
upcast
(
module
));
return
Ok
(
ProcessResult
::
Module
(
ResolvedVc
::
upcast
(
module
))
.cell
(
));
};
};
match
part
{
match
part
{
ModulePart
::
Evaluation
=>
{
ModulePart
::
Evaluation
=>
{
// We resolve the module evaluation here
to prevent duplicate assets.
// We resolve the module evaluation here
let
idx
=
*
entrypoints
.get
(
&
Key
::
ModuleEvaluation
)
.unwrap
();
if
let
Some
(
&
idx
)
=
entrypoints
.get
(
&
Key
::
ModuleEvaluation
)
{
return
Ok
(
Vc
::
upcast
(
return
Ok
(
ProcessResult
::
Module
(
Resolved
Vc
::
upcast
(
EcmascriptModulePartAsset
::
new_with_resolved_part
(
EcmascriptModulePartAsset
::
new_with_resolved_part
(
module
,
*
module
,
ModulePart
::
internal
(
idx
),
ModulePart
::
internal
(
idx
),
),
)
));
.to_resolved
()
.await
?
,
))
.cell
());
}
else
{
return
Ok
(
ProcessResult
::
Ignore
.cell
());
}
}
ModulePart
::
Exports
=>
{
// We resolve the exports here
if
let
Some
(
&
idx
)
=
entrypoints
.get
(
&
Key
::
Exports
)
{
return
Ok
(
ProcessResult
::
Module
(
ResolvedVc
::
upcast
(
EcmascriptModulePartAsset
::
new_with_resolved_part
(
*
module
,
ModulePart
::
internal
(
idx
),
)
.to_resolved
()
.await
?
,
))
.cell
());
}
else
{
return
Ok
(
ProcessResult
::
Ignore
.cell
());
}
}
}
ModulePart
::
Export
(
export
)
=>
{
ModulePart
::
Export
(
export
)
=>
{
if
entrypoints
.contains_key
(
&
Key
::
Export
(
export
.clone
()))
{
if
entrypoints
.contains_key
(
&
Key
::
Export
(
export
.clone
()))
{
return
Ok
(
Vc
::
upcast
(
return
Ok
(
ProcessResult
::
Module
(
Resolved
Vc
::
upcast
(
EcmascriptModulePartAsset
::
new_with_resolved_part
(
EcmascriptModulePartAsset
::
new_with_resolved_part
(
module
,
*
module
,
ModulePart
::
Export
(
export
),
ModulePart
::
Export
(
export
),
),
)
));
.to_resolved
()
.await
?
,
))
.cell
());
}
}
let
source_module
=
Vc
::
upcast
(
module
);
let
source_module
=
Resolved
Vc
::
upcast
(
module
);
let
FollowExportsWithSideEffectsResult
{
let
FollowExportsWithSideEffectsResult
{
side_effects
,
side_effects
,
result
,
result
,
}
=
&*
follow_reexports_with_side_effects
(
source_module
,
export
.clone
())
.await
?
;
}
=
&*
follow_reexports_with_side_effects
(
*
source_module
,
export
.clone
())
.await
?
;
let
FollowExportsResult
{
let
FollowExportsResult
{
module
:
final_module
,
module
:
final_module
,
export_name
:
new_export
,
export_name
:
new_export
,
...
@@ -206,22 +237,27 @@ impl EcmascriptModulePartAsset {
...
@@ -206,22 +237,27 @@ impl EcmascriptModulePartAsset {
)
)
};
};
if
side_effects
.is_empty
()
{
if
side_effects
.is_empty
()
{
return
Ok
(
*
final_module
);
return
Ok
(
ProcessResult
::
Module
(
ResolvedVc
::
upcast
(
final_module
))
.cell
()
);
}
}
let
side_effects_module
=
SideEffectsModule
::
new
(
let
side_effects_module
=
SideEffectsModule
::
new
(
module
,
*
module
,
ModulePart
::
Export
(
export
),
ModulePart
::
Export
(
export
),
*
final_module
,
*
final_module
,
side_effects
.iter
()
.map
(|
v
|
**
v
)
.collect
(),
side_effects
.iter
()
.map
(|
v
|
**
v
)
.collect
(),
);
)
return
Ok
(
Vc
::
upcast
(
side_effects_module
));
.to_resolved
()
.await
?
;
return
Ok
(
ProcessResult
::
Module
(
ResolvedVc
::
upcast
(
side_effects_module
))
.cell
());
}
}
_
=>
(),
_
=>
(),
}
}
Ok
(
Vc
::
upcast
(
Ok
(
ProcessResult
::
Module
(
ResolvedVc
::
upcast
(
EcmascriptModulePartAsset
::
new_with_resolved_part
(
module
,
part
.clone
()),
EcmascriptModulePartAsset
::
new_with_resolved_part
(
*
module
,
part
.clone
())
.to_resolved
()
.await
?
,
))
))
.cell
())
}
}
#[turbo_tasks
::
function]
#[turbo_tasks
::
function]
...
@@ -320,13 +356,30 @@ impl Module for EcmascriptModulePartAsset {
...
@@ -320,13 +356,30 @@ impl Module for EcmascriptModulePartAsset {
))
))
};
};
if
let
ModulePart
::
Facade
=
self
.part
{
match
self
.part
{
ModulePart
::
Facade
=>
{
let
SplitResult
::
Ok
{
entrypoints
,
..
}
=
&*
split_module
(
*
self
.full_module
)
.await
?
else
{
bail!
(
"Facade part requires split module to have entrypoints"
)
};
// Facade depends on evaluation and re-exports
// Facade depends on evaluation and re-exports
let
mut
references
=
vec!
[];
let
mut
references
=
vec!
[];
if
entrypoints
.contains_key
(
&
Key
::
ModuleEvaluation
)
{
references
.push
(
part_dep
(
ModulePart
::
evaluation
())
.to_resolved
()
.await
?
);
references
.push
(
part_dep
(
ModulePart
::
evaluation
())
.to_resolved
()
.await
?
);
}
if
entrypoints
.contains_key
(
&
Key
::
Exports
)
{
references
.push
(
part_dep
(
ModulePart
::
exports
())
.to_resolved
()
.await
?
);
references
.push
(
part_dep
(
ModulePart
::
exports
())
.to_resolved
()
.await
?
);
}
return
Ok
(
Vc
::
cell
(
references
));
return
Ok
(
Vc
::
cell
(
references
));
}
}
ModulePart
::
Evaluation
=>
{
// Evaluation part is the fake empty evaluation part with no dependencies
// It's only used when there is no internal evaluation part.
return
Ok
(
Vc
::
cell
(
vec!
[]));
}
_
=>
{}
}
let
analyze
=
analyze
(
*
self
.full_module
,
self
.part
.clone
());
let
analyze
=
analyze
(
*
self
.full_module
,
self
.part
.clone
());
...
@@ -334,13 +387,25 @@ impl Module for EcmascriptModulePartAsset {
...
@@ -334,13 +387,25 @@ impl Module for EcmascriptModulePartAsset {
}
}
#[turbo_tasks
::
function]
#[turbo_tasks
::
function]
async
fn
side_effects
(
&
self
)
->
Vc
<
ModuleSideEffects
>
{
async
fn
side_effects
(
&
self
)
->
Result
<
Vc
<
ModuleSideEffects
>>
{
match
self
.part
{
let
SplitResult
::
Ok
{
entrypoints
,
..
}
=
&*
split_module
(
*
self
.full_module
)
.await
?
else
{
ModulePart
::
Exports
|
ModulePart
::
Export
(
..
)
=>
{
return
Ok
(
self
.full_module
.side_effects
());
ModuleSideEffects
::
SideEffectFree
.cell
()
};
let
evaluation
=
entrypoints
.get
(
&
Key
::
ModuleEvaluation
);
Ok
(
match
self
.part
{
ModulePart
::
Internal
(
idx
)
=>
{
if
Some
(
&
idx
)
==
evaluation
{
ModuleSideEffects
::
SideEffectful
.cell
()
}
else
{
ModuleSideEffects
::
ModuleEvaluationIsSideEffectFree
.cell
()
}
}
}
_
=>
self
.full_module
.side_effects
(),
ModulePart
::
Facade
=>
ModuleSideEffects
::
ModuleEvaluationIsSideEffectFree
.cell
(),
_
=>
{
unreachable!
();
}
}
})
}
}
}
}
...
...
turbopack/crates/turbopack-ecmascript/tests/tree-shaker/analyzer/1/output.md
View file @
0219ed9e
...
@@ -548,16 +548,16 @@ export { foo };
...
@@ -548,16 +548,16 @@ export { foo };
## Part 12
## Part 12
```
js
```
js
export
{
external1
}
from
"__TURBOPACK_PART__"
assert
{
export
{
external1
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export external1"
__turbopack_part__
:
-
9
};
};
export
{
external2
}
from
"__TURBOPACK_PART__"
assert
{
export
{
external2
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export external2"
__turbopack_part__
:
-
10
};
};
export
{
foobar
}
from
"__TURBOPACK_PART__"
assert
{
export
{
foobar
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export foobar"
__turbopack_part__
:
-
10
};
};
export
{
foo
}
from
"__TURBOPACK_PART__"
assert
{
export
{
foo
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export foo"
__turbopack_part__
:
-
11
};
};
```
```
...
@@ -753,16 +753,16 @@ export { foobar };
...
@@ -753,16 +753,16 @@ export { foobar };
## Part 12
## Part 12
```
js
```
js
export
{
foo
}
from
"__TURBOPACK_PART__"
assert
{
export
{
foo
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export foo"
__turbopack_part__
:
-
3
};
};
export
{
external1
}
from
"__TURBOPACK_PART__"
assert
{
export
{
external1
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export external1"
__turbopack_part__
:
-
9
};
};
export
{
external2
}
from
"__TURBOPACK_PART__"
assert
{
export
{
external2
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export external2"
__turbopack_part__
:
-
10
};
};
export
{
foobar
}
from
"__TURBOPACK_PART__"
assert
{
export
{
foobar
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export foobar"
__turbopack_part__
:
-
11
};
};
```
```
...
...
turbopack/crates/turbopack-ecmascript/tests/tree-shaker/analyzer/2/output.md
View file @
0219ed9e
...
@@ -563,16 +563,16 @@ export { foo };
...
@@ -563,16 +563,16 @@ export { foo };
## Part 12
## Part 12
```
js
```
js
export
{
external1
}
from
"__TURBOPACK_PART__"
assert
{
export
{
external1
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export external1"
__turbopack_part__
:
-
0
};
};
export
{
external2
}
from
"__TURBOPACK_PART__"
assert
{
export
{
external2
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export external2"
__turbopack_part__
:
-
10
};
};
export
{
foobar
}
from
"__TURBOPACK_PART__"
assert
{
export
{
foobar
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export foobar"
__turbopack_part__
:
-
10
};
};
export
{
foo
}
from
"__TURBOPACK_PART__"
assert
{
export
{
foo
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export foo"
__turbopack_part__
:
-
11
};
};
```
```
...
@@ -767,16 +767,16 @@ export { foobar };
...
@@ -767,16 +767,16 @@ export { foobar };
## Part 12
## Part 12
```
js
```
js
export
{
external1
}
from
"__TURBOPACK_PART__"
assert
{
export
{
external1
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export external1"
__turbopack_part__
:
-
0
};
};
export
{
foo
}
from
"__TURBOPACK_PART__"
assert
{
export
{
foo
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export foo"
__turbopack_part__
:
-
4
};
};
export
{
external2
}
from
"__TURBOPACK_PART__"
assert
{
export
{
external2
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export external2"
__turbopack_part__
:
-
10
};
};
export
{
foobar
}
from
"__TURBOPACK_PART__"
assert
{
export
{
foobar
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export foobar"
__turbopack_part__
:
-
11
};
};
```
```
...
...
turbopack/crates/turbopack-ecmascript/tests/tree-shaker/analyzer/3/output.md
View file @
0219ed9e
...
@@ -477,13 +477,13 @@ export { c2_2 };
...
@@ -477,13 +477,13 @@ export { c2_2 };
## Part 9
## Part 9
```
js
```
js
export
{
c1_1
}
from
"__TURBOPACK_PART__"
assert
{
export
{
c1_1
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export c1_1"
__turbopack_part__
:
-
6
};
};
export
{
c1_3
}
from
"__TURBOPACK_PART__"
assert
{
export
{
c1_3
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export c1_3"
__turbopack_part__
:
-
7
};
};
export
{
c2_2
}
from
"__TURBOPACK_PART__"
assert
{
export
{
c2_2
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export c2_2"
__turbopack_part__
:
-
8
};
};
```
```
...
@@ -625,13 +625,13 @@ export { c2_2 };
...
@@ -625,13 +625,13 @@ export { c2_2 };
## Part 6
## Part 6
```
js
```
js
export
{
c1_1
}
from
"__TURBOPACK_PART__"
assert
{
export
{
c1_1
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export c1_1"
__turbopack_part__
:
-
3
};
};
export
{
c1_3
}
from
"__TURBOPACK_PART__"
assert
{
export
{
c1_3
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export c1_3"
__turbopack_part__
:
-
4
};
};
export
{
c2_2
}
from
"__TURBOPACK_PART__"
assert
{
export
{
c2_2
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export c2_2"
__turbopack_part__
:
-
5
};
};
```
```
...
...
turbopack/crates/turbopack-ecmascript/tests/tree-shaker/analyzer/amphtml-document/output.md
View file @
0219ed9e
...
@@ -454,7 +454,7 @@ export { };
...
@@ -454,7 +454,7 @@ export { };
## Part 11
## Part 11
```
js
```
js
export
{
default
}
from
"__TURBOPACK_PART__"
assert
{
export
{
default
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export default"
__turbopack_part__
:
-
10
};
};
```
```
...
@@ -681,7 +681,7 @@ export { };
...
@@ -681,7 +681,7 @@ export { };
## Part 11
## Part 11
```
js
```
js
export
{
default
}
from
"__TURBOPACK_PART__"
assert
{
export
{
default
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export default"
__turbopack_part__
:
-
10
};
};
```
```
...
...
turbopack/crates/turbopack-ecmascript/tests/tree-shaker/analyzer/app-route/output.md
View file @
0219ed9e
...
@@ -542,22 +542,22 @@ export { routeModule };
...
@@ -542,22 +542,22 @@ export { routeModule };
## Part 14
## Part 14
```
js
```
js
export
{
originalPathname
}
from
"__TURBOPACK_PART__"
assert
{
export
{
originalPathname
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export originalPathname"
__turbopack_part__
:
-
10
};
};
export
{
patchFetch
}
from
"__TURBOPACK_PART__"
assert
{
export
{
patchFetch
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export patchFetch"
__turbopack_part__
:
-
11
};
};
export
{
serverHooks
}
from
"__TURBOPACK_PART__"
assert
{
export
{
serverHooks
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export serverHooks"
__turbopack_part__
:
-
11
};
};
export
{
workAsyncStorage
}
from
"__TURBOPACK_PART__"
assert
{
export
{
workAsyncStorage
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export workAsyncStorage"
__turbopack_part__
:
-
11
};
};
export
{
requestAsyncStorage
}
from
"__TURBOPACK_PART__"
assert
{
export
{
requestAsyncStorage
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export requestAsyncStorage"
__turbopack_part__
:
-
12
};
};
export
{
routeModule
}
from
"__TURBOPACK_PART__"
assert
{
export
{
routeModule
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export routeModule"
__turbopack_part__
:
-
13
};
};
```
```
...
@@ -802,22 +802,22 @@ export { workAsyncStorage };
...
@@ -802,22 +802,22 @@ export { workAsyncStorage };
## Part 16
## Part 16
```
js
```
js
export
{
originalPathname
}
from
"__TURBOPACK_PART__"
assert
{
export
{
originalPathname
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export originalPathname"
__turbopack_part__
:
-
10
};
};
export
{
patchFetch
}
from
"__TURBOPACK_PART__"
assert
{
export
{
patchFetch
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export patchFetch"
__turbopack_part__
:
-
11
};
};
export
{
requestAsyncStorage
}
from
"__TURBOPACK_PART__"
assert
{
export
{
requestAsyncStorage
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export requestAsyncStorage"
__turbopack_part__
:
-
12
};
};
export
{
routeModule
}
from
"__TURBOPACK_PART__"
assert
{
export
{
routeModule
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export routeModule"
__turbopack_part__
:
-
13
};
};
export
{
serverHooks
}
from
"__TURBOPACK_PART__"
assert
{
export
{
serverHooks
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export serverHooks"
__turbopack_part__
:
-
14
};
};
export
{
workAsyncStorage
}
from
"__TURBOPACK_PART__"
assert
{
export
{
workAsyncStorage
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export workAsyncStorage"
__turbopack_part__
:
-
15
};
};
```
```
...
...
turbopack/crates/turbopack-ecmascript/tests/tree-shaker/analyzer/combined-export/output.md
View file @
0219ed9e
...
@@ -112,10 +112,10 @@ export { b as b } from "__TURBOPACK_VAR__" assert {
...
@@ -112,10 +112,10 @@ export { b as b } from "__TURBOPACK_VAR__" assert {
## Part 2
## Part 2
```
js
```
js
export
{
a
}
from
"__TURBOPACK_PART__"
assert
{
export
{
a
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export a"
__turbopack_part__
:
-
0
};
};
export
{
b
}
from
"__TURBOPACK_PART__"
assert
{
export
{
b
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export b"
__turbopack_part__
:
-
1
};
};
```
```
...
@@ -167,10 +167,10 @@ export { b as b } from "__TURBOPACK_VAR__" assert {
...
@@ -167,10 +167,10 @@ export { b as b } from "__TURBOPACK_VAR__" assert {
## Part 2
## Part 2
```
js
```
js
export
{
a
}
from
"__TURBOPACK_PART__"
assert
{
export
{
a
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export a"
__turbopack_part__
:
-
0
};
};
export
{
b
}
from
"__TURBOPACK_PART__"
assert
{
export
{
b
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export b"
__turbopack_part__
:
-
1
};
};
```
```
...
...
turbopack/crates/turbopack-ecmascript/tests/tree-shaker/analyzer/complex/output.md
View file @
0219ed9e
...
@@ -484,16 +484,16 @@ export { cat };
...
@@ -484,16 +484,16 @@ export { cat };
## Part 7
## Part 7
```
js
```
js
export
{
dogRef
}
from
"__TURBOPACK_PART__"
assert
{
export
{
dogRef
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export dogRef"
__turbopack_part__
:
-
2
};
};
export
{
initialCat
}
from
"__TURBOPACK_PART__"
assert
{
export
{
initialCat
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export initialCat"
__turbopack_part__
:
-
4
};
};
export
{
getChimera
}
from
"__TURBOPACK_PART__"
assert
{
export
{
getChimera
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export getChimera"
__turbopack_part__
:
-
5
};
};
export
{
cat
}
from
"__TURBOPACK_PART__"
assert
{
export
{
cat
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export cat"
__turbopack_part__
:
-
6
};
};
```
```
...
@@ -680,16 +680,16 @@ export { cat };
...
@@ -680,16 +680,16 @@ export { cat };
## Part 9
## Part 9
```
js
```
js
export
{
dogRef
}
from
"__TURBOPACK_PART__"
assert
{
export
{
dogRef
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export dogRef"
__turbopack_part__
:
-
3
};
};
export
{
initialCat
}
from
"__TURBOPACK_PART__"
assert
{
export
{
initialCat
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export initialCat"
__turbopack_part__
:
-
6
};
};
export
{
getChimera
}
from
"__TURBOPACK_PART__"
assert
{
export
{
getChimera
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export getChimera"
__turbopack_part__
:
-
7
};
};
export
{
cat
}
from
"__TURBOPACK_PART__"
assert
{
export
{
cat
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export cat"
__turbopack_part__
:
-
8
};
};
```
```
...
...
turbopack/crates/turbopack-ecmascript/tests/tree-shaker/analyzer/export-named/output.md
View file @
0219ed9e
...
@@ -90,7 +90,7 @@ export { };
...
@@ -90,7 +90,7 @@ export { };
## Part 1
## Part 1
```
js
```
js
export
{
fakeCat
}
from
"__TURBOPACK_PART__"
assert
{
export
{
fakeCat
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export fakeCat"
__turbopack_part__
:
-
0
};
};
```
```
...
@@ -133,7 +133,7 @@ export { };
...
@@ -133,7 +133,7 @@ export { };
## Part 1
## Part 1
```
js
```
js
export
{
fakeCat
}
from
"__TURBOPACK_PART__"
assert
{
export
{
fakeCat
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export fakeCat"
__turbopack_part__
:
-
0
};
};
```
```
...
...
turbopack/crates/turbopack-ecmascript/tests/tree-shaker/analyzer/failed-1/output.md
View file @
0219ed9e
...
@@ -352,13 +352,13 @@ export { sendMessage as f } from "__TURBOPACK_VAR__" assert {
...
@@ -352,13 +352,13 @@ export { sendMessage as f } from "__TURBOPACK_VAR__" assert {
## Part 5
## Part 5
```
js
```
js
export
{
connectHMR
}
from
"__TURBOPACK_PART__"
assert
{
export
{
connectHMR
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export connectHMR"
__turbopack_part__
:
-
2
};
};
export
{
addMessageListener
}
from
"__TURBOPACK_PART__"
assert
{
export
{
addMessageListener
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export addMessageListener"
__turbopack_part__
:
-
3
};
};
export
{
sendMessage
}
from
"__TURBOPACK_PART__"
assert
{
export
{
sendMessage
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export sendMessage"
__turbopack_part__
:
-
4
};
};
```
```
...
@@ -505,13 +505,13 @@ export { sendMessage as f } from "__TURBOPACK_VAR__" assert {
...
@@ -505,13 +505,13 @@ export { sendMessage as f } from "__TURBOPACK_VAR__" assert {
## Part 5
## Part 5
```
js
```
js
export
{
connectHMR
}
from
"__TURBOPACK_PART__"
assert
{
export
{
connectHMR
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export connectHMR"
__turbopack_part__
:
-
2
};
};
export
{
addMessageListener
}
from
"__TURBOPACK_PART__"
assert
{
export
{
addMessageListener
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export addMessageListener"
__turbopack_part__
:
-
3
};
};
export
{
sendMessage
}
from
"__TURBOPACK_PART__"
assert
{
export
{
sendMessage
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export sendMessage"
__turbopack_part__
:
-
4
};
};
```
```
...
...
turbopack/crates/turbopack-ecmascript/tests/tree-shaker/analyzer/failed-2/output.md
View file @
0219ed9e
...
@@ -914,28 +914,28 @@ export { createPostponedAbortSignal as k } from "__TURBOPACK_VAR__" assert {
...
@@ -914,28 +914,28 @@ export { createPostponedAbortSignal as k } from "__TURBOPACK_VAR__" assert {
## Part 17
## Part 17
```
js
```
js
export
{
createPrerenderState
}
from
"__TURBOPACK_PART__"
assert
{
export
{
createPrerenderState
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export createPrerenderState"
__turbopack_part__
:
-
9
};
};
export
{
markCurrentScopeAsDynamic
}
from
"__TURBOPACK_PART__"
assert
{
export
{
markCurrentScopeAsDynamic
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export markCurrentScopeAsDynamic"
__turbopack_part__
:
-
10
};
};
export
{
trackDynamicDataAccessed
}
from
"__TURBOPACK_PART__"
assert
{
export
{
trackDynamicDataAccessed
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export trackDynamicDataAccessed"
__turbopack_part__
:
-
11
};
};
export
{
Postpone
}
from
"__TURBOPACK_PART__"
assert
{
export
{
Postpone
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export Postpone"
__turbopack_part__
:
-
12
};
};
export
{
trackDynamicFetch
}
from
"__TURBOPACK_PART__"
assert
{
export
{
trackDynamicFetch
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export trackDynamicFetch"
__turbopack_part__
:
-
13
};
};
export
{
usedDynamicAPIs
}
from
"__TURBOPACK_PART__"
assert
{
export
{
usedDynamicAPIs
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export usedDynamicAPIs"
__turbopack_part__
:
-
14
};
};
export
{
formatDynamicAPIAccesses
}
from
"__TURBOPACK_PART__"
assert
{
export
{
formatDynamicAPIAccesses
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export formatDynamicAPIAccesses"
__turbopack_part__
:
-
15
};
};
export
{
createPostponedAbortSignal
}
from
"__TURBOPACK_PART__"
assert
{
export
{
createPostponedAbortSignal
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export createPostponedAbortSignal"
__turbopack_part__
:
-
16
};
};
```
```
...
@@ -1325,28 +1325,28 @@ export { createPostponedAbortSignal as k } from "__TURBOPACK_VAR__" assert {
...
@@ -1325,28 +1325,28 @@ export { createPostponedAbortSignal as k } from "__TURBOPACK_VAR__" assert {
## Part 19
## Part 19
```
js
```
js
export
{
createPrerenderState
}
from
"__TURBOPACK_PART__"
assert
{
export
{
createPrerenderState
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export createPrerenderState"
__turbopack_part__
:
-
9
};
};
export
{
markCurrentScopeAsDynamic
}
from
"__TURBOPACK_PART__"
assert
{
export
{
markCurrentScopeAsDynamic
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export markCurrentScopeAsDynamic"
__turbopack_part__
:
-
10
};
};
export
{
trackDynamicDataAccessed
}
from
"__TURBOPACK_PART__"
assert
{
export
{
trackDynamicDataAccessed
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export trackDynamicDataAccessed"
__turbopack_part__
:
-
11
};
};
export
{
Postpone
}
from
"__TURBOPACK_PART__"
assert
{
export
{
Postpone
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export Postpone"
__turbopack_part__
:
-
12
};
};
export
{
trackDynamicFetch
}
from
"__TURBOPACK_PART__"
assert
{
export
{
trackDynamicFetch
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export trackDynamicFetch"
__turbopack_part__
:
-
13
};
};
export
{
usedDynamicAPIs
}
from
"__TURBOPACK_PART__"
assert
{
export
{
usedDynamicAPIs
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export usedDynamicAPIs"
__turbopack_part__
:
-
15
};
};
export
{
formatDynamicAPIAccesses
}
from
"__TURBOPACK_PART__"
assert
{
export
{
formatDynamicAPIAccesses
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export formatDynamicAPIAccesses"
__turbopack_part__
:
-
16
};
};
export
{
createPostponedAbortSignal
}
from
"__TURBOPACK_PART__"
assert
{
export
{
createPostponedAbortSignal
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export createPostponedAbortSignal"
__turbopack_part__
:
-
18
};
};
```
```
...
...
turbopack/crates/turbopack-ecmascript/tests/tree-shaker/analyzer/failed-3/output.md
View file @
0219ed9e
...
@@ -1332,10 +1332,10 @@ export { structuredError };
...
@@ -1332,10 +1332,10 @@ export { structuredError };
## Part 12
## Part 12
```
js
```
js
export
{
IPC
}
from
"__TURBOPACK_PART__"
assert
{
export
{
IPC
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export IPC"
__turbopack_part__
:
-
10
};
};
export
{
structuredError
}
from
"__TURBOPACK_PART__"
assert
{
export
{
structuredError
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export structuredError"
__turbopack_part__
:
-
11
};
};
```
```
...
@@ -1698,10 +1698,10 @@ export { structuredError };
...
@@ -1698,10 +1698,10 @@ export { structuredError };
## Part 12
## Part 12
```
js
```
js
export
{
IPC
}
from
"__TURBOPACK_PART__"
assert
{
export
{
IPC
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export IPC"
__turbopack_part__
:
-
10
};
};
export
{
structuredError
}
from
"__TURBOPACK_PART__"
assert
{
export
{
structuredError
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export structuredError"
__turbopack_part__
:
-
11
};
};
```
```
...
...
turbopack/crates/turbopack-ecmascript/tests/tree-shaker/analyzer/grouping/output.md
View file @
0219ed9e
...
@@ -353,10 +353,10 @@ export { x };
...
@@ -353,10 +353,10 @@ export { x };
## Part 6
## Part 6
```
js
```
js
export
{
y
}
from
"__TURBOPACK_PART__"
assert
{
export
{
y
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export y"
__turbopack_part__
:
-
4
};
};
export
{
x
}
from
"__TURBOPACK_PART__"
assert
{
export
{
x
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export x"
__turbopack_part__
:
-
5
};
};
```
```
...
@@ -463,10 +463,10 @@ export { x };
...
@@ -463,10 +463,10 @@ export { x };
## Part 7
## Part 7
```
js
```
js
export
{
y
}
from
"__TURBOPACK_PART__"
assert
{
export
{
y
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export y"
__turbopack_part__
:
-
5
};
};
export
{
x
}
from
"__TURBOPACK_PART__"
assert
{
export
{
x
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export x"
__turbopack_part__
:
-
6
};
};
```
```
...
...
turbopack/crates/turbopack-ecmascript/tests/tree-shaker/analyzer/ipc-evaluate/output.md
View file @
0219ed9e
...
@@ -357,7 +357,7 @@ export { };
...
@@ -357,7 +357,7 @@ export { };
## Part 3
## Part 3
```
js
```
js
export
{
run
}
from
"__TURBOPACK_PART__"
assert
{
export
{
run
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export run"
__turbopack_part__
:
-
2
};
};
```
```
...
@@ -617,7 +617,7 @@ export { };
...
@@ -617,7 +617,7 @@ export { };
## Part 3
## Part 3
```
js
```
js
export
{
run
}
from
"__TURBOPACK_PART__"
assert
{
export
{
run
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export run"
__turbopack_part__
:
-
2
};
};
```
```
...
...
turbopack/crates/turbopack-ecmascript/tests/tree-shaker/analyzer/ipc-index/output.md
View file @
0219ed9e
...
@@ -1332,10 +1332,10 @@ export { structuredError };
...
@@ -1332,10 +1332,10 @@ export { structuredError };
## Part 12
## Part 12
```
js
```
js
export
{
IPC
}
from
"__TURBOPACK_PART__"
assert
{
export
{
IPC
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export IPC"
__turbopack_part__
:
-
10
};
};
export
{
structuredError
}
from
"__TURBOPACK_PART__"
assert
{
export
{
structuredError
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export structuredError"
__turbopack_part__
:
-
11
};
};
```
```
...
@@ -1698,10 +1698,10 @@ export { structuredError };
...
@@ -1698,10 +1698,10 @@ export { structuredError };
## Part 12
## Part 12
```
js
```
js
export
{
IPC
}
from
"__TURBOPACK_PART__"
assert
{
export
{
IPC
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export IPC"
__turbopack_part__
:
-
10
};
};
export
{
structuredError
}
from
"__TURBOPACK_PART__"
assert
{
export
{
structuredError
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export structuredError"
__turbopack_part__
:
-
11
};
};
```
```
...
...
turbopack/crates/turbopack-ecmascript/tests/tree-shaker/analyzer/let-bug-1/output.md
View file @
0219ed9e
...
@@ -301,10 +301,10 @@ export { getClientComponentLoaderMetrics as e } from "__TURBOPACK_VAR__" assert
...
@@ -301,10 +301,10 @@ export { getClientComponentLoaderMetrics as e } from "__TURBOPACK_VAR__" assert
## Part 5
## Part 5
```
js
```
js
export
{
wrapClientComponentLoader
}
from
"__TURBOPACK_PART__"
assert
{
export
{
wrapClientComponentLoader
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export wrapClientComponentLoader"
__turbopack_part__
:
-
3
};
};
export
{
getClientComponentLoaderMetrics
}
from
"__TURBOPACK_PART__"
assert
{
export
{
getClientComponentLoaderMetrics
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export getClientComponentLoaderMetrics"
__turbopack_part__
:
-
4
};
};
```
```
...
@@ -437,10 +437,10 @@ export { getClientComponentLoaderMetrics as e } from "__TURBOPACK_VAR__" assert
...
@@ -437,10 +437,10 @@ export { getClientComponentLoaderMetrics as e } from "__TURBOPACK_VAR__" assert
## Part 5
## Part 5
```
js
```
js
export
{
wrapClientComponentLoader
}
from
"__TURBOPACK_PART__"
assert
{
export
{
wrapClientComponentLoader
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export wrapClientComponentLoader"
__turbopack_part__
:
-
3
};
};
export
{
getClientComponentLoaderMetrics
}
from
"__TURBOPACK_PART__"
assert
{
export
{
getClientComponentLoaderMetrics
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export getClientComponentLoaderMetrics"
__turbopack_part__
:
-
4
};
};
```
```
...
...
turbopack/crates/turbopack-ecmascript/tests/tree-shaker/analyzer/logger/output.md
View file @
0219ed9e
...
@@ -301,10 +301,10 @@ export { getClientComponentLoaderMetrics as e } from "__TURBOPACK_VAR__" assert
...
@@ -301,10 +301,10 @@ export { getClientComponentLoaderMetrics as e } from "__TURBOPACK_VAR__" assert
## Part 5
## Part 5
```
js
```
js
export
{
wrapClientComponentLoader
}
from
"__TURBOPACK_PART__"
assert
{
export
{
wrapClientComponentLoader
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export wrapClientComponentLoader"
__turbopack_part__
:
-
3
};
};
export
{
getClientComponentLoaderMetrics
}
from
"__TURBOPACK_PART__"
assert
{
export
{
getClientComponentLoaderMetrics
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export getClientComponentLoaderMetrics"
__turbopack_part__
:
-
4
};
};
```
```
...
@@ -437,10 +437,10 @@ export { getClientComponentLoaderMetrics as e } from "__TURBOPACK_VAR__" assert
...
@@ -437,10 +437,10 @@ export { getClientComponentLoaderMetrics as e } from "__TURBOPACK_VAR__" assert
## Part 5
## Part 5
```
js
```
js
export
{
wrapClientComponentLoader
}
from
"__TURBOPACK_PART__"
assert
{
export
{
wrapClientComponentLoader
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export wrapClientComponentLoader"
__turbopack_part__
:
-
3
};
};
export
{
getClientComponentLoaderMetrics
}
from
"__TURBOPACK_PART__"
assert
{
export
{
getClientComponentLoaderMetrics
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export getClientComponentLoaderMetrics"
__turbopack_part__
:
-
4
};
};
```
```
...
...
turbopack/crates/turbopack-ecmascript/tests/tree-shaker/analyzer/mui-sys/output.md
View file @
0219ed9e
...
@@ -1571,43 +1571,43 @@ export { gridTemplateRows };
...
@@ -1571,43 +1571,43 @@ export { gridTemplateRows };
## Part 38
## Part 38
```
js
```
js
export
{
gap
}
from
"__TURBOPACK_PART__"
assert
{
export
{
gap
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export gap"
__turbopack_part__
:
-
13
};
};
export
{
columnGap
}
from
"__TURBOPACK_PART__"
assert
{
export
{
columnGap
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export columnGap"
__turbopack_part__
:
-
16
};
};
export
{
rowGap
}
from
"__TURBOPACK_PART__"
assert
{
export
{
rowGap
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export rowGap"
__turbopack_part__
:
-
19
};
};
export
{
gridArea
}
from
"__TURBOPACK_PART__"
assert
{
export
{
gridArea
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export gridArea"
__turbopack_part__
:
-
28
};
};
export
{
default
}
from
"__TURBOPACK_PART__"
assert
{
export
{
default
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export default"
__turbopack_part__
:
-
29
};
};
export
{
gridAutoColumns
}
from
"__TURBOPACK_PART__"
assert
{
export
{
gridAutoColumns
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export gridAutoColumns"
__turbopack_part__
:
-
30
};
};
export
{
gridAutoFlow
}
from
"__TURBOPACK_PART__"
assert
{
export
{
gridAutoFlow
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export gridAutoFlow"
__turbopack_part__
:
-
31
};
};
export
{
gridAutoRows
}
from
"__TURBOPACK_PART__"
assert
{
export
{
gridAutoRows
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export gridAutoRows"
__turbopack_part__
:
-
32
};
};
export
{
gridColumn
}
from
"__TURBOPACK_PART__"
assert
{
export
{
gridColumn
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export gridColumn"
__turbopack_part__
:
-
33
};
};
export
{
gridRow
}
from
"__TURBOPACK_PART__"
assert
{
export
{
gridRow
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export gridRow"
__turbopack_part__
:
-
34
};
};
export
{
gridTemplateAreas
}
from
"__TURBOPACK_PART__"
assert
{
export
{
gridTemplateAreas
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export gridTemplateAreas"
__turbopack_part__
:
-
35
};
};
export
{
gridTemplateColumns
}
from
"__TURBOPACK_PART__"
assert
{
export
{
gridTemplateColumns
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export gridTemplateColumns"
__turbopack_part__
:
-
36
};
};
export
{
gridTemplateRows
}
from
"__TURBOPACK_PART__"
assert
{
export
{
gridTemplateRows
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export gridTemplateRows"
__turbopack_part__
:
-
37
};
};
```
```
...
@@ -2249,43 +2249,43 @@ export { gridTemplateRows };
...
@@ -2249,43 +2249,43 @@ export { gridTemplateRows };
## Part 38
## Part 38
```
js
```
js
export
{
gap
}
from
"__TURBOPACK_PART__"
assert
{
export
{
gap
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export gap"
__turbopack_part__
:
-
13
};
};
export
{
columnGap
}
from
"__TURBOPACK_PART__"
assert
{
export
{
columnGap
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export columnGap"
__turbopack_part__
:
-
16
};
};
export
{
rowGap
}
from
"__TURBOPACK_PART__"
assert
{
export
{
rowGap
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export rowGap"
__turbopack_part__
:
-
19
};
};
export
{
gridArea
}
from
"__TURBOPACK_PART__"
assert
{
export
{
gridArea
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export gridArea"
__turbopack_part__
:
-
28
};
};
export
{
default
}
from
"__TURBOPACK_PART__"
assert
{
export
{
default
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export default"
__turbopack_part__
:
-
29
};
};
export
{
gridAutoColumns
}
from
"__TURBOPACK_PART__"
assert
{
export
{
gridAutoColumns
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export gridAutoColumns"
__turbopack_part__
:
-
30
};
};
export
{
gridAutoFlow
}
from
"__TURBOPACK_PART__"
assert
{
export
{
gridAutoFlow
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export gridAutoFlow"
__turbopack_part__
:
-
31
};
};
export
{
gridAutoRows
}
from
"__TURBOPACK_PART__"
assert
{
export
{
gridAutoRows
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export gridAutoRows"
__turbopack_part__
:
-
32
};
};
export
{
gridColumn
}
from
"__TURBOPACK_PART__"
assert
{
export
{
gridColumn
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export gridColumn"
__turbopack_part__
:
-
33
};
};
export
{
gridRow
}
from
"__TURBOPACK_PART__"
assert
{
export
{
gridRow
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export gridRow"
__turbopack_part__
:
-
34
};
};
export
{
gridTemplateAreas
}
from
"__TURBOPACK_PART__"
assert
{
export
{
gridTemplateAreas
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export gridTemplateAreas"
__turbopack_part__
:
-
35
};
};
export
{
gridTemplateColumns
}
from
"__TURBOPACK_PART__"
assert
{
export
{
gridTemplateColumns
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export gridTemplateColumns"
__turbopack_part__
:
-
36
};
};
export
{
gridTemplateRows
}
from
"__TURBOPACK_PART__"
assert
{
export
{
gridTemplateRows
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export gridTemplateRows"
__turbopack_part__
:
-
37
};
};
```
```
...
...
turbopack/crates/turbopack-ecmascript/tests/tree-shaker/analyzer/multi-export/output.md
View file @
0219ed9e
...
@@ -112,10 +112,10 @@ export { cat as b } from "__TURBOPACK_VAR__" assert {
...
@@ -112,10 +112,10 @@ export { cat as b } from "__TURBOPACK_VAR__" assert {
## Part 2
## Part 2
```
js
```
js
export
{
DOG
}
from
"__TURBOPACK_PART__"
assert
{
export
{
DOG
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export DOG"
__turbopack_part__
:
-
0
};
};
export
{
cat
}
from
"__TURBOPACK_PART__"
assert
{
export
{
cat
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export cat"
__turbopack_part__
:
-
1
};
};
```
```
...
@@ -167,10 +167,10 @@ export { cat as b } from "__TURBOPACK_VAR__" assert {
...
@@ -167,10 +167,10 @@ export { cat as b } from "__TURBOPACK_VAR__" assert {
## Part 2
## Part 2
```
js
```
js
export
{
DOG
}
from
"__TURBOPACK_PART__"
assert
{
export
{
DOG
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export DOG"
__turbopack_part__
:
-
0
};
};
export
{
cat
}
from
"__TURBOPACK_PART__"
assert
{
export
{
cat
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export cat"
__turbopack_part__
:
-
1
};
};
```
```
...
...
turbopack/crates/turbopack-ecmascript/tests/tree-shaker/analyzer/nanoid/output.md
View file @
0219ed9e
...
@@ -613,19 +613,19 @@ export { urlAlphabet };
...
@@ -613,19 +613,19 @@ export { urlAlphabet };
## Part 15
## Part 15
```
js
```
js
export
{
customAlphabet
}
from
"__TURBOPACK_PART__"
assert
{
export
{
customAlphabet
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export customAlphabet"
__turbopack_part__
:
-
9
};
};
export
{
customRandom
}
from
"__TURBOPACK_PART__"
assert
{
export
{
customRandom
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export customRandom"
__turbopack_part__
:
-
11
};
};
export
{
nanoid
}
from
"__TURBOPACK_PART__"
assert
{
export
{
nanoid
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export nanoid"
__turbopack_part__
:
-
12
};
};
export
{
random
}
from
"__TURBOPACK_PART__"
assert
{
export
{
random
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export random"
__turbopack_part__
:
-
13
};
};
export
{
urlAlphabet
}
from
"__TURBOPACK_PART__"
assert
{
export
{
urlAlphabet
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export urlAlphabet"
__turbopack_part__
:
-
14
};
};
```
```
...
@@ -890,19 +890,19 @@ export { urlAlphabet };
...
@@ -890,19 +890,19 @@ export { urlAlphabet };
## Part 15
## Part 15
```
js
```
js
export
{
customAlphabet
}
from
"__TURBOPACK_PART__"
assert
{
export
{
customAlphabet
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export customAlphabet"
__turbopack_part__
:
-
9
};
};
export
{
customRandom
}
from
"__TURBOPACK_PART__"
assert
{
export
{
customRandom
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export customRandom"
__turbopack_part__
:
-
11
};
};
export
{
nanoid
}
from
"__TURBOPACK_PART__"
assert
{
export
{
nanoid
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export nanoid"
__turbopack_part__
:
-
12
};
};
export
{
random
}
from
"__TURBOPACK_PART__"
assert
{
export
{
random
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export random"
__turbopack_part__
:
-
13
};
};
export
{
urlAlphabet
}
from
"__TURBOPACK_PART__"
assert
{
export
{
urlAlphabet
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export urlAlphabet"
__turbopack_part__
:
-
14
};
};
```
```
...
...
turbopack/crates/turbopack-ecmascript/tests/tree-shaker/analyzer/next-response/output.md
View file @
0219ed9e
...
@@ -571,7 +571,7 @@ export { };
...
@@ -571,7 +571,7 @@ export { };
## Part 1
## Part 1
```
js
```
js
export
{
NextResponse
}
from
"__TURBOPACK_PART__"
assert
{
export
{
NextResponse
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export NextResponse"
__turbopack_part__
:
-
0
};
};
```
```
...
@@ -870,7 +870,7 @@ export { };
...
@@ -870,7 +870,7 @@ export { };
## Part 1
## Part 1
```
js
```
js
export
{
NextResponse
}
from
"__TURBOPACK_PART__"
assert
{
export
{
NextResponse
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export NextResponse"
__turbopack_part__
:
-
0
};
};
```
```
...
...
turbopack/crates/turbopack-ecmascript/tests/tree-shaker/analyzer/nextjs-tracer/output.md
View file @
0219ed9e
...
@@ -1028,19 +1028,19 @@ export { rootSpanAttributesStore as i } from "__TURBOPACK_VAR__" assert {
...
@@ -1028,19 +1028,19 @@ export { rootSpanAttributesStore as i } from "__TURBOPACK_VAR__" assert {
## Part 14
## Part 14
```
js
```
js
export
{
getTracer
}
from
"__TURBOPACK_PART__"
assert
{
export
{
getTracer
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export getTracer"
__turbopack_part__
:
-
6
};
};
export
{
SpanStatusCode
}
from
"__TURBOPACK_PART__"
assert
{
export
{
SpanStatusCode
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export SpanStatusCode"
__turbopack_part__
:
-
9
};
};
export
{
BubbledError
}
from
"__TURBOPACK_PART__"
assert
{
export
{
BubbledError
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export BubbledError"
__turbopack_part__
:
-
10
};
};
export
{
SpanKind
}
from
"__TURBOPACK_PART__"
assert
{
export
{
SpanKind
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export SpanKind"
__turbopack_part__
:
-
11
};
};
export
{
isBubbledError
}
from
"__TURBOPACK_PART__"
assert
{
export
{
isBubbledError
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export isBubbledError"
__turbopack_part__
:
-
12
};
};
```
```
...
@@ -1650,19 +1650,19 @@ export { isBubbledError };
...
@@ -1650,19 +1650,19 @@ export { isBubbledError };
## Part 13
## Part 13
```
js
```
js
export
{
getTracer
}
from
"__TURBOPACK_PART__"
assert
{
export
{
getTracer
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export getTracer"
__turbopack_part__
:
-
6
};
};
export
{
SpanStatusCode
}
from
"__TURBOPACK_PART__"
assert
{
export
{
SpanStatusCode
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export SpanStatusCode"
__turbopack_part__
:
-
9
};
};
export
{
BubbledError
}
from
"__TURBOPACK_PART__"
assert
{
export
{
BubbledError
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export BubbledError"
__turbopack_part__
:
-
10
};
};
export
{
SpanKind
}
from
"__TURBOPACK_PART__"
assert
{
export
{
SpanKind
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export SpanKind"
__turbopack_part__
:
-
11
};
};
export
{
isBubbledError
}
from
"__TURBOPACK_PART__"
assert
{
export
{
isBubbledError
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export isBubbledError"
__turbopack_part__
:
-
12
};
};
```
```
...
...
turbopack/crates/turbopack-ecmascript/tests/tree-shaker/analyzer/node-fetch/output.md
View file @
0219ed9e
...
@@ -175,7 +175,7 @@ export { };
...
@@ -175,7 +175,7 @@ export { };
## Part 3
## Part 3
```
js
```
js
export
{
default
}
from
"__TURBOPACK_PART__"
assert
{
export
{
default
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export default"
__turbopack_part__
:
-
2
};
};
```
```
...
@@ -252,7 +252,7 @@ export { };
...
@@ -252,7 +252,7 @@ export { };
## Part 3
## Part 3
```
js
```
js
export
{
default
}
from
"__TURBOPACK_PART__"
assert
{
export
{
default
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export default"
__turbopack_part__
:
-
2
};
};
```
```
...
...
turbopack/crates/turbopack-ecmascript/tests/tree-shaker/analyzer/otel-core/output.md
View file @
0219ed9e
...
@@ -279,10 +279,10 @@ export { getEnvWithoutDefaults as b } from "__TURBOPACK_VAR__" assert {
...
@@ -279,10 +279,10 @@ export { getEnvWithoutDefaults as b } from "__TURBOPACK_VAR__" assert {
## Part 7
## Part 7
```
js
```
js
export
{
getEnv
}
from
"__TURBOPACK_PART__"
assert
{
export
{
getEnv
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export getEnv"
__turbopack_part__
:
-
5
};
};
export
{
getEnvWithoutDefaults
}
from
"__TURBOPACK_PART__"
assert
{
export
{
getEnvWithoutDefaults
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export getEnvWithoutDefaults"
__turbopack_part__
:
-
6
};
};
```
```
...
@@ -393,10 +393,10 @@ export { getEnvWithoutDefaults as b } from "__TURBOPACK_VAR__" assert {
...
@@ -393,10 +393,10 @@ export { getEnvWithoutDefaults as b } from "__TURBOPACK_VAR__" assert {
## Part 7
## Part 7
```
js
```
js
export
{
getEnv
}
from
"__TURBOPACK_PART__"
assert
{
export
{
getEnv
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export getEnv"
__turbopack_part__
:
-
5
};
};
export
{
getEnvWithoutDefaults
}
from
"__TURBOPACK_PART__"
assert
{
export
{
getEnvWithoutDefaults
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export getEnvWithoutDefaults"
__turbopack_part__
:
-
6
};
};
```
```
...
...
turbopack/crates/turbopack-ecmascript/tests/tree-shaker/analyzer/route-handler/output.md
View file @
0219ed9e
...
@@ -157,10 +157,10 @@ export { runtime as b } from "__TURBOPACK_VAR__" assert {
...
@@ -157,10 +157,10 @@ export { runtime as b } from "__TURBOPACK_VAR__" assert {
## Part 2
## Part 2
```
js
```
js
export
{
GET
}
from
"__TURBOPACK_PART__"
assert
{
export
{
GET
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export GET"
__turbopack_part__
:
-
0
};
};
export
{
runtime
}
from
"__TURBOPACK_PART__"
assert
{
export
{
runtime
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export runtime"
__turbopack_part__
:
-
2
};
};
```
```
...
@@ -225,10 +225,10 @@ export { runtime as b } from "__TURBOPACK_VAR__" assert {
...
@@ -225,10 +225,10 @@ export { runtime as b } from "__TURBOPACK_VAR__" assert {
## Part 2
## Part 2
```
js
```
js
export
{
GET
}
from
"__TURBOPACK_PART__"
assert
{
export
{
GET
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export GET"
__turbopack_part__
:
-
0
};
};
export
{
runtime
}
from
"__TURBOPACK_PART__"
assert
{
export
{
runtime
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export runtime"
__turbopack_part__
:
-
2
};
};
```
```
...
...
turbopack/crates/turbopack-ecmascript/tests/tree-shaker/analyzer/route-kind/output.md
View file @
0219ed9e
...
@@ -107,7 +107,7 @@ export { };
...
@@ -107,7 +107,7 @@ export { };
## Part 1
## Part 1
```
js
```
js
export
{
RouteKind
}
from
"__TURBOPACK_PART__"
assert
{
export
{
RouteKind
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export RouteKind"
__turbopack_part__
:
-
0
};
};
```
```
...
@@ -160,7 +160,7 @@ export { };
...
@@ -160,7 +160,7 @@ export { };
## Part 1
## Part 1
```
js
```
js
export
{
RouteKind
}
from
"__TURBOPACK_PART__"
assert
{
export
{
RouteKind
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export RouteKind"
__turbopack_part__
:
-
0
};
};
```
```
...
...
turbopack/crates/turbopack-ecmascript/tests/tree-shaker/analyzer/shared-2/output.md
View file @
0219ed9e
...
@@ -318,13 +318,13 @@ export { a };
...
@@ -318,13 +318,13 @@ export { a };
## Part 6
## Part 6
```
js
```
js
export
{
order
}
from
"__TURBOPACK_PART__"
assert
{
export
{
order
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export order"
__turbopack_part__
:
-
2
};
};
export
{
b
}
from
"__TURBOPACK_PART__"
assert
{
export
{
b
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export b"
__turbopack_part__
:
-
4
};
};
export
{
a
}
from
"__TURBOPACK_PART__"
assert
{
export
{
a
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export a"
__turbopack_part__
:
-
5
};
};
```
```
...
@@ -444,13 +444,13 @@ export { a };
...
@@ -444,13 +444,13 @@ export { a };
## Part 6
## Part 6
```
js
```
js
export
{
order
}
from
"__TURBOPACK_PART__"
assert
{
export
{
order
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export order"
__turbopack_part__
:
-
2
};
};
export
{
b
}
from
"__TURBOPACK_PART__"
assert
{
export
{
b
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export b"
__turbopack_part__
:
-
4
};
};
export
{
a
}
from
"__TURBOPACK_PART__"
assert
{
export
{
a
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export a"
__turbopack_part__
:
-
5
};
};
```
```
...
...
turbopack/crates/turbopack-ecmascript/tests/tree-shaker/analyzer/shared-and-side-effects/output.md
View file @
0219ed9e
...
@@ -314,10 +314,10 @@ export { a };
...
@@ -314,10 +314,10 @@ export { a };
## Part 4
## Part 4
```
js
```
js
export
{
b
}
from
"__TURBOPACK_PART__"
assert
{
export
{
b
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export b"
__turbopack_part__
:
-
2
};
};
export
{
a
}
from
"__TURBOPACK_PART__"
assert
{
export
{
a
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export a"
__turbopack_part__
:
-
3
};
};
```
```
...
@@ -453,10 +453,10 @@ export { a };
...
@@ -453,10 +453,10 @@ export { a };
## Part 7
## Part 7
```
js
```
js
export
{
b
}
from
"__TURBOPACK_PART__"
assert
{
export
{
b
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export b"
__turbopack_part__
:
-
5
};
};
export
{
a
}
from
"__TURBOPACK_PART__"
assert
{
export
{
a
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export a"
__turbopack_part__
:
-
6
};
};
```
```
...
...
turbopack/crates/turbopack-ecmascript/tests/tree-shaker/analyzer/shared-regression/output.md
View file @
0219ed9e
...
@@ -318,13 +318,13 @@ export { a };
...
@@ -318,13 +318,13 @@ export { a };
## Part 6
## Part 6
```
js
```
js
export
{
order
}
from
"__TURBOPACK_PART__"
assert
{
export
{
order
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export order"
__turbopack_part__
:
-
2
};
};
export
{
b
}
from
"__TURBOPACK_PART__"
assert
{
export
{
b
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export b"
__turbopack_part__
:
-
4
};
};
export
{
a
}
from
"__TURBOPACK_PART__"
assert
{
export
{
a
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export a"
__turbopack_part__
:
-
5
};
};
```
```
...
@@ -444,13 +444,13 @@ export { a };
...
@@ -444,13 +444,13 @@ export { a };
## Part 6
## Part 6
```
js
```
js
export
{
order
}
from
"__TURBOPACK_PART__"
assert
{
export
{
order
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export order"
__turbopack_part__
:
-
2
};
};
export
{
b
}
from
"__TURBOPACK_PART__"
assert
{
export
{
b
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export b"
__turbopack_part__
:
-
4
};
};
export
{
a
}
from
"__TURBOPACK_PART__"
assert
{
export
{
a
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export a"
__turbopack_part__
:
-
5
};
};
```
```
...
...
turbopack/crates/turbopack-ecmascript/tests/tree-shaker/analyzer/simple-vars-1/output.md
View file @
0219ed9e
...
@@ -112,10 +112,10 @@ export { b as b } from "__TURBOPACK_VAR__" assert {
...
@@ -112,10 +112,10 @@ export { b as b } from "__TURBOPACK_VAR__" assert {
## Part 2
## Part 2
```
js
```
js
export
{
a
}
from
"__TURBOPACK_PART__"
assert
{
export
{
a
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export a"
__turbopack_part__
:
-
0
};
};
export
{
b
}
from
"__TURBOPACK_PART__"
assert
{
export
{
b
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export b"
__turbopack_part__
:
-
1
};
};
```
```
...
@@ -167,10 +167,10 @@ export { b as b } from "__TURBOPACK_VAR__" assert {
...
@@ -167,10 +167,10 @@ export { b as b } from "__TURBOPACK_VAR__" assert {
## Part 2
## Part 2
```
js
```
js
export
{
a
}
from
"__TURBOPACK_PART__"
assert
{
export
{
a
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export a"
__turbopack_part__
:
-
0
};
};
export
{
b
}
from
"__TURBOPACK_PART__"
assert
{
export
{
b
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export b"
__turbopack_part__
:
-
1
};
};
```
```
...
...
turbopack/crates/turbopack-ecmascript/tests/tree-shaker/analyzer/simple/output.md
View file @
0219ed9e
...
@@ -172,10 +172,10 @@ export { DOG as d } from "__TURBOPACK_VAR__" assert {
...
@@ -172,10 +172,10 @@ export { DOG as d } from "__TURBOPACK_VAR__" assert {
## Part 3
## Part 3
```
js
```
js
export
{
CHIMERA
}
from
"__TURBOPACK_PART__"
assert
{
export
{
CHIMERA
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export CHIMERA"
__turbopack_part__
:
-
1
};
};
export
{
DOG
}
from
"__TURBOPACK_PART__"
assert
{
export
{
DOG
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export DOG"
__turbopack_part__
:
-
2
};
};
```
```
...
@@ -245,10 +245,10 @@ export { DOG as d } from "__TURBOPACK_VAR__" assert {
...
@@ -245,10 +245,10 @@ export { DOG as d } from "__TURBOPACK_VAR__" assert {
## Part 3
## Part 3
```
js
```
js
export
{
CHIMERA
}
from
"__TURBOPACK_PART__"
assert
{
export
{
CHIMERA
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export CHIMERA"
__turbopack_part__
:
-
1
};
};
export
{
DOG
}
from
"__TURBOPACK_PART__"
assert
{
export
{
DOG
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export DOG"
__turbopack_part__
:
-
2
};
};
```
```
...
...
turbopack/crates/turbopack-ecmascript/tests/tree-shaker/analyzer/template-pages/output.md
View file @
0219ed9e
...
@@ -1240,40 +1240,40 @@ export { unstable_getStaticProps };
...
@@ -1240,40 +1240,40 @@ export { unstable_getStaticProps };
## Part 35
## Part 35
```
js
```
js
export
{
routeModule
}
from
"__TURBOPACK_PART__"
assert
{
export
{
routeModule
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export routeModule"
__turbopack_part__
:
-
23
};
};
export
{
default
}
from
"__TURBOPACK_PART__"
assert
{
export
{
default
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export default"
__turbopack_part__
:
-
24
};
};
export
{
config
}
from
"__TURBOPACK_PART__"
assert
{
export
{
config
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export config"
__turbopack_part__
:
-
25
};
};
export
{
getServerSideProps
}
from
"__TURBOPACK_PART__"
assert
{
export
{
getServerSideProps
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export getServerSideProps"
__turbopack_part__
:
-
26
};
};
export
{
getStaticPaths
}
from
"__TURBOPACK_PART__"
assert
{
export
{
getStaticPaths
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export getStaticPaths"
__turbopack_part__
:
-
27
};
};
export
{
getStaticProps
}
from
"__TURBOPACK_PART__"
assert
{
export
{
getStaticProps
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export getStaticProps"
__turbopack_part__
:
-
28
};
};
export
{
reportWebVitals
}
from
"__TURBOPACK_PART__"
assert
{
export
{
reportWebVitals
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export reportWebVitals"
__turbopack_part__
:
-
29
};
};
export
{
unstable_getServerProps
}
from
"__TURBOPACK_PART__"
assert
{
export
{
unstable_getServerProps
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export unstable_getServerProps"
__turbopack_part__
:
-
30
};
};
export
{
unstable_getServerSideProps
}
from
"__TURBOPACK_PART__"
assert
{
export
{
unstable_getServerSideProps
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export unstable_getServerSideProps"
__turbopack_part__
:
-
31
};
};
export
{
unstable_getStaticParams
}
from
"__TURBOPACK_PART__"
assert
{
export
{
unstable_getStaticParams
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export unstable_getStaticParams"
__turbopack_part__
:
-
32
};
};
export
{
unstable_getStaticPaths
}
from
"__TURBOPACK_PART__"
assert
{
export
{
unstable_getStaticPaths
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export unstable_getStaticPaths"
__turbopack_part__
:
-
33
};
};
export
{
unstable_getStaticProps
}
from
"__TURBOPACK_PART__"
assert
{
export
{
unstable_getStaticProps
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export unstable_getStaticProps"
__turbopack_part__
:
-
34
};
};
```
```
...
@@ -1803,40 +1803,40 @@ export { unstable_getStaticProps };
...
@@ -1803,40 +1803,40 @@ export { unstable_getStaticProps };
## Part 35
## Part 35
```
js
```
js
export
{
routeModule
}
from
"__TURBOPACK_PART__"
assert
{
export
{
routeModule
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export routeModule"
__turbopack_part__
:
-
23
};
};
export
{
default
}
from
"__TURBOPACK_PART__"
assert
{
export
{
default
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export default"
__turbopack_part__
:
-
24
};
};
export
{
config
}
from
"__TURBOPACK_PART__"
assert
{
export
{
config
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export config"
__turbopack_part__
:
-
25
};
};
export
{
getServerSideProps
}
from
"__TURBOPACK_PART__"
assert
{
export
{
getServerSideProps
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export getServerSideProps"
__turbopack_part__
:
-
26
};
};
export
{
getStaticPaths
}
from
"__TURBOPACK_PART__"
assert
{
export
{
getStaticPaths
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export getStaticPaths"
__turbopack_part__
:
-
27
};
};
export
{
getStaticProps
}
from
"__TURBOPACK_PART__"
assert
{
export
{
getStaticProps
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export getStaticProps"
__turbopack_part__
:
-
28
};
};
export
{
reportWebVitals
}
from
"__TURBOPACK_PART__"
assert
{
export
{
reportWebVitals
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export reportWebVitals"
__turbopack_part__
:
-
29
};
};
export
{
unstable_getServerProps
}
from
"__TURBOPACK_PART__"
assert
{
export
{
unstable_getServerProps
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export unstable_getServerProps"
__turbopack_part__
:
-
30
};
};
export
{
unstable_getServerSideProps
}
from
"__TURBOPACK_PART__"
assert
{
export
{
unstable_getServerSideProps
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export unstable_getServerSideProps"
__turbopack_part__
:
-
31
};
};
export
{
unstable_getStaticParams
}
from
"__TURBOPACK_PART__"
assert
{
export
{
unstable_getStaticParams
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export unstable_getStaticParams"
__turbopack_part__
:
-
32
};
};
export
{
unstable_getStaticPaths
}
from
"__TURBOPACK_PART__"
assert
{
export
{
unstable_getStaticPaths
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export unstable_getStaticPaths"
__turbopack_part__
:
-
33
};
};
export
{
unstable_getStaticProps
}
from
"__TURBOPACK_PART__"
assert
{
export
{
unstable_getStaticProps
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export unstable_getStaticProps"
__turbopack_part__
:
-
34
};
};
```
```
...
...
turbopack/crates/turbopack-ecmascript/tests/tree-shaker/analyzer/test-config-1/output.md
View file @
0219ed9e
...
@@ -548,16 +548,16 @@ export { foo };
...
@@ -548,16 +548,16 @@ export { foo };
## Part 12
## Part 12
```
js
```
js
export
{
external1
}
from
"__TURBOPACK_PART__"
assert
{
export
{
external1
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export external1"
__turbopack_part__
:
-
9
};
};
export
{
external2
}
from
"__TURBOPACK_PART__"
assert
{
export
{
external2
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export external2"
__turbopack_part__
:
-
10
};
};
export
{
foobar
}
from
"__TURBOPACK_PART__"
assert
{
export
{
foobar
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export foobar"
__turbopack_part__
:
-
10
};
};
export
{
foo
}
from
"__TURBOPACK_PART__"
assert
{
export
{
foo
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export foo"
__turbopack_part__
:
-
11
};
};
```
```
...
@@ -753,16 +753,16 @@ export { foobar };
...
@@ -753,16 +753,16 @@ export { foobar };
## Part 12
## Part 12
```
js
```
js
export
{
foo
}
from
"__TURBOPACK_PART__"
assert
{
export
{
foo
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export foo"
__turbopack_part__
:
-
3
};
};
export
{
external1
}
from
"__TURBOPACK_PART__"
assert
{
export
{
external1
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export external1"
__turbopack_part__
:
-
9
};
};
export
{
external2
}
from
"__TURBOPACK_PART__"
assert
{
export
{
external2
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export external2"
__turbopack_part__
:
-
10
};
};
export
{
foobar
}
from
"__TURBOPACK_PART__"
assert
{
export
{
foobar
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export foobar"
__turbopack_part__
:
-
11
};
};
```
```
...
...
turbopack/crates/turbopack-ecmascript/tests/tree-shaker/analyzer/tla-1/output.md
View file @
0219ed9e
...
@@ -138,10 +138,10 @@ export { };
...
@@ -138,10 +138,10 @@ export { };
## Part 2
## Part 2
```
js
```
js
export
{
effect
}
from
"__TURBOPACK_PART__"
assert
{
export
{
effect
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export effect"
__turbopack_part__
:
-
0
};
};
export
{
effects
}
from
"__TURBOPACK_PART__"
assert
{
export
{
effects
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export effects"
__turbopack_part__
:
-
0
};
};
```
```
...
@@ -207,10 +207,10 @@ export { };
...
@@ -207,10 +207,10 @@ export { };
## Part 4
## Part 4
```
js
```
js
export
{
effect
}
from
"__TURBOPACK_PART__"
assert
{
export
{
effect
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export effect"
__turbopack_part__
:
-
1
};
};
export
{
effects
}
from
"__TURBOPACK_PART__"
assert
{
export
{
effects
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export effects"
__turbopack_part__
:
-
2
};
};
```
```
...
...
turbopack/crates/turbopack-ecmascript/tests/tree-shaker/analyzer/typeof-1/output.md
View file @
0219ed9e
...
@@ -198,7 +198,7 @@ export { };
...
@@ -198,7 +198,7 @@ export { };
## Part 1
## Part 1
```
js
```
js
export
{
GET
}
from
"__TURBOPACK_PART__"
assert
{
export
{
GET
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export GET"
__turbopack_part__
:
-
0
};
};
```
```
...
@@ -261,7 +261,7 @@ export { };
...
@@ -261,7 +261,7 @@ export { };
## Part 1
## Part 1
```
js
```
js
export
{
GET
}
from
"__TURBOPACK_PART__"
assert
{
export
{
GET
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export GET"
__turbopack_part__
:
-
0
};
};
```
```
...
...
turbopack/crates/turbopack-ecmascript/tests/tree-shaker/analyzer/write-order/output.md
View file @
0219ed9e
...
@@ -291,13 +291,13 @@ export { shared };
...
@@ -291,13 +291,13 @@ export { shared };
## Part 4
## Part 4
```
js
```
js
export
{
func
}
from
"__TURBOPACK_PART__"
assert
{
export
{
func
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export func"
__turbopack_part__
:
-
1
};
};
export
{
order
}
from
"__TURBOPACK_PART__"
assert
{
export
{
order
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export order"
__turbopack_part__
:
-
1
};
};
export
{
shared
}
from
"__TURBOPACK_PART__"
assert
{
export
{
shared
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export shared"
__turbopack_part__
:
-
3
};
};
```
```
...
@@ -422,13 +422,13 @@ export { shared };
...
@@ -422,13 +422,13 @@ export { shared };
## Part 6
## Part 6
```
js
```
js
export
{
func
}
from
"__TURBOPACK_PART__"
assert
{
export
{
func
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export func"
__turbopack_part__
:
-
1
};
};
export
{
order
}
from
"__TURBOPACK_PART__"
assert
{
export
{
order
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export order"
__turbopack_part__
:
-
4
};
};
export
{
shared
}
from
"__TURBOPACK_PART__"
assert
{
export
{
shared
}
from
"__TURBOPACK_PART__"
assert
{
__turbopack_part__
:
"export shared"
__turbopack_part__
:
-
5
};
};
```
```
...
...
turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/dynamic-import/output/bf321_tests_snapshot_basic-tree-shake_dynamic-import_input_lib_
a280e616
.js
→
turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/dynamic-import/output/bf321_tests_snapshot_basic-tree-shake_dynamic-import_input_lib_
63494f91
.js
View file @
0219ed9e
(
globalThis
[
"TURBOPACK"
]
||
(
globalThis
[
"TURBOPACK"
]
=
[])).
push
([
"output/bf321_tests_snapshot_basic-tree-shake_dynamic-import_input_lib_
a280e616
.js"
,
(
globalThis
[
"TURBOPACK"
]
||
(
globalThis
[
"TURBOPACK"
]
=
[])).
push
([
"output/bf321_tests_snapshot_basic-tree-shake_dynamic-import_input_lib_
63494f91
.js"
,
"[project]/turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/dynamic-import/input/lib.js [test] (ecmascript) <internal part 0>"
,
((
__turbopack_context__
)
=>
{
"[project]/turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/dynamic-import/input/lib.js [test] (ecmascript) <internal part 0>"
,
((
__turbopack_context__
)
=>
{
"use strict"
;
"use strict"
;
...
@@ -140,7 +140,7 @@ var __TURBOPACK__imported__module__$5b$project$5d2f$turbopack$2f$crates$2f$turbo
...
@@ -140,7 +140,7 @@ var __TURBOPACK__imported__module__$5b$project$5d2f$turbopack$2f$crates$2f$turbo
;
;
;
;
}),
}),
"[project]/turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/dynamic-import/input/lib.js [test] (ecmascript) <
exports
>"
,
((
__turbopack_context__
)
=>
{
"[project]/turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/dynamic-import/input/lib.js [test] (ecmascript) <
internal part 9
>"
,
((
__turbopack_context__
)
=>
{
"use strict"
;
"use strict"
;
__turbopack_context__
.
s
([
__turbopack_context__
.
s
([
...
@@ -167,19 +167,19 @@ var __TURBOPACK__imported__module__$5b$project$5d2f$turbopack$2f$crates$2f$turbo
...
@@ -167,19 +167,19 @@ var __TURBOPACK__imported__module__$5b$project$5d2f$turbopack$2f$crates$2f$turbo
__turbopack_context__
.
s
([
__turbopack_context__
.
s
([
"cat"
,
"cat"
,
()
=>
__TURBOPACK__imported__module__$5b$project$5d2f$turbopack$2f$crates$2f$turbopack$2d$tests$2f$tests$2f$snapshot$2f$basic$2d$tree$2d$shake$2f$dynamic$2d$import$2f$input$2f$lib$2e$js__$5b$test$5d$__$28$ecmascript$29$__$3c$
exports
$3e$__
[
"cat"
],
()
=>
__TURBOPACK__imported__module__$5b$project$5d2f$turbopack$2f$crates$2f$turbopack$2d$tests$2f$tests$2f$snapshot$2f$basic$2d$tree$2d$shake$2f$dynamic$2d$import$2f$input$2f$lib$2e$js__$5b$test$5d$__$28$ecmascript$29$__$3c$
internal__part__9
$3e$__
[
"cat"
],
"dogRef"
,
"dogRef"
,
()
=>
__TURBOPACK__imported__module__$5b$project$5d2f$turbopack$2f$crates$2f$turbopack$2d$tests$2f$tests$2f$snapshot$2f$basic$2d$tree$2d$shake$2f$dynamic$2d$import$2f$input$2f$lib$2e$js__$5b$test$5d$__$28$ecmascript$29$__$3c$
exports
$3e$__
[
"dogRef"
],
()
=>
__TURBOPACK__imported__module__$5b$project$5d2f$turbopack$2f$crates$2f$turbopack$2d$tests$2f$tests$2f$snapshot$2f$basic$2d$tree$2d$shake$2f$dynamic$2d$import$2f$input$2f$lib$2e$js__$5b$test$5d$__$28$ecmascript$29$__$3c$
internal__part__9
$3e$__
[
"dogRef"
],
"getChimera"
,
"getChimera"
,
()
=>
__TURBOPACK__imported__module__$5b$project$5d2f$turbopack$2f$crates$2f$turbopack$2d$tests$2f$tests$2f$snapshot$2f$basic$2d$tree$2d$shake$2f$dynamic$2d$import$2f$input$2f$lib$2e$js__$5b$test$5d$__$28$ecmascript$29$__$3c$
exports
$3e$__
[
"getChimera"
],
()
=>
__TURBOPACK__imported__module__$5b$project$5d2f$turbopack$2f$crates$2f$turbopack$2d$tests$2f$tests$2f$snapshot$2f$basic$2d$tree$2d$shake$2f$dynamic$2d$import$2f$input$2f$lib$2e$js__$5b$test$5d$__$28$ecmascript$29$__$3c$
internal__part__9
$3e$__
[
"getChimera"
],
"initialCat"
,
"initialCat"
,
()
=>
__TURBOPACK__imported__module__$5b$project$5d2f$turbopack$2f$crates$2f$turbopack$2d$tests$2f$tests$2f$snapshot$2f$basic$2d$tree$2d$shake$2f$dynamic$2d$import$2f$input$2f$lib$2e$js__$5b$test$5d$__$28$ecmascript$29$__$3c$
exports
$3e$__
[
"initialCat"
]
()
=>
__TURBOPACK__imported__module__$5b$project$5d2f$turbopack$2f$crates$2f$turbopack$2d$tests$2f$tests$2f$snapshot$2f$basic$2d$tree$2d$shake$2f$dynamic$2d$import$2f$input$2f$lib$2e$js__$5b$test$5d$__$28$ecmascript$29$__$3c$
internal__part__9
$3e$__
[
"initialCat"
]
]);
]);
var
__TURBOPACK__imported__module__$5b$project$5d2f$turbopack$2f$crates$2f$turbopack$2d$tests$2f$tests$2f$snapshot$2f$basic$2d$tree$2d$shake$2f$dynamic$2d$import$2f$input$2f$lib$2e$js__$5b$test$5d$__$28$ecmascript$29$__$3c$internal__part__2$3e$__
=
__turbopack_context__
.
i
(
"[project]/turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/dynamic-import/input/lib.js [test] (ecmascript) <internal part 2>"
);
var
__TURBOPACK__imported__module__$5b$project$5d2f$turbopack$2f$crates$2f$turbopack$2d$tests$2f$tests$2f$snapshot$2f$basic$2d$tree$2d$shake$2f$dynamic$2d$import$2f$input$2f$lib$2e$js__$5b$test$5d$__$28$ecmascript$29$__$3c$internal__part__2$3e$__
=
__turbopack_context__
.
i
(
"[project]/turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/dynamic-import/input/lib.js [test] (ecmascript) <internal part 2>"
);
var
__TURBOPACK__imported__module__$5b$project$5d2f$turbopack$2f$crates$2f$turbopack$2d$tests$2f$tests$2f$snapshot$2f$basic$2d$tree$2d$shake$2f$dynamic$2d$import$2f$input$2f$lib$2e$js__$5b$test$5d$__$28$ecmascript$29$__$3c$
exports$3e$__
=
__turbopack_context__
.
i
(
"[project]/turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/dynamic-import/input/lib.js [test] (ecmascript) <exports
>"
);
var
__TURBOPACK__imported__module__$5b$project$5d2f$turbopack$2f$crates$2f$turbopack$2d$tests$2f$tests$2f$snapshot$2f$basic$2d$tree$2d$shake$2f$dynamic$2d$import$2f$input$2f$lib$2e$js__$5b$test$5d$__$28$ecmascript$29$__$3c$
internal__part__9$3e$__
=
__turbopack_context__
.
i
(
"[project]/turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/dynamic-import/input/lib.js [test] (ecmascript) <internal part 9
>"
);
;
;
;
;
}),
}),
]);
]);
//# sourceMappingURL=bf321_tests_snapshot_basic-tree-shake_dynamic-import_input_lib_a280e616.js.map
//# sourceMappingURL=bf321_tests_snapshot_basic-tree-shake_dynamic-import_input_lib_63494f91.js.map
\ No newline at end of file
\ No newline at end of file
turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/dynamic-import/output/bf321_tests_snapshot_basic-tree-shake_dynamic-import_input_lib_
a280e616
.js.map
→
turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/dynamic-import/output/bf321_tests_snapshot_basic-tree-shake_dynamic-import_input_lib_
63494f91
.js.map
View file @
0219ed9e
File moved
turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/dynamic-import/output/bf321_tests_snapshot_basic-tree-shake_dynamic-import_input_lib_ee638b2a.js
View file @
0219ed9e
...
@@ -3,7 +3,7 @@
...
@@ -3,7 +3,7 @@
__turbopack_context__
.
v
((
parentImport
)
=>
{
__turbopack_context__
.
v
((
parentImport
)
=>
{
return
Promise
.
all
([
return
Promise
.
all
([
"output/bf321_tests_snapshot_basic-tree-shake_dynamic-import_input_lib_
a280e616
.js"
"output/bf321_tests_snapshot_basic-tree-shake_dynamic-import_input_lib_
63494f91
.js"
].
map
((
chunk
)
=>
__turbopack_context__
.
l
(
chunk
))).
then
(()
=>
{
].
map
((
chunk
)
=>
__turbopack_context__
.
l
(
chunk
))).
then
(()
=>
{
return
parentImport
(
"[project]/turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/dynamic-import/input/lib.js [test] (ecmascript)"
);
return
parentImport
(
"[project]/turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/dynamic-import/input/lib.js [test] (ecmascript)"
);
});
});
...
...
turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/export-namespace/output/780ce_turbopack-tests_tests_snapshot_basic-tree-shake_export-namespace_input_
c8f48bdf
._.js
→
turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/export-namespace/output/780ce_turbopack-tests_tests_snapshot_basic-tree-shake_export-namespace_input_
2100e737
._.js
View file @
0219ed9e
(
globalThis
[
"TURBOPACK"
]
||
(
globalThis
[
"TURBOPACK"
]
=
[])).
push
([
"output/780ce_turbopack-tests_tests_snapshot_basic-tree-shake_export-namespace_input_
c8f48bdf
._.js"
,
(
globalThis
[
"TURBOPACK"
]
||
(
globalThis
[
"TURBOPACK"
]
=
[])).
push
([
"output/780ce_turbopack-tests_tests_snapshot_basic-tree-shake_export-namespace_input_
2100e737
._.js"
,
"[project]/turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/export-namespace/input/lib.js [test] (ecmascript) <internal part 0>"
,
((
__turbopack_context__
)
=>
{
"[project]/turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/export-namespace/input/lib.js [test] (ecmascript) <internal part 0>"
,
((
__turbopack_context__
)
=>
{
"use strict"
;
"use strict"
;
...
@@ -140,7 +140,7 @@ var __TURBOPACK__imported__module__$5b$project$5d2f$turbopack$2f$crates$2f$turbo
...
@@ -140,7 +140,7 @@ var __TURBOPACK__imported__module__$5b$project$5d2f$turbopack$2f$crates$2f$turbo
;
;
;
;
}),
}),
"[project]/turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/export-namespace/input/lib.js [test] (ecmascript) <
exports
>"
,
((
__turbopack_context__
)
=>
{
"[project]/turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/export-namespace/input/lib.js [test] (ecmascript) <
internal part 9
>"
,
((
__turbopack_context__
)
=>
{
"use strict"
;
"use strict"
;
__turbopack_context__
.
s
([
__turbopack_context__
.
s
([
...
@@ -167,12 +167,12 @@ var __TURBOPACK__imported__module__$5b$project$5d2f$turbopack$2f$crates$2f$turbo
...
@@ -167,12 +167,12 @@ var __TURBOPACK__imported__module__$5b$project$5d2f$turbopack$2f$crates$2f$turbo
__turbopack_context__
.
s
([
__turbopack_context__
.
s
([
"a"
,
"a"
,
()
=>
__TURBOPACK__imported__module__$5b$project$5d2f$turbopack$2f$crates$2f$turbopack$2d$tests$2f$tests$2f$snapshot$2f$basic$2d$tree$2d$shake$2f$export$2d$namespace$2f$input$2f$lib$2e$js__$5b$test$5d$__$28$ecmascript$29$__$3c$
exports
$3e$__
,
()
=>
__TURBOPACK__imported__module__$5b$project$5d2f$turbopack$2f$crates$2f$turbopack$2d$tests$2f$tests$2f$snapshot$2f$basic$2d$tree$2d$shake$2f$export$2d$namespace$2f$input$2f$lib$2e$js__$5b$test$5d$__$28$ecmascript$29$__$3c$
internal__part__9
$3e$__
,
"lib"
,
"lib"
,
()
=>
__TURBOPACK__imported__module__$5b$project$5d2f$turbopack$2f$crates$2f$turbopack$2d$tests$2f$tests$2f$snapshot$2f$basic$2d$tree$2d$shake$2f$export$2d$namespace$2f$input$2f$lib$2e$js__$5b$test$5d$__$28$ecmascript$29$__$3c$
exports
$3e$__
()
=>
__TURBOPACK__imported__module__$5b$project$5d2f$turbopack$2f$crates$2f$turbopack$2d$tests$2f$tests$2f$snapshot$2f$basic$2d$tree$2d$shake$2f$export$2d$namespace$2f$input$2f$lib$2e$js__$5b$test$5d$__$28$ecmascript$29$__$3c$
internal__part__9
$3e$__
]);
]);
var
__TURBOPACK__imported__module__$5b$project$5d2f$turbopack$2f$crates$2f$turbopack$2d$tests$2f$tests$2f$snapshot$2f$basic$2d$tree$2d$shake$2f$export$2d$namespace$2f$input$2f$lib$2e$js__$5b$test$5d$__$28$ecmascript$29$__$3c$internal__part__2$3e$__
=
__turbopack_context__
.
i
(
"[project]/turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/export-namespace/input/lib.js [test] (ecmascript) <internal part 2>"
);
var
__TURBOPACK__imported__module__$5b$project$5d2f$turbopack$2f$crates$2f$turbopack$2d$tests$2f$tests$2f$snapshot$2f$basic$2d$tree$2d$shake$2f$export$2d$namespace$2f$input$2f$lib$2e$js__$5b$test$5d$__$28$ecmascript$29$__$3c$internal__part__2$3e$__
=
__turbopack_context__
.
i
(
"[project]/turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/export-namespace/input/lib.js [test] (ecmascript) <internal part 2>"
);
var
__TURBOPACK__imported__module__$5b$project$5d2f$turbopack$2f$crates$2f$turbopack$2d$tests$2f$tests$2f$snapshot$2f$basic$2d$tree$2d$shake$2f$export$2d$namespace$2f$input$2f$lib$2e$js__$5b$test$5d$__$28$ecmascript$29$__$3c$
exports$3e$__
=
__turbopack_context__
.
i
(
"[project]/turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/export-namespace/input/lib.js [test] (ecmascript) <exports
>"
);
var
__TURBOPACK__imported__module__$5b$project$5d2f$turbopack$2f$crates$2f$turbopack$2d$tests$2f$tests$2f$snapshot$2f$basic$2d$tree$2d$shake$2f$export$2d$namespace$2f$input$2f$lib$2e$js__$5b$test$5d$__$28$ecmascript$29$__$3c$
internal__part__9$3e$__
=
__turbopack_context__
.
i
(
"[project]/turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/export-namespace/input/lib.js [test] (ecmascript) <internal part 9
>"
);
;
;
;
;
;
;
...
@@ -189,4 +189,4 @@ console.log(__TURBOPACK__imported__module__$5b$project$5d2f$turbopack$2f$crates$
...
@@ -189,4 +189,4 @@ console.log(__TURBOPACK__imported__module__$5b$project$5d2f$turbopack$2f$crates$
}),
}),
]);
]);
//# sourceMappingURL=780ce_turbopack-tests_tests_snapshot_basic-tree-shake_export-namespace_input_c8f48bdf._.js.map
//# sourceMappingURL=780ce_turbopack-tests_tests_snapshot_basic-tree-shake_export-namespace_input_2100e737._.js.map
\ No newline at end of file
\ No newline at end of file
turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/export-namespace/output/780ce_turbopack-tests_tests_snapshot_basic-tree-shake_export-namespace_input_
c8f48bdf
._.js.map
→
turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/export-namespace/output/780ce_turbopack-tests_tests_snapshot_basic-tree-shake_export-namespace_input_
2100e737
._.js.map
View file @
0219ed9e
File moved
turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/export-namespace/output/ad3e4_tests_snapshot_basic-tree-shake_export-namespace_input_index_
2b1fc03b
.js
→
turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/export-namespace/output/ad3e4_tests_snapshot_basic-tree-shake_export-namespace_input_index_
fee7c584
.js
View file @
0219ed9e
(
globalThis
[
"TURBOPACK"
]
||
(
globalThis
[
"TURBOPACK"
]
=
[])).
push
([
(
globalThis
[
"TURBOPACK"
]
||
(
globalThis
[
"TURBOPACK"
]
=
[])).
push
([
"output/ad3e4_tests_snapshot_basic-tree-shake_export-namespace_input_index_
2b1fc03b
.js"
,
"output/ad3e4_tests_snapshot_basic-tree-shake_export-namespace_input_index_
fee7c584
.js"
,
{
"otherChunks"
:[
"output/780ce_turbopack-tests_tests_snapshot_basic-tree-shake_export-namespace_input_
c8f48bdf
._.js"
],
"runtimeModuleIds"
:[
"[project]/turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/export-namespace/input/index.js [test] (ecmascript)"
]}
{
"otherChunks"
:[
"output/780ce_turbopack-tests_tests_snapshot_basic-tree-shake_export-namespace_input_
2100e737
._.js"
],
"runtimeModuleIds"
:[
"[project]/turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/export-namespace/input/index.js [test] (ecmascript)"
]}
]);
]);
// Dummy runtime
// Dummy runtime
\ No newline at end of file
turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/export-namespace/output/bf321_tests_snapshot_basic-tree-shake_export-namespace_input_index_
2b1fc03b
.js.map
→
turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/export-namespace/output/bf321_tests_snapshot_basic-tree-shake_export-namespace_input_index_
fee7c584
.js.map
View file @
0219ed9e
File moved
turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/import-namespace/output/780ce_turbopack-tests_tests_snapshot_basic-tree-shake_import-namespace_input_
bba52bc8
._.js
→
turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/import-namespace/output/780ce_turbopack-tests_tests_snapshot_basic-tree-shake_import-namespace_input_
31731fc7
._.js
View file @
0219ed9e
(
globalThis
[
"TURBOPACK"
]
||
(
globalThis
[
"TURBOPACK"
]
=
[])).
push
([
"output/780ce_turbopack-tests_tests_snapshot_basic-tree-shake_import-namespace_input_
bba52bc8
._.js"
,
(
globalThis
[
"TURBOPACK"
]
||
(
globalThis
[
"TURBOPACK"
]
=
[])).
push
([
"output/780ce_turbopack-tests_tests_snapshot_basic-tree-shake_import-namespace_input_
31731fc7
._.js"
,
"[project]/turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/import-namespace/input/lib.js [test] (ecmascript) <internal part 0>"
,
((
__turbopack_context__
)
=>
{
"[project]/turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/import-namespace/input/lib.js [test] (ecmascript) <internal part 0>"
,
((
__turbopack_context__
)
=>
{
"use strict"
;
"use strict"
;
...
@@ -140,7 +140,7 @@ var __TURBOPACK__imported__module__$5b$project$5d2f$turbopack$2f$crates$2f$turbo
...
@@ -140,7 +140,7 @@ var __TURBOPACK__imported__module__$5b$project$5d2f$turbopack$2f$crates$2f$turbo
;
;
;
;
}),
}),
"[project]/turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/import-namespace/input/lib.js [test] (ecmascript) <
exports
>"
,
((
__turbopack_context__
)
=>
{
"[project]/turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/import-namespace/input/lib.js [test] (ecmascript) <
internal part 9
>"
,
((
__turbopack_context__
)
=>
{
"use strict"
;
"use strict"
;
__turbopack_context__
.
s
([
__turbopack_context__
.
s
([
...
@@ -167,10 +167,10 @@ var __TURBOPACK__imported__module__$5b$project$5d2f$turbopack$2f$crates$2f$turbo
...
@@ -167,10 +167,10 @@ var __TURBOPACK__imported__module__$5b$project$5d2f$turbopack$2f$crates$2f$turbo
__turbopack_context__
.
s
([]);
__turbopack_context__
.
s
([]);
var
__TURBOPACK__imported__module__$5b$project$5d2f$turbopack$2f$crates$2f$turbopack$2d$tests$2f$tests$2f$snapshot$2f$basic$2d$tree$2d$shake$2f$import$2d$namespace$2f$input$2f$lib$2e$js__$5b$test$5d$__$28$ecmascript$29$__$3c$internal__part__2$3e$__
=
__turbopack_context__
.
i
(
"[project]/turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/import-namespace/input/lib.js [test] (ecmascript) <internal part 2>"
);
var
__TURBOPACK__imported__module__$5b$project$5d2f$turbopack$2f$crates$2f$turbopack$2d$tests$2f$tests$2f$snapshot$2f$basic$2d$tree$2d$shake$2f$import$2d$namespace$2f$input$2f$lib$2e$js__$5b$test$5d$__$28$ecmascript$29$__$3c$internal__part__2$3e$__
=
__turbopack_context__
.
i
(
"[project]/turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/import-namespace/input/lib.js [test] (ecmascript) <internal part 2>"
);
var
__TURBOPACK__imported__module__$5b$project$5d2f$turbopack$2f$crates$2f$turbopack$2d$tests$2f$tests$2f$snapshot$2f$basic$2d$tree$2d$shake$2f$import$2d$namespace$2f$input$2f$lib$2e$js__$5b$test$5d$__$28$ecmascript$29$__$3c$
exports$3e$__
=
__turbopack_context__
.
i
(
"[project]/turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/import-namespace/input/lib.js [test] (ecmascript) <exports
>"
);
var
__TURBOPACK__imported__module__$5b$project$5d2f$turbopack$2f$crates$2f$turbopack$2d$tests$2f$tests$2f$snapshot$2f$basic$2d$tree$2d$shake$2f$import$2d$namespace$2f$input$2f$lib$2e$js__$5b$test$5d$__$28$ecmascript$29$__$3c$
internal__part__9$3e$__
=
__turbopack_context__
.
i
(
"[project]/turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/import-namespace/input/lib.js [test] (ecmascript) <internal part 9
>"
);
;
;
console
.
log
(
__TURBOPACK__imported__module__$5b$project$5d2f$turbopack$2f$crates$2f$turbopack$2d$tests$2f$tests$2f$snapshot$2f$basic$2d$tree$2d$shake$2f$import$2d$namespace$2f$input$2f$lib$2e$js__$5b$test$5d$__$28$ecmascript$29$__$3c$
exports
$3e$__
[
"cat"
]);
console
.
log
(
__TURBOPACK__imported__module__$5b$project$5d2f$turbopack$2f$crates$2f$turbopack$2d$tests$2f$tests$2f$snapshot$2f$basic$2d$tree$2d$shake$2f$import$2d$namespace$2f$input$2f$lib$2e$js__$5b$test$5d$__$28$ecmascript$29$__$3c$
internal__part__9
$3e$__
[
"cat"
]);
}),
}),
]);
]);
//# sourceMappingURL=780ce_turbopack-tests_tests_snapshot_basic-tree-shake_import-namespace_input_bba52bc8._.js.map
//# sourceMappingURL=780ce_turbopack-tests_tests_snapshot_basic-tree-shake_import-namespace_input_31731fc7._.js.map
\ No newline at end of file
\ No newline at end of file
turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/import-namespace/output/780ce_turbopack-tests_tests_snapshot_basic-tree-shake_import-namespace_input_
bba52bc8
._.js.map
→
turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/import-namespace/output/780ce_turbopack-tests_tests_snapshot_basic-tree-shake_import-namespace_input_
31731fc7
._.js.map
View file @
0219ed9e
...
@@ -12,5 +12,5 @@
...
@@ -12,5 +12,5 @@
{"offset": {"line": 112, "column": 0}, "map": {"version":3,"sources":["turbopack:///[project]/turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/import-namespace/input/lib.js"],"sourcesContent":["let dog = 'dog'\n\ndog += '!'\n\nconsole.log(dog)\n\nfunction getDog() {\n return dog\n}\n\ndog += '!'\n\nconsole.log(dog)\n\nfunction setDog(newDog) {\n dog = newDog\n}\n\ndog += '!'\n\nconsole.log(dog)\n\nexport const dogRef = {\n initial: dog,\n get: getDog,\n set: setDog,\n}\n\nexport let cat = 'cat'\n\nexport const initialCat = cat\n\nexport function getChimera() {\n return cat + dog\n}\n"],"names":["getChimera"],"mappings":";;;;;;;;;;;;;AAgCO,SAASA;IACd,OAAO,yPAAG,GAAG,yPAAG;AAClB"}},
{"offset": {"line": 112, "column": 0}, "map": {"version":3,"sources":["turbopack:///[project]/turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/import-namespace/input/lib.js"],"sourcesContent":["let dog = 'dog'\n\ndog += '!'\n\nconsole.log(dog)\n\nfunction getDog() {\n return dog\n}\n\ndog += '!'\n\nconsole.log(dog)\n\nfunction setDog(newDog) {\n dog = newDog\n}\n\ndog += '!'\n\nconsole.log(dog)\n\nexport const dogRef = {\n initial: dog,\n get: getDog,\n set: setDog,\n}\n\nexport let cat = 'cat'\n\nexport const initialCat = cat\n\nexport function getChimera() {\n return cat + dog\n}\n"],"names":["getChimera"],"mappings":";;;;;;;;;;;;;AAgCO,SAASA;IACd,OAAO,yPAAG,GAAG,yPAAG;AAClB"}},
{"offset": {"line": 134, "column": 0}, "map": {"version":3,"sources":[],"names":[],"mappings":""}},
{"offset": {"line": 134, "column": 0}, "map": {"version":3,"sources":[],"names":[],"mappings":""}},
{"offset": {"line": 145, "column": 0}, "map": {"version":3,"sources":[],"names":[],"mappings":""}},
{"offset": {"line": 145, "column": 0}, "map": {"version":3,"sources":[],"names":[],"mappings":""}},
{"offset": {"line": 167, "column": 0}, "map": {"version":3,"sources":["turbopack:///[project]/turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/import-namespace/input/index.js"],"sourcesContent":["import * as lib from './lib'\n\nconsole.log(lib.cat)\n"],"names":["console","log"],"mappings":";AAAA;AAAA;;AAEAA,QAAQC,GAAG,CAAC,
i
PAAO"}}]
{"offset": {"line": 167, "column": 0}, "map": {"version":3,"sources":["turbopack:///[project]/turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/import-namespace/input/index.js"],"sourcesContent":["import * as lib from './lib'\n\nconsole.log(lib.cat)\n"],"names":["console","log"],"mappings":";AAAA;AAAA;;AAEAA,QAAQC,GAAG,CAAC,
2
PAAO"}}]
}
}
\ No newline at end of file
turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/import-namespace/output/ad3e4_tests_snapshot_basic-tree-shake_import-namespace_input_index_
a6f015be
.js
→
turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/import-namespace/output/ad3e4_tests_snapshot_basic-tree-shake_import-namespace_input_index_
928c6c80
.js
View file @
0219ed9e
(
globalThis
[
"TURBOPACK"
]
||
(
globalThis
[
"TURBOPACK"
]
=
[])).
push
([
(
globalThis
[
"TURBOPACK"
]
||
(
globalThis
[
"TURBOPACK"
]
=
[])).
push
([
"output/ad3e4_tests_snapshot_basic-tree-shake_import-namespace_input_index_
a6f015be
.js"
,
"output/ad3e4_tests_snapshot_basic-tree-shake_import-namespace_input_index_
928c6c80
.js"
,
{
"otherChunks"
:[
"output/780ce_turbopack-tests_tests_snapshot_basic-tree-shake_import-namespace_input_
bba52bc8
._.js"
],
"runtimeModuleIds"
:[
"[project]/turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/import-namespace/input/index.js [test] (ecmascript)"
]}
{
"otherChunks"
:[
"output/780ce_turbopack-tests_tests_snapshot_basic-tree-shake_import-namespace_input_
31731fc7
._.js"
],
"runtimeModuleIds"
:[
"[project]/turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/import-namespace/input/index.js [test] (ecmascript)"
]}
]);
]);
// Dummy runtime
// Dummy runtime
\ No newline at end of file
turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/import-namespace/output/bf321_tests_snapshot_basic-tree-shake_import-namespace_input_index_
a6f015be
.js.map
→
turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/import-namespace/output/bf321_tests_snapshot_basic-tree-shake_import-namespace_input_index_
928c6c80
.js.map
View file @
0219ed9e
File moved
turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/require-side-effect/output/ad3e4_tests_snapshot_basic-tree-shake_require-side-effect_input_index_
702672b9
.js
→
turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/require-side-effect/output/ad3e4_tests_snapshot_basic-tree-shake_require-side-effect_input_index_
ec5c94a4
.js
View file @
0219ed9e
(
globalThis
[
"TURBOPACK"
]
||
(
globalThis
[
"TURBOPACK"
]
=
[])).
push
([
(
globalThis
[
"TURBOPACK"
]
||
(
globalThis
[
"TURBOPACK"
]
=
[])).
push
([
"output/ad3e4_tests_snapshot_basic-tree-shake_require-side-effect_input_index_
702672b9
.js"
,
"output/ad3e4_tests_snapshot_basic-tree-shake_require-side-effect_input_index_
ec5c94a4
.js"
,
{
"otherChunks"
:[
"output/bf321_tests_snapshot_basic-tree-shake_require-side-effect_input_
341cf5f1
._.js"
],
"runtimeModuleIds"
:[
"[project]/turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/require-side-effect/input/index.js [test] (ecmascript)"
]}
{
"otherChunks"
:[
"output/bf321_tests_snapshot_basic-tree-shake_require-side-effect_input_
a2766cda
._.js"
],
"runtimeModuleIds"
:[
"[project]/turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/require-side-effect/input/index.js [test] (ecmascript)"
]}
]);
]);
// Dummy runtime
// Dummy runtime
\ No newline at end of file
turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/require-side-effect/output/bf321_tests_snapshot_basic-tree-shake_require-side-effect_input_
341cf5f1
._.js
→
turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/require-side-effect/output/bf321_tests_snapshot_basic-tree-shake_require-side-effect_input_
a2766cda
._.js
View file @
0219ed9e
(
globalThis
[
"TURBOPACK"
]
||
(
globalThis
[
"TURBOPACK"
]
=
[])).
push
([
"output/bf321_tests_snapshot_basic-tree-shake_require-side-effect_input_
341cf5f1
._.js"
,
(
globalThis
[
"TURBOPACK"
]
||
(
globalThis
[
"TURBOPACK"
]
=
[])).
push
([
"output/bf321_tests_snapshot_basic-tree-shake_require-side-effect_input_
a2766cda
._.js"
,
"[project]/turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/require-side-effect/input/lib.js [test] (ecmascript) <internal part 0>"
,
((
__turbopack_context__
)
=>
{
"[project]/turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/require-side-effect/input/lib.js [test] (ecmascript) <internal part 0>"
,
((
__turbopack_context__
)
=>
{
"use strict"
;
"use strict"
;
...
@@ -140,7 +140,7 @@ var __TURBOPACK__imported__module__$5b$project$5d2f$turbopack$2f$crates$2f$turbo
...
@@ -140,7 +140,7 @@ var __TURBOPACK__imported__module__$5b$project$5d2f$turbopack$2f$crates$2f$turbo
;
;
;
;
}),
}),
"[project]/turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/require-side-effect/input/lib.js [test] (ecmascript) <
exports
>"
,
((
__turbopack_context__
)
=>
{
"[project]/turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/require-side-effect/input/lib.js [test] (ecmascript) <
internal part 9
>"
,
((
__turbopack_context__
)
=>
{
"use strict"
;
"use strict"
;
__turbopack_context__
.
s
([
__turbopack_context__
.
s
([
...
@@ -167,16 +167,16 @@ var __TURBOPACK__imported__module__$5b$project$5d2f$turbopack$2f$crates$2f$turbo
...
@@ -167,16 +167,16 @@ var __TURBOPACK__imported__module__$5b$project$5d2f$turbopack$2f$crates$2f$turbo
__turbopack_context__
.
s
([
__turbopack_context__
.
s
([
"cat"
,
"cat"
,
()
=>
__TURBOPACK__imported__module__$5b$project$5d2f$turbopack$2f$crates$2f$turbopack$2d$tests$2f$tests$2f$snapshot$2f$basic$2d$tree$2d$shake$2f$require$2d$side$2d$effect$2f$input$2f$lib$2e$js__$5b$test$5d$__$28$ecmascript$29$__$3c$
exports
$3e$__
[
"cat"
],
()
=>
__TURBOPACK__imported__module__$5b$project$5d2f$turbopack$2f$crates$2f$turbopack$2d$tests$2f$tests$2f$snapshot$2f$basic$2d$tree$2d$shake$2f$require$2d$side$2d$effect$2f$input$2f$lib$2e$js__$5b$test$5d$__$28$ecmascript$29$__$3c$
internal__part__9
$3e$__
[
"cat"
],
"dogRef"
,
"dogRef"
,
()
=>
__TURBOPACK__imported__module__$5b$project$5d2f$turbopack$2f$crates$2f$turbopack$2d$tests$2f$tests$2f$snapshot$2f$basic$2d$tree$2d$shake$2f$require$2d$side$2d$effect$2f$input$2f$lib$2e$js__$5b$test$5d$__$28$ecmascript$29$__$3c$
exports
$3e$__
[
"dogRef"
],
()
=>
__TURBOPACK__imported__module__$5b$project$5d2f$turbopack$2f$crates$2f$turbopack$2d$tests$2f$tests$2f$snapshot$2f$basic$2d$tree$2d$shake$2f$require$2d$side$2d$effect$2f$input$2f$lib$2e$js__$5b$test$5d$__$28$ecmascript$29$__$3c$
internal__part__9
$3e$__
[
"dogRef"
],
"getChimera"
,
"getChimera"
,
()
=>
__TURBOPACK__imported__module__$5b$project$5d2f$turbopack$2f$crates$2f$turbopack$2d$tests$2f$tests$2f$snapshot$2f$basic$2d$tree$2d$shake$2f$require$2d$side$2d$effect$2f$input$2f$lib$2e$js__$5b$test$5d$__$28$ecmascript$29$__$3c$
exports
$3e$__
[
"getChimera"
],
()
=>
__TURBOPACK__imported__module__$5b$project$5d2f$turbopack$2f$crates$2f$turbopack$2d$tests$2f$tests$2f$snapshot$2f$basic$2d$tree$2d$shake$2f$require$2d$side$2d$effect$2f$input$2f$lib$2e$js__$5b$test$5d$__$28$ecmascript$29$__$3c$
internal__part__9
$3e$__
[
"getChimera"
],
"initialCat"
,
"initialCat"
,
()
=>
__TURBOPACK__imported__module__$5b$project$5d2f$turbopack$2f$crates$2f$turbopack$2d$tests$2f$tests$2f$snapshot$2f$basic$2d$tree$2d$shake$2f$require$2d$side$2d$effect$2f$input$2f$lib$2e$js__$5b$test$5d$__$28$ecmascript$29$__$3c$
exports
$3e$__
[
"initialCat"
]
()
=>
__TURBOPACK__imported__module__$5b$project$5d2f$turbopack$2f$crates$2f$turbopack$2d$tests$2f$tests$2f$snapshot$2f$basic$2d$tree$2d$shake$2f$require$2d$side$2d$effect$2f$input$2f$lib$2e$js__$5b$test$5d$__$28$ecmascript$29$__$3c$
internal__part__9
$3e$__
[
"initialCat"
]
]);
]);
var
__TURBOPACK__imported__module__$5b$project$5d2f$turbopack$2f$crates$2f$turbopack$2d$tests$2f$tests$2f$snapshot$2f$basic$2d$tree$2d$shake$2f$require$2d$side$2d$effect$2f$input$2f$lib$2e$js__$5b$test$5d$__$28$ecmascript$29$__$3c$internal__part__2$3e$__
=
__turbopack_context__
.
i
(
"[project]/turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/require-side-effect/input/lib.js [test] (ecmascript) <internal part 2>"
);
var
__TURBOPACK__imported__module__$5b$project$5d2f$turbopack$2f$crates$2f$turbopack$2d$tests$2f$tests$2f$snapshot$2f$basic$2d$tree$2d$shake$2f$require$2d$side$2d$effect$2f$input$2f$lib$2e$js__$5b$test$5d$__$28$ecmascript$29$__$3c$internal__part__2$3e$__
=
__turbopack_context__
.
i
(
"[project]/turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/require-side-effect/input/lib.js [test] (ecmascript) <internal part 2>"
);
var
__TURBOPACK__imported__module__$5b$project$5d2f$turbopack$2f$crates$2f$turbopack$2d$tests$2f$tests$2f$snapshot$2f$basic$2d$tree$2d$shake$2f$require$2d$side$2d$effect$2f$input$2f$lib$2e$js__$5b$test$5d$__$28$ecmascript$29$__$3c$
exports$3e$__
=
__turbopack_context__
.
i
(
"[project]/turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/require-side-effect/input/lib.js [test] (ecmascript) <exports
>"
);
var
__TURBOPACK__imported__module__$5b$project$5d2f$turbopack$2f$crates$2f$turbopack$2d$tests$2f$tests$2f$snapshot$2f$basic$2d$tree$2d$shake$2f$require$2d$side$2d$effect$2f$input$2f$lib$2e$js__$5b$test$5d$__$28$ecmascript$29$__$3c$
internal__part__9$3e$__
=
__turbopack_context__
.
i
(
"[project]/turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/require-side-effect/input/lib.js [test] (ecmascript) <internal part 9
>"
);
;
;
;
;
}),
}),
...
@@ -186,4 +186,4 @@ const { cat } = __turbopack_context__.r("[project]/turbopack/crates/turbopack-te
...
@@ -186,4 +186,4 @@ const { cat } = __turbopack_context__.r("[project]/turbopack/crates/turbopack-te
}),
}),
]);
]);
//# sourceMappingURL=bf321_tests_snapshot_basic-tree-shake_require-side-effect_input_341cf5f1._.js.map
//# sourceMappingURL=bf321_tests_snapshot_basic-tree-shake_require-side-effect_input_a2766cda._.js.map
\ No newline at end of file
\ No newline at end of file
turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/require-side-effect/output/bf321_tests_snapshot_basic-tree-shake_require-side-effect_input_
341cf5f1
._.js.map
→
turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/require-side-effect/output/bf321_tests_snapshot_basic-tree-shake_require-side-effect_input_
a2766cda
._.js.map
View file @
0219ed9e
File moved
turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/require-side-effect/output/bf321_tests_snapshot_basic-tree-shake_require-side-effect_input_index_
702672b9
.js.map
→
turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/require-side-effect/output/bf321_tests_snapshot_basic-tree-shake_require-side-effect_input_index_
ec5c94a4
.js.map
View file @
0219ed9e
File moved
turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/tree-shake-test-1/output/ad3e4_tests_snapshot_basic-tree-shake_tree-shake-test-1_input_index_
210ac8f
d.js
→
turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/tree-shake-test-1/output/ad3e4_tests_snapshot_basic-tree-shake_tree-shake-test-1_input_index_
a09a504
d.js
View file @
0219ed9e
(
globalThis
[
"TURBOPACK"
]
||
(
globalThis
[
"TURBOPACK"
]
=
[])).
push
([
(
globalThis
[
"TURBOPACK"
]
||
(
globalThis
[
"TURBOPACK"
]
=
[])).
push
([
"output/ad3e4_tests_snapshot_basic-tree-shake_tree-shake-test-1_input_index_
210ac8f
d.js"
,
"output/ad3e4_tests_snapshot_basic-tree-shake_tree-shake-test-1_input_index_
a09a504
d.js"
,
{
"otherChunks"
:[
"output/bf321_tests_snapshot_basic-tree-shake_tree-shake-test-1_input_index_
18e65124
.js"
],
"runtimeModuleIds"
:[
"[project]/turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/tree-shake-test-1/input/index.js [test] (ecmascript)"
]}
{
"otherChunks"
:[
"output/bf321_tests_snapshot_basic-tree-shake_tree-shake-test-1_input_index_
88b827c6
.js"
],
"runtimeModuleIds"
:[
"[project]/turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/tree-shake-test-1/input/index.js [test] (ecmascript)"
]}
]);
]);
// Dummy runtime
// Dummy runtime
\ No newline at end of file
turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/tree-shake-test-1/output/bf321_tests_snapshot_basic-tree-shake_tree-shake-test-1_input_index_
18e65124
.js
→
turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/tree-shake-test-1/output/bf321_tests_snapshot_basic-tree-shake_tree-shake-test-1_input_index_
88b827c6
.js
View file @
0219ed9e
(
globalThis
[
"TURBOPACK"
]
||
(
globalThis
[
"TURBOPACK"
]
=
[])).
push
([
"output/bf321_tests_snapshot_basic-tree-shake_tree-shake-test-1_input_index_
18e65124
.js"
,
(
globalThis
[
"TURBOPACK"
]
||
(
globalThis
[
"TURBOPACK"
]
=
[])).
push
([
"output/bf321_tests_snapshot_basic-tree-shake_tree-shake-test-1_input_index_
88b827c6
.js"
,
"[project]/turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/tree-shake-test-1/input/index.js [test] (ecmascript) <internal part 0>"
,
((
__turbopack_context__
)
=>
{
"[project]/turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/tree-shake-test-1/input/index.js [test] (ecmascript) <internal part 0>"
,
((
__turbopack_context__
)
=>
{
"use strict"
;
"use strict"
;
...
@@ -140,7 +140,7 @@ var __TURBOPACK__imported__module__$5b$project$5d2f$turbopack$2f$crates$2f$turbo
...
@@ -140,7 +140,7 @@ var __TURBOPACK__imported__module__$5b$project$5d2f$turbopack$2f$crates$2f$turbo
;
;
;
;
}),
}),
"[project]/turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/tree-shake-test-1/input/index.js [test] (ecmascript) <
exports
>"
,
((
__turbopack_context__
)
=>
{
"[project]/turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/tree-shake-test-1/input/index.js [test] (ecmascript) <
internal part 9
>"
,
((
__turbopack_context__
)
=>
{
"use strict"
;
"use strict"
;
__turbopack_context__
.
s
([
__turbopack_context__
.
s
([
...
@@ -167,19 +167,19 @@ var __TURBOPACK__imported__module__$5b$project$5d2f$turbopack$2f$crates$2f$turbo
...
@@ -167,19 +167,19 @@ var __TURBOPACK__imported__module__$5b$project$5d2f$turbopack$2f$crates$2f$turbo
__turbopack_context__
.
s
([
__turbopack_context__
.
s
([
"cat"
,
"cat"
,
()
=>
__TURBOPACK__imported__module__$5b$project$5d2f$turbopack$2f$crates$2f$turbopack$2d$tests$2f$tests$2f$snapshot$2f$basic$2d$tree$2d$shake$2f$tree$2d$shake$2d$test$2d$1$2f$input$2f$index$2e$js__$5b$test$5d$__$28$ecmascript$29$__$3c$
exports
$3e$__
[
"cat"
],
()
=>
__TURBOPACK__imported__module__$5b$project$5d2f$turbopack$2f$crates$2f$turbopack$2d$tests$2f$tests$2f$snapshot$2f$basic$2d$tree$2d$shake$2f$tree$2d$shake$2d$test$2d$1$2f$input$2f$index$2e$js__$5b$test$5d$__$28$ecmascript$29$__$3c$
internal__part__9
$3e$__
[
"cat"
],
"dogRef"
,
"dogRef"
,
()
=>
__TURBOPACK__imported__module__$5b$project$5d2f$turbopack$2f$crates$2f$turbopack$2d$tests$2f$tests$2f$snapshot$2f$basic$2d$tree$2d$shake$2f$tree$2d$shake$2d$test$2d$1$2f$input$2f$index$2e$js__$5b$test$5d$__$28$ecmascript$29$__$3c$
exports
$3e$__
[
"dogRef"
],
()
=>
__TURBOPACK__imported__module__$5b$project$5d2f$turbopack$2f$crates$2f$turbopack$2d$tests$2f$tests$2f$snapshot$2f$basic$2d$tree$2d$shake$2f$tree$2d$shake$2d$test$2d$1$2f$input$2f$index$2e$js__$5b$test$5d$__$28$ecmascript$29$__$3c$
internal__part__9
$3e$__
[
"dogRef"
],
"getChimera"
,
"getChimera"
,
()
=>
__TURBOPACK__imported__module__$5b$project$5d2f$turbopack$2f$crates$2f$turbopack$2d$tests$2f$tests$2f$snapshot$2f$basic$2d$tree$2d$shake$2f$tree$2d$shake$2d$test$2d$1$2f$input$2f$index$2e$js__$5b$test$5d$__$28$ecmascript$29$__$3c$
exports
$3e$__
[
"getChimera"
],
()
=>
__TURBOPACK__imported__module__$5b$project$5d2f$turbopack$2f$crates$2f$turbopack$2d$tests$2f$tests$2f$snapshot$2f$basic$2d$tree$2d$shake$2f$tree$2d$shake$2d$test$2d$1$2f$input$2f$index$2e$js__$5b$test$5d$__$28$ecmascript$29$__$3c$
internal__part__9
$3e$__
[
"getChimera"
],
"initialCat"
,
"initialCat"
,
()
=>
__TURBOPACK__imported__module__$5b$project$5d2f$turbopack$2f$crates$2f$turbopack$2d$tests$2f$tests$2f$snapshot$2f$basic$2d$tree$2d$shake$2f$tree$2d$shake$2d$test$2d$1$2f$input$2f$index$2e$js__$5b$test$5d$__$28$ecmascript$29$__$3c$
exports
$3e$__
[
"initialCat"
]
()
=>
__TURBOPACK__imported__module__$5b$project$5d2f$turbopack$2f$crates$2f$turbopack$2d$tests$2f$tests$2f$snapshot$2f$basic$2d$tree$2d$shake$2f$tree$2d$shake$2d$test$2d$1$2f$input$2f$index$2e$js__$5b$test$5d$__$28$ecmascript$29$__$3c$
internal__part__9
$3e$__
[
"initialCat"
]
]);
]);
var
__TURBOPACK__imported__module__$5b$project$5d2f$turbopack$2f$crates$2f$turbopack$2d$tests$2f$tests$2f$snapshot$2f$basic$2d$tree$2d$shake$2f$tree$2d$shake$2d$test$2d$1$2f$input$2f$index$2e$js__$5b$test$5d$__$28$ecmascript$29$__$3c$internal__part__2$3e$__
=
__turbopack_context__
.
i
(
"[project]/turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/tree-shake-test-1/input/index.js [test] (ecmascript) <internal part 2>"
);
var
__TURBOPACK__imported__module__$5b$project$5d2f$turbopack$2f$crates$2f$turbopack$2d$tests$2f$tests$2f$snapshot$2f$basic$2d$tree$2d$shake$2f$tree$2d$shake$2d$test$2d$1$2f$input$2f$index$2e$js__$5b$test$5d$__$28$ecmascript$29$__$3c$internal__part__2$3e$__
=
__turbopack_context__
.
i
(
"[project]/turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/tree-shake-test-1/input/index.js [test] (ecmascript) <internal part 2>"
);
var
__TURBOPACK__imported__module__$5b$project$5d2f$turbopack$2f$crates$2f$turbopack$2d$tests$2f$tests$2f$snapshot$2f$basic$2d$tree$2d$shake$2f$tree$2d$shake$2d$test$2d$1$2f$input$2f$index$2e$js__$5b$test$5d$__$28$ecmascript$29$__$3c$
exports$3e$__
=
__turbopack_context__
.
i
(
"[project]/turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/tree-shake-test-1/input/index.js [test] (ecmascript) <exports
>"
);
var
__TURBOPACK__imported__module__$5b$project$5d2f$turbopack$2f$crates$2f$turbopack$2d$tests$2f$tests$2f$snapshot$2f$basic$2d$tree$2d$shake$2f$tree$2d$shake$2d$test$2d$1$2f$input$2f$index$2e$js__$5b$test$5d$__$28$ecmascript$29$__$3c$
internal__part__9$3e$__
=
__turbopack_context__
.
i
(
"[project]/turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/tree-shake-test-1/input/index.js [test] (ecmascript) <internal part 9
>"
);
;
;
;
;
}),
}),
]);
]);
//# sourceMappingURL=bf321_tests_snapshot_basic-tree-shake_tree-shake-test-1_input_index_18e65124.js.map
//# sourceMappingURL=bf321_tests_snapshot_basic-tree-shake_tree-shake-test-1_input_index_88b827c6.js.map
\ No newline at end of file
\ No newline at end of file
turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/tree-shake-test-1/output/bf321_tests_snapshot_basic-tree-shake_tree-shake-test-1_input_index_
18e65124
.js.map
→
turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/tree-shake-test-1/output/bf321_tests_snapshot_basic-tree-shake_tree-shake-test-1_input_index_
88b827c6
.js.map
View file @
0219ed9e
File moved
turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/tree-shake-test-1/output/bf321_tests_snapshot_basic-tree-shake_tree-shake-test-1_input_index_
210ac8f
d.js.map
→
turbopack/crates/turbopack-tests/tests/snapshot/basic-tree-shake/tree-shake-test-1/output/bf321_tests_snapshot_basic-tree-shake_tree-shake-test-1_input_index_
a09a504
d.js.map
View file @
0219ed9e
File moved
turbopack/crates/turbopack/src/lib.rs
View file @
0219ed9e
...
@@ -188,10 +188,10 @@ async fn apply_module_type(
...
@@ -188,10 +188,10 @@ async fn apply_module_type(
match
tree_shaking_mode
{
match
tree_shaking_mode
{
Some
(
TreeShakingMode
::
ModuleFragments
)
=>
{
Some
(
TreeShakingMode
::
ModuleFragments
)
=>
{
Vc
::
upcast
(
EcmascriptModulePartAsset
::
select_part
(
return
Ok
(
EcmascriptModulePartAsset
::
select_part
(
*
module
,
*
module
,
part
.unwrap_or
(
ModulePart
::
facade
()),
part
.unwrap_or
(
ModulePart
::
facade
()),
))
))
;
}
}
Some
(
TreeShakingMode
::
ReexportsOnly
)
=>
{
Some
(
TreeShakingMode
::
ReexportsOnly
)
=>
{
if
*
module
.get_exports
()
.split_locals_and_reexports
()
.await
?
{
if
*
module
.get_exports
()
.split_locals_and_reexports
()
.await
?
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment