Skip to content

Commit aadb95c

Browse files
authored
Turbopack: import to char not replaced (#86573)
Adds a test case for #86532 , #86076
1 parent 737ddf7 commit aadb95c

8 files changed

+68
-0
lines changed
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
import { char } from './Tokenizer.js'
2+
3+
export function comment() {
4+
console.log(char())
5+
}
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
export function char() {
2+
return 0
3+
}
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
import { comment } from './Parser.js'
2+
3+
console.log(comment())
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
{
2+
"browserslist": "chrome 142"
3+
}

turbopack/crates/turbopack-tests/tests/snapshot/swc_transforms/preset_env_modern/output/780ce_turbopack-tests_tests_snapshot_swc_transforms_preset_env_modern_input_e3b65cb8._.js

Lines changed: 36 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

turbopack/crates/turbopack-tests/tests/snapshot/swc_transforms/preset_env_modern/output/780ce_turbopack-tests_tests_snapshot_swc_transforms_preset_env_modern_input_e3b65cb8._.js.map

Lines changed: 8 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
(globalThis.TURBOPACK || (globalThis.TURBOPACK = [])).push([
2+
"output/ad3e4_tests_snapshot_swc_transforms_preset_env_modern_input_index_a3dbfd52.js",
3+
{"otherChunks":["output/780ce_turbopack-tests_tests_snapshot_swc_transforms_preset_env_modern_input_e3b65cb8._.js"],"runtimeModuleIds":["[project]/turbopack/crates/turbopack-tests/tests/snapshot/swc_transforms/preset_env_modern/input/index.js [test] (ecmascript)"]}
4+
]);
5+
// Dummy runtime

turbopack/crates/turbopack-tests/tests/snapshot/swc_transforms/preset_env_modern/output/bf321_tests_snapshot_swc_transforms_preset_env_modern_input_index_a3dbfd52.js.map

Lines changed: 5 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)