mirror of
https://github.com/vercel-labs/scriptc.git
synced 2026-10-27 06:43:19 +08:00
The export-alias rewrite skipped a whole function when a let or const anywhere inside it declared the alias's name, so the function's other references to the alias kept the alias name after its declaration was removed. A function now shadows the alias only through its parameters, its own name, its vars and the declarations directly in its body; a block, case block, catch clause or for loop shadows it through its own declarations, and the walk skips just that scope.