Skip to content

Fix transpile test diffs - #4902

Open
Jake Bailey (jakebailey) wants to merge 6 commits into
mainfrom
jabaile/fix-transpile-declaration
Open

Fix transpile test diffs#4902
Jake Bailey (jakebailey) wants to merge 6 commits into
mainfrom
jabaile/fix-transpile-declaration

Conversation

@jakebailey

Copy link
Copy Markdown
Member

Sort of a last minute panic to try and fix these now that they've been introduced just before we delete all the diffs 😄

Copilot AI balanced review requested due to automatic review settings August 13, 2026 23:39
Comment thread internal/checker/nodebuilderimpl.go Outdated

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Aligns transpile, declaration, diagnostic, and source-map behavior with the TypeScript reference implementation.

Changes:

  • Corrects namespace/export and declaration source-map ranges.
  • Improves isolated-declaration inference for computed symbols and implicit undefined.
  • Adds regression coverage and refreshes affected baselines.

Reviewed changes

Copilot reviewed 66 out of 85 changed files in this pull request and generated no comments.

Show a summary per file
File Description
testdata/tests/cases/compiler/isolatedDeclarationsShadowedSymbolComputedName.ts Adds computed-symbol regression cases.
testdata/baselines/reference/submodule/transpile/jsWithSourceMapBasic(sourceMap=true).js.diff Removes resolved source-map diff.
testdata/baselines/reference/submodule/transpile/jsWithSourceMapBasic(sourceMap=true).js Updates source-map baseline.
testdata/baselines/reference/submodule/transpile/jsWithInlineSourceMapBasic(inlineSourceMap=true).js.diff Removes resolved inline-map diff.
testdata/baselines/reference/submodule/transpile/jsWithInlineSourceMapBasic(inlineSourceMap=true).js Updates inline-map baseline.
testdata/baselines/reference/submodule/transpile/declarationFunctionDeclarations.d.ts.diff Removes resolved diagnostic diff.
testdata/baselines/reference/submodule/transpile/declarationFunctionDeclarations.d.ts Updates parameter diagnostics.
testdata/baselines/reference/submodule/transpile/declarationCrossFileInferences.d.ts.diff Removes resolved inference diff.
testdata/baselines/reference/submodule/transpile/declarationCrossFileInferences.d.ts Updates return-type diagnostic location.
testdata/baselines/reference/submodule/transpile/declarationComputedPropertyNames.d.ts.diff Removes resolved computed-name diff.
testdata/baselines/reference/submodule/transpile/declarationComputedPropertyNames.d.ts Updates computed-name output.
testdata/baselines/reference/submodule/transpile/declarationBasicSyntax(declarationMap=true).d.ts.diff Removes resolved declaration-map diff.
testdata/baselines/reference/submodule/transpile/declarationBasicSyntax(declarationMap=true).d.ts Updates declaration-map baseline.
testdata/baselines/reference/submodule/conformance/tsxEmit3.sourcemap.txt.diff Reduces TSX source-map differences.
testdata/baselines/reference/submodule/conformance/tsxEmit3.sourcemap.txt Updates TSX map visualization.
testdata/baselines/reference/submodule/conformance/tsxEmit3.js.map Updates TSX map data.
testdata/baselines/reference/submodule/conformance/esDecorators-classDeclaration-sourceMap(target=esnext).sourcemap.txt.diff Reduces ESNext decorator-map diff.
testdata/baselines/reference/submodule/conformance/esDecorators-classDeclaration-sourceMap(target=esnext).sourcemap.txt Updates ESNext map visualization.
testdata/baselines/reference/submodule/conformance/esDecorators-classDeclaration-sourceMap(target=esnext).js.map.diff Updates remaining ESNext map diff.
testdata/baselines/reference/submodule/conformance/esDecorators-classDeclaration-sourceMap(target=esnext).js.map Updates ESNext declaration map.
testdata/baselines/reference/submodule/conformance/esDecorators-classDeclaration-sourceMap(target=es2022).sourcemap.txt.diff Removes resolved ES2022 map diff.
testdata/baselines/reference/submodule/conformance/esDecorators-classDeclaration-sourceMap(target=es2022).sourcemap.txt Updates ES2022 map visualization.
testdata/baselines/reference/submodule/conformance/esDecorators-classDeclaration-sourceMap(target=es2015).sourcemap.txt.diff Removes resolved ES2015 map diff.
testdata/baselines/reference/submodule/conformance/esDecorators-classDeclaration-sourceMap(target=es2015).sourcemap.txt Updates ES2015 map visualization.
testdata/baselines/reference/submodule/compiler/sourceMapValidationModule.sourcemap.txt.diff Removes resolved module-map diff.
testdata/baselines/reference/submodule/compiler/sourceMapValidationModule.sourcemap.txt Updates module map visualization.
testdata/baselines/reference/submodule/compiler/sourceMapValidationModule.js.map.diff Removes resolved module map diff.
testdata/baselines/reference/submodule/compiler/sourceMapValidationModule.js.map Updates module map data.
testdata/baselines/reference/submodule/compiler/sourceMapValidationImport.sourcemap.txt.diff Reduces import map differences.
testdata/baselines/reference/submodule/compiler/sourceMapValidationImport.sourcemap.txt Updates import map visualization.
testdata/baselines/reference/submodule/compiler/sourceMapValidationImport.js.map.diff Updates remaining import map diff.
testdata/baselines/reference/submodule/compiler/sourceMapValidationImport.js.map Updates import map data.
testdata/baselines/reference/submodule/compiler/sourcemapValidationDuplicateNames.sourcemap.txt.diff Removes resolved duplicate-name diff.
testdata/baselines/reference/submodule/compiler/sourcemapValidationDuplicateNames.sourcemap.txt Updates duplicate-name visualization.
testdata/baselines/reference/submodule/compiler/sourcemapValidationDuplicateNames.js.map.diff Removes resolved map diff.
testdata/baselines/reference/submodule/compiler/sourcemapValidationDuplicateNames.js.map Updates duplicate-name map.
testdata/baselines/reference/submodule/compiler/sourceMapValidationClasses.sourcemap.txt.diff Reduces class map differences.
testdata/baselines/reference/submodule/compiler/sourceMapValidationClasses.sourcemap.txt Updates class map visualization.
testdata/baselines/reference/submodule/compiler/sourceMapSample.sourcemap.txt.diff Reduces sample map differences.
testdata/baselines/reference/submodule/compiler/sourceMapSample.sourcemap.txt Updates sample map visualization.
testdata/baselines/reference/submodule/compiler/sourceMap-FileWithComments.sourcemap.txt.diff Reduces commented-file map diff.
testdata/baselines/reference/submodule/compiler/sourceMap-FileWithComments.sourcemap.txt Updates commented-file visualization.
testdata/baselines/reference/submodule/compiler/sourceMap-FileWithComments.js.map Updates commented-file map.
testdata/baselines/reference/submodule/compiler/sourceMap-Comments(target=es2015).sourcemap.txt.diff Removes resolved comments map diff.
testdata/baselines/reference/submodule/compiler/sourceMap-Comments(target=es2015).sourcemap.txt Updates comments map visualization.
testdata/baselines/reference/submodule/compiler/sourceMap-Comments(target=es2015).js.map.diff Removes resolved comments map diff.
testdata/baselines/reference/submodule/compiler/sourceMap-Comments(target=es2015).js.map Updates comments map data.
testdata/baselines/reference/submodule/compiler/jsxFactoryQualifiedName.sourcemap.txt.diff Reduces qualified JSX map diff.
testdata/baselines/reference/submodule/compiler/jsxFactoryQualifiedName.sourcemap.txt Updates qualified JSX visualization.
testdata/baselines/reference/submodule/compiler/jsxFactoryQualifiedName.js.map Updates qualified JSX map.
testdata/baselines/reference/submodule/compiler/jsxFactoryIdentifier.sourcemap.txt.diff Reduces identifier JSX map diff.
testdata/baselines/reference/submodule/compiler/jsxFactoryIdentifier.sourcemap.txt Updates identifier JSX visualization.
testdata/baselines/reference/submodule/compiler/jsxFactoryIdentifier.js.map Updates identifier JSX map.
testdata/baselines/reference/submodule/compiler/declarationMapsMultifile.sourcemap.txt.diff Reduces multifile declaration-map diff.
testdata/baselines/reference/submodule/compiler/declarationMapsMultifile.sourcemap.txt Updates multifile map visualization.
testdata/baselines/reference/submodule/compiler/declarationMapsMultifile.js.map.diff Updates remaining multifile map diff.
testdata/baselines/reference/submodule/compiler/declarationMapsMultifile.js.map Updates multifile declaration map.
testdata/baselines/reference/compiler/isolatedDeclarationsShadowedSymbolComputedName.types Adds inferred-type baseline.
testdata/baselines/reference/compiler/isolatedDeclarationsShadowedSymbolComputedName.symbols Adds symbol-resolution baseline.
testdata/baselines/reference/compiler/isolatedDeclarationsShadowedSymbolComputedName.js Adds emit baseline.
testdata/baselines/reference/compiler/isolatedDeclarationsShadowedSymbolComputedName.errors.txt Adds diagnostic baseline.
internal/transformers/tstransforms/runtimesyntax.go Corrects namespace export map ranges.
internal/transformers/estransforms/using.go Clears cloned using-target location.
internal/transformers/declarations/transform.go Corrects method declaration mapping.
internal/transformers/declarations/diagnostics.go Supplies enclosing parameter context.
internal/pseudochecker/lookup.go Improves inference and computed-name handling.
internal/pseudochecker/checker.go Adds resolver support.
internal/checker/nodebuilderimpl.go Aligns container ordering and fallback diagnostics.
internal/checker/emitresolver.go Exposes checker-safe global Symbol resolution.

💡 Add a code-review agent skill for context-aware, tailored reviews. Learn more in the docs.

@jakebailey
Jake Bailey (jakebailey) force-pushed the jabaile/fix-transpile-declaration branch from 275b7c8 to 0b0d8c6 Compare August 14, 2026 22:06
return &PseudoChecker{
strictNullChecks: strictNullChecks,
exactOptionalPropertyTypes: exactOptionalPropertyTypes,
nameResolver: &binder.NameResolver{CompilerOptions: compilerOptions},

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think it's actually quite possible to make the name resolver not have compiler options at all, but this of course goofy to have plumbed this way (for the time being)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants