Repository navigation
test(lexer): cover TypeScript default reexports in extended mode - #137
Merged
Merged
Conversation
TypeScript emits default reexports with an __importDefault call inside a getter. Default mode excludes the name because the call falls outside its getter patterns. Extended mode must retain the name even after an exports.bar = void 0 declaration. Refs: #76 Signed-off-by: Ruben Bridgewater <ruben.bridgewater@datadoghq.com>
BridgeAR
marked this pull request as ready for review
October 27, 2026 17:37
guybedford
approved these changes
Nov 19, 2026
guybedford
left a comment
Collaborator
There was a problem hiding this comment.
LGTM. Optional suggestion: since extended defineProperty takes the name before looking at the descriptor, neither the helper form nor the void 0 predeclaration affects the result. A single test using the verbatim output from #76 might read more clearly than the matrix. Also, if extended mode is the resolution for #76, Fixes instead of Refs would close it.
Signed-off-by: Ruben Bridgewater <ruben.bridgewater@datadoghq.com>
Member
Author
|
Updated. About #76: that seems unrelated to this test and I am hesitant to close it already. Extended mode kind of solves it, but I consider it as a kind of experimental part |
guybedford
approved these changes
Nov 20, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
TypeScript emits default reexports with an
__importDefaultcall inside a getter. Default mode excludes the name because the call falls outside its getter patterns. Extended mode must retain the name even after anexports.bar = void 0declaration.Refs: #76