-
Notifications
You must be signed in to change notification settings - Fork 1.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Tree Shaking grouping of items #8420
Conversation
The latest updates on your projects. Learn more about Vercel for Git ↗︎
8 Ignored Deployments
|
|
||
export { x }; | ||
|
||
export const y = x; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Removing this line fixes the problem
🟢 Turbopack Benchmark CI successful 🟢Thanks |
✅ This change can build |
x = 2; | ||
export { x } from "__TURBOPACK_VAR__" assert { | ||
__turbopack_var__: true | ||
}; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It should import x
import "__TURBOPACK_PART__" assert { | ||
__turbopack_part__: 4 | ||
}; | ||
import "__TURBOPACK_PART__" assert { | ||
__turbopack_part__: 5 | ||
}; | ||
import "__TURBOPACK_PART__" assert { | ||
__turbopack_part__: 6 | ||
}; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
import "__TURBOPACK_PART__" assert { | |
__turbopack_part__: 4 | |
}; | |
import "__TURBOPACK_PART__" assert { | |
__turbopack_part__: 5 | |
}; | |
import "__TURBOPACK_PART__" assert { | |
__turbopack_part__: 6 | |
}; |
These are not necessary. It only need to import the last Write to a variable. And the declaration of it
export { x } from "__TURBOPACK_VAR__" assert { | ||
__turbopack_var__: true | ||
}; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I feel like it's wrong that a module exports a variable that it didn't declare.
|
cec53bc
to
f7b632b
Compare
This reverts commit 63767f7.
# Turbopack * vercel/turborepo#8473 <!-- Donny/강동윤 - feat: Check the number of direct dependants while tree shaking --> * vercel/turborepo#8420 <!-- Tobias Koppers - Tree Shaking grouping of items --> * vercel/turborepo#8510 <!-- Tobias Koppers - read larger chunks when reading a trace file --> * vercel/turborepo#8509 <!-- Tobias Koppers - avoid duplicates in primary_modules --> * vercel/turborepo#8508 <!-- Tobias Koppers - only create spans for nodes that are actually visited --> * vercel/turborepo#8502 <!-- Donny/강동윤 - build: Update `swc_core` to `v0.95.2` --> ### What? Update `swc_core`. - [CHANGELOG](https://github.com/swc-project/swc/blob/064af5391d8da9599f277bd68fd0b479b0b1235c/CHANGELOG.md#160---2024-06-15) ### Why? I improved the performance of the parser by margin.
…orepo#8472) ### Description Extracted from vercel/turborepo#8420 to split diffs for optimization vs intuitiveness ### Testing Instructions --------- Co-authored-by: Tobias Koppers <tobias.koppers@googlemail.com>
### Description add test case ### Testing Instructions <!-- Give a quick description of steps to test your changes. --> --------- Co-authored-by: 강동윤 (Donny) <kdy1997.dev@gmail.com>
…orepo#8472) ### Description Extracted from vercel/turborepo#8420 to split diffs for optimization vs intuitiveness ### Testing Instructions --------- Co-authored-by: Tobias Koppers <tobias.koppers@googlemail.com>
### Description add test case ### Testing Instructions <!-- Give a quick description of steps to test your changes. --> --------- Co-authored-by: 강동윤 (Donny) <kdy1997.dev@gmail.com>
…orepo#8472) ### Description Extracted from vercel/turborepo#8420 to split diffs for optimization vs intuitiveness ### Testing Instructions --------- Co-authored-by: Tobias Koppers <tobias.koppers@googlemail.com>
### Description add test case ### Testing Instructions <!-- Give a quick description of steps to test your changes. --> --------- Co-authored-by: 강동윤 (Donny) <kdy1997.dev@gmail.com>
…orepo#8472) ### Description Extracted from vercel/turborepo#8420 to split diffs for optimization vs intuitiveness ### Testing Instructions --------- Co-authored-by: Tobias Koppers <tobias.koppers@googlemail.com>
### Description add test case ### Testing Instructions <!-- Give a quick description of steps to test your changes. --> --------- Co-authored-by: 강동윤 (Donny) <kdy1997.dev@gmail.com>
* vercel/turborepo#8473 <!-- Donny/강동윤 - feat: Check the number of direct dependants while tree shaking --> * vercel/turborepo#8420 <!-- Tobias Koppers - Tree Shaking grouping of items --> * vercel/turborepo#8510 <!-- Tobias Koppers - read larger chunks when reading a trace file --> * vercel/turborepo#8509 <!-- Tobias Koppers - avoid duplicates in primary_modules --> * vercel/turborepo#8508 <!-- Tobias Koppers - only create spans for nodes that are actually visited --> * vercel/turborepo#8502 <!-- Donny/강동윤 - build: Update `swc_core` to `v0.95.2` --> Update `swc_core`. - [CHANGELOG](https://github.com/swc-project/swc/blob/064af5391d8da9599f277bd68fd0b479b0b1235c/CHANGELOG.md#160---2024-06-15) I improved the performance of the parser by margin.
* vercel/turborepo#8473 <!-- Donny/강동윤 - feat: Check the number of direct dependants while tree shaking --> * vercel/turborepo#8420 <!-- Tobias Koppers - Tree Shaking grouping of items --> * vercel/turborepo#8510 <!-- Tobias Koppers - read larger chunks when reading a trace file --> * vercel/turborepo#8509 <!-- Tobias Koppers - avoid duplicates in primary_modules --> * vercel/turborepo#8508 <!-- Tobias Koppers - only create spans for nodes that are actually visited --> * vercel/turborepo#8502 <!-- Donny/강동윤 - build: Update `swc_core` to `v0.95.2` --> Update `swc_core`. - [CHANGELOG](https://github.com/swc-project/swc/blob/064af5391d8da9599f277bd68fd0b479b0b1235c/CHANGELOG.md#160---2024-06-15) I improved the performance of the parser by margin.
# Turbopack * vercel/turborepo#8473 <!-- Donny/강동윤 - feat: Check the number of direct dependants while tree shaking --> * vercel/turborepo#8420 <!-- Tobias Koppers - Tree Shaking grouping of items --> * vercel/turborepo#8510 <!-- Tobias Koppers - read larger chunks when reading a trace file --> * vercel/turborepo#8509 <!-- Tobias Koppers - avoid duplicates in primary_modules --> * vercel/turborepo#8508 <!-- Tobias Koppers - only create spans for nodes that are actually visited --> * vercel/turborepo#8502 <!-- Donny/강동윤 - build: Update `swc_core` to `v0.95.2` --> ### What? Update `swc_core`. - [CHANGELOG](https://github.com/swc-project/swc/blob/064af5391d8da9599f277bd68fd0b479b0b1235c/CHANGELOG.md#160---2024-06-15) ### Why? I improved the performance of the parser by margin.
Description
add test case
Testing Instructions