ReviewOS

home-lang/home

TypeScript checker parity: eliminate the remaining 30 failures

#69
Closed chris opened this 14 days ago · 717 comments
14 days ago

Parent: #67

Scope

Make ts_checker fully green by porting the remaining TypeScript semantics and exact diagnostic behavior. Do not weaken assertions or encode fixture-specific outcomes.

Current verified state

After fixing distributive-conditional union member ownership:

  • 2,976 / 3,006 pass
  • 30 fail
  • 0 crash (down from 2 crashes)

The crash fix copies union member IDs before recursive conditional evaluation so interner reallocations cannot invalidate a borrowed slice.

Remaining failure clusters

  • Enum/member literal assignment compatibility.
  • Global-script this indexed access diagnostics.
  • Generic defaults, conditional distribution, NonNullable, mapped and template types.
  • Variadic tuple inference and callback arity.
  • Overload diagnostic anchoring and CheckJS/JSDoc arity.
  • Accessor read/write and spread typing.
  • Alias/generic-instance diagnostic rendering.
  • Recursive type depth/circular mapped diagnostics.

Completion gate

  • ./pantry/.bin/zig build test -Dfilter=ts_checker --summary failures reports 3,006 / 3,006.
  • No crash, timeout, or skipped parity assertion replaces a failure.
  • Each semantic cluster lands in a focused conventional commit with regression coverage.
14 days ago

Pushed baseline-policy correction bb7408532 (fix(ts-parity): fall back to original ts baselines).

This implements TS_PORT_DIVERGENCE_NOTES.md: tsgo-generated baselines remain primary, while original TypeScript baselines are used only when tsgo has no matching output for an unported feature.

  • Recovered the 3 resolver fixtures exactly without suppressing diagnostics (3/3 targeted).
  • Scope: 1 conformance file, +32/-1, plus 1 fallback-path regression test.
  • Authoritative leading inventory under the corrected contract: 982/1,000, 18 failures.
  • The prior 997/1,000 projection used only the incomplete tsgo baseline set and is superseded.

The 18 newly visible failures cluster into union/alias identity rendering, generic constraint diagnostic selection, template-literal relation identity, unique-symbol JS validation, and mapped-key identity.

14 days ago

Pushed two direct-main parity chunks as Chris (no coauthors):

  • ad1e57df0 fix(ts-parity): close leading exact conformance slice — 154 additions / 18 deletions in the checker. Flips all 18 corrected layered-baseline failures covering repeated alias identity, conditional distributivity preservation, callable/construct union diagnostics, heritage constraint leaves, and checked-JS unique-symbol modifiers.
  • 95ab2e2d6 test(ts-parity): layer fallback into category survey — 3 additions. Applies the documented original-TypeScript fallback to the baseline-aware category survey.

Measured results against canonical tsgo 24fabe95acba758c05fcb349bf427a3a0c8ad676 plus original-TS fallback only when tsgo has no baseline:

  • authoritative START=0 LIMIT=1000: 982/1000 -> 1000/1000 exact, no skips
  • baseline-aware category survey: 585/586 -> 586/586, including unique-symbol 7/7
  • focused corrected variants: 21/21 exact (substring expansion included 3 related variants)
  • ts_driver: clean
  • broad ts_checker: 3716/3765, with the remaining 49 known red assertions retained as the next package-level backlog

The leading 1,000-case window is now fully exact under the corrected layered baseline inventory. Continuing with START=1000 LIMIT=1000.

14 days ago

Parity checkpoint: exact cases 1,000-1,999 are now 1,000/1,000, so the leading exact range is 2,000/2,000. The baseline-aware category survey remains 586/586.

Pushed as three small conventional commits:

  • 062c361d2 fix(ts-checker): close class diagnostic parity gaps - 8 focused regressions covering private/protected receiver identity, duplicate private declarations, merged class instances, static-super/Reflect collisions, global receivers, and mixin displays.
  • f09848d6b fix(ts-driver): port stage-3 decorator helpers - 4 helper contracts (__esDecorate, __runInitializers, __propKey, __setFunctionName) across direct and program compilation.
  • ab60e1eda fix(ts-conformance): route exact emit targets - 11 target generations through all 3 corpus execution routes.

Verification:

  • exact 1,000-case slice: 1,000/1,000
  • baseline-aware categories: 586/586
  • ts_driver: pass
  • ts_program: pass
  • checker: 3,724/3,773, retaining the same 49 known failures while all 8 new regressions pass
  • conformance unit suite retains the same 6 known failures; no new unit failures

Continuing with exact cases 2,000-2,999.

14 days ago

Exact parity checkpoint: cases 2,000-2,999 are now 1,000/1,000, bringing the leading exact range to 3,000/3,000.

Pushed as two small conventional commits:

  • 5dd8529c5 fix(ts-checker): close checked JS assignment gaps - preserves undefined CommonJS flow, checks method writes against constructor-inferred members, diagnoses cross-file class expandos, and renders chained export-assignment namespaces. Adds 2 regressions and strengthens 2 existing contracts.
  • f39943154 fix(ts-program): collect chained CommonJS exports - records whole exports through exports = module.exports = C while retaining named export metadata. Adds 1 program regression.

Verification:

  • exact cases 2,000-2,999: 1,000/1,000 (up from 994/1,000)
  • targeted original failures: 6/6
  • interaction regression contextualTypedSpecialAssignment: pass
  • ts_program: pass
  • checker: 3,726/3,775, retaining the same 49 known failures while both new regressions pass

Continuing with exact cases 3,000-3,999.

14 days ago

Exact parity checkpoint: 3,879 / 4,000 leading fixtures

Pushed 884513083 (fix(ts-checker): follow tsgo checked JS namespace semantics) as Chris with no coauthors.

  • Fresh exact window 3000-3999: 879 / 1,000 (up from 870, +9 flips)
  • Leading exact total: 3,879 / 4,000
  • Focused current-tsgo checked-JS families: 7 / 7 cumulatively across expanded variants
  • Program suite: passing
  • Change size: 203 insertions / 104 deletions across checker + program
  • Coverage: five checker contracts and one program contract

The batch removed two obsolete fallback-era diagnostics, resolved qualified JSDoc typedefs before namespace errors, separated type-only/value expando metadata, and used future CommonJS assignment types for declaration checking. The remaining 121 fixtures are now being grouped by shared compiler behavior.

14 days ago

Parity checkpoint at 34c846851 (fix(ts-checker): align checked JS declaration flow):

  • Leading exact tsgo corpus is now 3,888/4,000 (up +9 from the prior 3,879 checkpoint).
  • This chunk flipped 3/3 exact fixtures: jsDeclarationsClassLikeHeuristic, jsDeclarationsModuleReferenceHasEmit, and jsDeclarationsTypeReassignmentFromDeclaration2.
  • Broad checker: 3,737/3,784, with the same 47 known failures and all 3 new checker contracts passing.
  • Parser: 842/843; the sole failure remains the unrelated recovered-JavaScript-modifier TS8009 count.
  • Changes were pushed directly to main as Chris with no coauthor.
14 days ago

TypeScript parity checkpoint

Pushed four small conventional commits directly to main as Chris:

  • ca1b6733a fix(ts-checker): recognize declaration-only JSDoc typedefs — flipped 3 checker contracts.
  • 9da6316fc build: add focused TypeScript checker tests — added -Dts-checker-test-filter, reducing focused feedback from roughly 6 minutes to about 20 seconds.
  • 489275840 fix(ts-checker): preserve JavaScript base constructors — flipped the cached checked-JS heritage contract.
  • 1164ad271 fix(ts-checker): preserve JavaScript constructor instances — flipped 6 more contracts across direct-this constructor inference, prototype object this, accurate missing-member diagnostics, and inherited constructor @template scope for direct/object/qualified prototype methods.

Latest authoritative checker sweep: 3,747/3,784 passing (99.02%), up from 3,737/3,784 across this checkpoint, with 37 known failures and no regressions in the latest batch. The full checkjs prototype focused group is green.

Other established floors remain:

  • exact current-tsgo leading corpus: 3,888/4,000
  • baseline-aware category survey: 586/586
  • parser: 842/843, with the sole known JavaScript modifier recovery diagnostic mismatch

Next work stays on the remaining checker clusters before another expensive exact-corpus sweep.

14 days ago

Pushed ffc1f46d1 (fix(ts-checker): align current JSDoc diagnostics) directly to main as Chris.

This batch:

  • preserves exact braced JSDoc text for current tsgo parsing;
  • reports bare @satisfies and empty generic syntax without stale cascades;
  • keeps Closure-style function(...) JSDoc types malformed per current tsgo;
  • renders contextual async callback Promise signatures correctly;
  • deduplicates raw-checker TS2741 diagnostics;
  • updates focused regressions to the canonical tsgo contracts.

Measured progress:

  • full checker: 3,747/3,784 -> 3,754/3,784 (+7, no new failure names);
  • affected exact tsgo fixtures: 7/7;
  • established exact leading corpus remains 3,888/4,000;
  • baseline-aware category survey remains 586/586;
  • parser remains 842/843, with the one known unrelated recovered-JavaScript-modifier diagnostic gap.

The checker now has 30 focused failures remaining.

14 days ago

Pushed ef0ec09cc (fix(ts-checker): align relation identity with tsgo) directly to main as Chris Breuer, with no coauthor trailers.

This chunk changes 118 lines in packages/ts_checker/src/check.zig (74 insertions, 44 deletions): function expandos now bind to their resolved declaration across block shadowing, uppercase Object relations distinguish weak all-optional targets from required targets, indexed sources satisfy open any string indexes, and five local assertions now use current tsgo diagnostic surfaces.

Verification:

  • full checker: 3,754/3,784 -> 3,761/3,784 (+7, 23 remaining)
  • focused checker groups: 6/6 passing, covering 7 tests
  • targeted canonical exact batch: 8/9 exact; only the pre-existing jsDeclarationsReactComponents mismatch remains
  • exact fixtures now matching include narrowingGenericTypeFromInstanceof01, typeGuardIntersectionTypes, mappedTypeErrors, mappedTypeErrors2, objectTypeWithStringAndNumberIndexSignatureToAny, constructorParameterProperties2, typeFromPropertyAssignment29, and typeFromPropertyAssignment36
  • git diff --check: clean
14 days ago

Pushed de8004b6e (fix(ts-checker): adopt current tsgo JavaScript divergence) directly to main as Chris Breuer, without coauthors. This flips 8 previously failing checker cases to the current tsgo contracts (rather than inherited TypeScript baselines): void-zero JS expandos, cross-file qualified JSDoc namespaces, chained CommonJS constructor values, string-literal CommonJS exports, bare/variable constructor this, and cross-file class/JS conflicts. It also removes duplicate TS2339 emission for the same member-access node. Focused current tsgo checker group is 9/9 passing. Based on the previous 3761/3784 full run this should move the checker floor to at least 3769/3784; I am batching the remaining implementation fixes before the next full run.

14 days ago

Pushed 83103570f (test(ts-checker): track current tsgo diagnostic shifts) directly to main as Chris Breuer, without coauthors. This flips 6 more stale checker contracts to the canonical tsgo baselines: ambient namespace prototype TS2339, object-call TS2741, four auto-accessor duplicate diagnostics, malformed @template without the legacy unresolved-name error, enum initializer TS2739, and current checked-JS this diagnostics. The focused current-tsgo group grew from 9/9 to 15/15. Together with the prior shared TS2339 deduplication, the old 23-failure list now has 15 corrected cases plus 1 additional implementation case passing; 7 genuine checker gaps remain before the next full run.

14 days ago

Checker parity batch pushed as 0deb23a (Chris only, no coauthors).\n\n- Closed the final 8 known checker contracts across checked-JS member flow, cross-file prototype ownership, CommonJS whole/rebound exports, private-origin repeated vars, qualified namespace class parameters, and ECMAScript private-brand elaboration.\n- Updated 5 stale assertions to the current tsgo diagnostic shape, including the canonical jsTypedefMergedWithModuleExportProperty baseline (1x TS2339 + TS2309).\n- Full checker result: 3,784/3,784 passing, up 23 from the last full 3,761/3,784 audit.\n\nNext parity work moves to the remaining exact corpus windows and the single parser TS8009 gap.

14 days ago

Pushed 525792858 (fix(ts-checker): align destructuring argument relations) directly to main as Chris.

  • Flipped 4 current-tsgo exact contracts: iterableArrayPattern17, iterableArrayPattern18, destructuringParameterDeclaration1ES6, and destructuringParameterDeclaration4.
  • Exact 4000-4019 is now 20/20, up from 16/20.
  • Added rest-argument missing-property elaboration, nullish default-array element reporting after outer relation failure, nested tuple element priority over width, and current Array remainder text (24).
  • Focused verification: 4/4.

Next exact survey inventory: 4020-4099 is 65/80; failures are clustered around self-reference flow, destructuring control flow, ES5 iterable element precision, parser anchors, and object-rest diagnostics.

14 days ago

Pushed 3ea4342b5 (fix(ts-checker): preserve destructuring source context) directly to main as Chris.

  • Flipped 6 current-tsgo exact fixtures.
  • Exact 4020-4099 improved from 65/80 to 71/80.
  • 4020-4039 is now 20/20; 4060-4079 is 19/20.
  • Preserved positional array-literal and rest-source context, gated circular TS7022 on noImplicitAny, respected var hoisting for TS2448, retained iterator source names, and anchored mixed Map overload diagnostics at the incompatible value.
  • Focused verification: 6/6.
  • Adjacent for-of39 exceeded a 180-second exact audit and is not counted as passing.
14 days ago

Pushed 27440ca fix(ts): align radix and symbol conformance to main as Chris (no coauthor). This batch flipped 9 exact current-tsgo fixtures: 4 binary/octal numeric-property fixtures, 3 well-known-symbol fixtures, iterableArrayPattern7, and typeArgumentInferenceWithClassExpression2. Verification: focused exact 9/9; affected directories 241/255 (14 remaining gaps identified); checker 3,784/3,784; parser 842/843 with the pre-existing TS8009 JavaScript-modifier recovery assertion unchanged. The implementation now canonicalizes arbitrary-length radix keys with JS scientific spelling, preserves anonymous class static/prototype identity, checks symbol-index signature returns, reports current-tsgo duplicate symbol declarations, and scopes Array<t> missing-member diagnostics to the correct destructuring relation.

14 days ago

Pushed a04df0417 (fix(ts-checker): align destructuring width diagnostics) directly to main as Chris Breuer with no coauthors. This flips 3 exact current-tsgo fixtures, moving the 255-fixture affected sweep from 241/255 to 244/255, and also matches 5 additional tuple-bound diagnostics in declarationsAndAssignments. Verification: focused exact 3/3, affected exact 244/255, full ts_checker 3784/3784.

14 days ago

Pushed 171fa99d4 (fix(ts-checker): align nested binding diagnostics) directly to main as Chris Breuer with no coauthors. This flips 2 exact current-tsgo fixtures, moving the 255-fixture affected sweep from 244/255 to 246/255. It closes 4 residual declarationsAndAssignments mismatches and all 4 diagnostics in destructuringParameterDeclaration8. Verification: focused exact 3/3 (including the optional-default regression fixture), affected exact 246/255, full ts_checker 3784/3784.

14 days ago

Pushed e5c75791d (fix(ts-checker): align nested default diagnostics) to main as Chris only.

Parity movement:

  • Added diagnostic-only recursive comparison of array arguments against array binding-pattern defaults.
  • Preserved inferred signature types while reporting exact null/undefined leaf targets, including literal true/false display.
  • Flipped 2 exact tsgo fixtures: destructuringParameterDeclaration1ES5 and destructuringParameterDeclaration1ES5iterable.
  • Affected exact slice: 246/255 -> 248/255 (7 remaining).
  • Full checker regression suite: 3,784/3,784 passing.

Next batch is the remaining destructuring control-flow/grammar recovery and computed-symbol accessor parity.

14 days ago

Pushed c67a022dd (fix(ts-checker): align destructuring recovery diagnostics) to main as Chris only.

Parity movement:

  • Removed stale contextual TS2322 returns from unannotated duplicate getters after TS2300 recovery.
  • Added apparent primitive wrapper diagnostics for object assignment patterns, including static property and dynamic index keys.
  • Preserved declared optional tuple element flow instead of overriding it with a shorter initializer tuple.
  • Restored parenthesized object-rest anchors, TS2701 target checks, and nested array iterator validation.
  • Flipped 3 exact tsgo fixtures: symbolDeclarationEmit12, destructuringControlFlow, and restPropertyWithBindingPattern.
  • Affected exact slice: 248/255 -> 251/255 (4 remaining).
  • Full checker regression suite: 3,784/3,784 passing.

Remaining in this focused cluster: destructuringParameterProperties3 generic tuple inference plus three malformed destructuring parser-recovery fixtures.

14 days ago

Pushed ab204f7a8 fix(ts-checker): infer positional tuple candidates directly to main (Chris only, no coauthors). This adds positional candidate collection for direct mutable tuple type parameters, preserves whole-structure inference for const type parameters, and merges repeated nullish candidates. Exact affected parity moved 251/255 -> 252/255 by flipping destructuringParameterProperties3; the full checker remains 3,784/3,784. The affected slice now has only three malformed parser-recovery fixtures left.

14 days ago

Pushed 04a341f92 fix(ts-checker): recover malformed binding patterns directly to main (Chris only, no coauthors). The parser now preserves HIR after malformed object bindings and missing array closers; the checker ignores zero-width names for property shapes, handles primitive/empty-object unions, respects explicit : any, and checks nested binding defaults. Exact affected parity moved 252/255 -> 253/255 by flipping destructuringObjectBindingPatternAndAssignment3. Verification: checker 3,785/3,785; parser 843/844, with only the pre-existing TS8009 recovery-count test remaining. Two exact affected fixtures remain: destructuringParameterDeclaration2 and destructuringParameterDeclaration6.

14 days ago

Pushed 4abef69a6 (fix(ts-checker): recover destructured parameter contracts) directly to main as Chris.

Parity impact:

  • Flipped destructuringParameterDeclaration2 to exact tsgo parity.
  • Affected exact corpus: 253/255 -> 254/255.
  • Full checker gate: 3,785/3,785.
  • Parser gate: 843/844, with only the existing recovered JavaScript-modifier TS8009 count mismatch (expected 5, found 3).
  • Remaining affected failure: destructuringParameterDeclaration6 reserved-word parser recovery.

The port covers declaration-specific object defaults, duplicate binding names across parameter patterns, fixed tuple width diagnostics, recovered object-argument elaboration, and binding-pattern method compatibility without relying on structurally interned signature metadata.

14 days ago

Pushed 9cfc6341b (fix(ts-parser): recover reserved binding parameters) directly to main as Chris, with no coauthors.

Parity impact:

  • Flipped destructuringParameterDeclaration6 to exact current-tsgo parity.
  • Completed the affected destructuring corpus: 254/255 -> 255/255 exact.
  • Target fixture: 1/1 exact, matching all 21 diagnostics in code, message, position, and order.
  • Full checker gate: 3,785/3,785.
  • Driver suite: passing.
  • Parser gate: 845/846, with only the existing recovered JavaScript-modifier TS8009 count mismatch (expected 5, found 3).

The port keeps malformed reserved array bindings recoverable as bodyless declarations, retains checker-visible missing rest bindings, follows tsgo binder suppression only after true syntactic parse errors, and preserves tsgo same-position diagnostic precedence. The checkpoint changes +212/-17 across 3 files.

14 days ago

Pushed c929e8c79 (fix(ts-checker): resolve tagged template context) to main.

This checkpoint ports tagged-template contextual typing and recursive callable-interface behavior into Home:

  • selects a unique visible arity-compatible overload for tagged substitutions
  • preserves nested generic callback-owned type parameters
  • removes eager TS2347 diagnostics only when contextual parameters make the callback callable
  • refreshes recursive interface member/index shapes at call/member/index consumers
  • prefers direct TS2345 diagnostics for unique arity matches instead of TS2769

Measured parity delta: exact START=4000 LIMIT=1000 advanced 954/1000 -> 960/1000, flipping 6 fixtures with zero regressions:

  • taggedTemplateContextualTyping1/2
  • taggedTemplateStringsWithTypedTags + ES6
  • taggedTemplateStringsWithIncompatibleTypedTags + ES6

Verification: ts_checker 3788/3788, 3 focused tagged-template regressions, zig ast-check, git diff --check, and the full 1,000-case exact slice. The remaining failures in this band are 40.

14 days ago

Pushed 54f45c863 (fix(ts-checker): align literal spread call arity) to main.

This checkpoint:

  • counts source array-literal spread elements for fixed call arity
  • contextually checks each spread element against its positional parameter
  • keeps variable-backed non-tuple spreads on TS2556
  • renders optional fixed-parameter arity as the accepted range (0-1)
  • stops malformed tagged super<T> recovery before semantic constructor arity checking

Measured parity delta: exact START=4000 LIMIT=1000 advanced 960/1000 -> 962/1000, flipping 2 fixtures with zero regressions: arraySpreadInCall and taggedTemplatesWithTypeArguments2.

Verification: focused exact 2/2, ts_checker 3790/3790, zig ast-check, git diff --check, and the full 1,000-case exact slice. Remaining failures in this band: 38.

14 days ago

Pushed 883a94650 (fix(ts-conformance): parse CR-only directives) to main.

The corpus directive reader now tokenizes both CR and LF line endings. This preserves @target: es6 in CR-only upstream sources instead of silently falling back to ES5 and emitting a spurious TS5107.

Measured parity delta: exact START=4000 LIMIT=1000 advanced 962/1000 -> 963/1000, flipping templateStringMultiline3_ES6 with zero regressions.

Verification: focused CR-only target-selection unit test, focused exact 1/1, forced fresh-cache broad exact slice 963/1000, zig ast-check, and git diff --check. Remaining failures in this band: 37.

14 days ago

Pushed bde76e162 (fix(ts-checker): prioritize invalid computed keys) to main.

Computed-key validation now removes nested TS2872/TS2873 diagnostics only after the key type is proven invalid, immediately before TS2464. This preserves truthiness diagnostics for valid computed keys and keeps object-literal this semantics unchanged.

Measured parity delta: exact START=4000 LIMIT=1000 advanced 963/1000 -> 965/1000, flipping computedPropertyNamesDeclarationEmit6_ES5 and _ES6 with zero regressions.

Verification: focused checker regression, focused exact 2/2, corrected fresh-cache broad exact 965/1000, full ts_checker 3791/3791, zig ast-check, and git diff --check. Remaining failures in this band: 35.

14 days ago

Pushed 8897e53b7 (fix(ts-checker): defer duplicate default classes) to main.

Declaration-space entries now track default-export ownership. When two same-named classes are both default exports, TS2300 is suppressed and the dedicated default-export pass emits the canonical TS2528 pair; ordinary duplicate classes and mixed default/named collisions keep TS2300.

Measured parity delta: exact START=4000 LIMIT=1000 advanced 965/1000 -> 966/1000, flipping multipleDefaultExports03 with zero regressions.

Verification: focused checker regression, focused exact 1/1, fresh-cache broad exact 966/1000, full ts_checker 3792/3792, zig ast-check, and git diff --check. Remaining failures in this band: 34.

14 days ago

Pushed 1848a9b52 (fix(ts-lib): restore Array.concat overloads) to main.

The seeded Array<T> surface now models lib.d.ts's array-only and mixed scalar/array concat overloads separately. Invalid arrays therefore fail the overload set with TS2769, while valid scalar, array, and mixed concat calls remain accepted.

Measured parity delta: exact START=4000 LIMIT=1000 advanced 966/1000 -> 967/1000, flipping iteratorSpreadInArray6 with zero regressions.

Verification: focused checker regression, focused exact 1/1, fresh-cache broad exact 967/1000, full ts_checker 3793/3793, both files zig ast-check, and git diff --check. Remaining failures in this band: 33.

14 days ago

Pushed c0c544772 (fix(ts-driver): validate array spread helper arity).

  • Ported the TypeScript ES5 __spreadArray imported-helper contract into both single-file driver and multi-file Program compilation.
  • Added first-spread source anchoring, 3-parameter TS2807 validation, missing-helper TS2343 handling, and missing-tslib TS2354 participation.
  • Added 161 lines across 2 files, including 2 focused regressions with exact spread spans.
  • Flipped arraySpreadImportHelpers; exact 4000-4999 parity advanced 967/1000 -> 968/1000 with zero regressions.
  • Verified ts_driver, ts_program, focused exact conformance 1/1, and broad exact conformance 968/1000.
14 days ago

Pushed 69313e3d7 (fix(ts-checker): align conditional expression typing) to main.

Ported tsgo conditional-expression behavior in one focused checker chunk:

  • reports void and always-defined callable conditions at the correct conditional sites
  • permits numeric 0/1 truthiness idioms while retaining diagnostics for other static numbers
  • contextually types conditional callback branches and preserves inferred return types
  • preserves explicit callback parameter annotations/arity under strictFunctionTypes
  • renders source-owned conditional callback unions without leaking display metadata globally

Parity movement:

  • exact conditionalOperator family: 7/7
  • exact 4,000-4,999 partition: 968 -> 972/1,000 (4 fixtures flipped, 28 remain)
  • checker suite: 3,795/3,795
  • implementation scope: 173 additions, 15 deletions in packages/ts_checker/src/check.zig
14 days ago

Pushed 407294e37 (fix(ts-checker): align operator diagnostics) to main.

Ported another focused tsgo operator batch:

  • TS2365 now renders callable, widened-enum, namespace, and empty-array operands as () => void, E, typeof M, and never[]
  • TS2447 now anchors boolean bitwise diagnostics at the & / | / ^ operator token
  • nullish classification now reads real union constituents before overlapping intersection flags, eliminating false TS18049 diagnostics on numeric enum unions

Parity movement:

  • exact additionOperatorWith family: 11/11
  • exact 4,000-4,999 partition: 972 -> 976/1,000 (4 fixtures flipped, 24 remain)
  • checker suite: 3,797/3,797
  • implementation scope: 115 additions, 34 deletions in packages/ts_checker/src/check.zig
14 days ago

Pushed fba89758c (fix(ts-checker): align this expression contexts) to main.

Ported two current-tsgo this semantics:

  • object-literal methods returning a missing this.member now report the real TS2339 only, without misclassifying the return as recursive TS7023
  • class D extends this now renders typeof globalThis in scripts and undefined in external modules

Parity movement:

  • exact thisIn family: 4/4
  • exact 4,000-4,999 partition: 976 -> 978/1,000 (2 fixtures flipped, 22 remain)
  • checker suite: 3,798/3,798
  • implementation scope: 30 additions, 36 deletions in packages/ts_checker/src/check.zig
14 days ago

Property-access parity batch landed on main as 8e2decc11 (fix(ts): align property access semantics).

  • Preserved the member-access dot after legacy-octal literals (000.toString()), while retaining the existing 01.0 recovery.
  • Distributed string | number index keys across string/number index signatures and required whole-union compatibility for numeric-only indexing.
  • Matched fresh {} read behavior versus widened assignment-target diagnostics for (options || {}), including exact TS2339/TS7053 anchors and chains.
  • Added bracketed Array prototype lookup and source-quoted TS2353 property names.

Exact results:

  • Focused property-access family: 14/14.
  • START=4000 LIMIT=1000: 978/1000 -> 981/1000 (+3), leaving 19 failures.
  • Leading 0..4999: 4,869/5,000 exact.
  • Full ts_checker: 3,801/3,801.
  • ts_lexer: green.
  • ts_parser: 846/847; only the known TS8009 recovery test remains.

The three partition flips are propertyAccessNumericLiterals, propertyAccess, and propertyAccessWidening.

14 days ago

Exact parity progress: malformed object shorthand recovery

Pushed c1c231152 (fix(ts-parser): recover malformed object shorthand).

This ports tsgo's recovery semantics for malformed object-literal members:

  • recognizes get/set accessors when a legal property name follows even if the parameter-list ( is missing;
  • reports the canonical TS1005 anchor and resumes at the next object member;
  • recovers a.b-style shorthand tails as a missing comma without truncating the containing object or namespace;
  • keeps TS18004 unresolved-shorthand checking for a while suppressing TS1117 for those syntactically recovered access tails.

Exact fixtures flipped: 2

  • objectLiteralShorthandPropertiesErrorWithModule
  • objectLiteralShorthandPropertiesErrorFromNotUsingIdentifier

Measured parity

  • focused exact: 2/2
  • exact partition 4000-4999: 983/1,000, up from 981/1,000
  • remaining failures in that partition: 17, down from 19
  • leading exact 0-4999: 4,871/5,000, up from 4,869/5,000
  • checker: 3,802/3,802
  • parser: 848/849; the sole known failure remains the existing TS8009 recovered-JavaScript-modifier diagnostic gap
  • canonical tsgo remains pinned at 24fabe95acba758c05fcb349bf427a3a0c8ad676

The remaining 4000-4999 failures are now the tagged-template family, multipleDefaultExports01, incrementAndDecrement, three contextual-typing fixtures, typeAssertions, constAssertions, commaOperatorWithSecondOperandObjectType, typeOfThisGeneral, and the two constructor-signature comparison fixtures.

14 days ago

Pushed 21faad6d1 (fix(ts-checker): align tagged template overload resolution).

  • Distinguishes compiler-synthesized TemplateStringsArray arguments from ordinary array literals, preserving TS2741 for the missing raw property.
  • Reports TS2554 when ordinary/tagged calls exceed the complete visible overload boundary.
  • Flipped both taggedTemplateStringsWithOverloadResolution1{,_ES6} exact tsgo fixtures: 2/2 exact.
  • 4000-4999 partition advances 983 -> 985/1000; leading 0-4999 advances 4,871 -> 4,873/5,000.
  • Full checker suite: 3,803/3,803.
14 days ago

Pushed 05eeff9f2 (fix(ts-checker): align tagged generic overload diagnostics).

  • Enforces inferred generic constraints during overload applicability instead of leaking post-selection TS2345 diagnostics.
  • Reports TS2769 from the last arity-compatible overload, including the constraint child and related declaration.
  • Adds primitive String legacy members to spelling suggestions without changing structural assignability.
  • Flipped both taggedTemplateStringsWithOverloadResolution3{,_ES6} exact tsgo fixtures: 2/2 exact.
  • 4000-4999 partition advances 985 -> 987/1000; leading 0-4999 advances 4,873 -> 4,875/5,000.
  • Full checker suite: 3,805/3,805.
14 days ago

Pushed 5f4d184b3 (fix(ts-checker): align tagged template type inference).

Parity movement:

  • Flipped 2 exact tsgo fixtures: taggedTemplateStringsTypeArgumentInference and its ES6 variant.
  • Partition 4000-4999: 987/1000 -> 989/1000.
  • Leading exact parity: 4,875/5,000 -> 4,877/5,000.
  • Checker suite: 3,806/3,806 passing.

Implemented repeated generic candidate behavior for tagged templates: widened scalar return inference with literal-only argument diagnostics, mutable object/nullish best-common unions, equivalent-object collapse, explicit any dominance without treating empty-array inference as explicit any, and cleanup of provisional contextual callback diagnostics after successful inference.

14 days ago

Pushed 42062aaf8 (fix(ts-checker): align virtual default export merging).

Parity movement:

  • Flipped multipleDefaultExports01 exact against current tsgo.
  • Partition 4000-4999: 989/1000 -> 990/1000.
  • Leading exact parity: 4,877/5,000 -> 4,878/5,000.
  • Canonical fixture: 1/1 passing.
  • Default-export checker cluster: 24/24 passing.

Implemented order-independent class/function default-export merging per virtual file section, retained all three TS2528 conflicts when a value default joins the merge, deferred merge diagnostics to preserve tsgo ordering, and anchored identifier default exports on the identifier span.

14 days ago

Pushed 8c27e587b (fix(ts-checker): align constructor signature comparisons) directly to main as Chris, with no coauthors.

This ports tsgo's whole-signature constructor comparability behavior: concrete constructor parameters must relate in one consistent direction, while generic constructors and ordinary zero-required-argument overlap remain comparable. It also fixes rest-constructor rendering in TS2365/TS2367 so { new (...a: T[]): R } prints as new (...a: T[]) => R.

Parity impact:

  • comparisonOperatorWithSubtypeObjectOnConstructorSignature: exact pass
  • comparisonOperatorWithNoRelationshipObjectsOnConstructorSignature: exact pass
  • shard 4,000-4,999: 990/1,000 -> 992/1,000
  • leading 5,000: 4,878 -> 4,880 exact passes
  • added 1 focused checker regression covering 6 comparison shapes

Verification:

  • focused checker regression: pass
  • canonical exact filter OnConstructorSignature: 2/2
  • git diff --check: pass

Next cluster: typeAssertions + constAssertions.

14 days ago

Pushed 085539d7b (fix(ts-checker): complete const assertion diagnostics) directly to main as Chris, with no coauthors.

This completes current tsgo constAssertions behavior across four areas: const-asserted object properties are readonly inside their own methods, parenthesized invalid operands keep the opening-parenthesis TS1355 anchor, asserted object assignment failures elaborate at the mismatched property, and TS1355 uses the current singular wording in both checker emissions and the diagnostic catalog.

Parity impact:

  • constAssertions: exact pass
  • shard 4,000-4,999: 992/1,000 -> 993/1,000
  • leading 5,000: 4,880 -> 4,881 exact passes
  • added 1 focused checker regression covering 3 repaired diagnostic surfaces

Verification:

  • focused TS1355 regression: pass
  • focused const semantic regression: pass
  • canonical exact filter constAssertions: 1/1
  • git diff --check: pass

Continuing with the remaining typeAssertions fixture in the assertion cluster.

14 days ago

Pushed 1594b5edf (fix(ts-parser): preserve type assertion recovery) to main as Chris, with no coauthor trailers.

Parity movement:

  • Flipped canonical typeAssertions from failing to exact pass.
  • typeAssertions filtered group: 3/3 exact.
  • Exact shard 4000-4999: 993 -> 994 / 1000.
  • Leading exact corpus 0-4999: 4,881 -> 4,882 / 5,000.

Implementation:

  • Preserved the parsed source root through malformed predicate-like assertion tails, restoring all earlier binder/checker diagnostics.
  • Matched tsgo TS1434/TS1128 recovery ordering for (expr as value is string).
  • Ported tsgo binary + result behavior so one any operand remains any after concrete string/number checks, removing the spurious TS2403.
  • Added 1 parser and 2 checker regressions.

Verification:

  • Canonical exact typeAssertions filter: 3 passed, 0 failed.
  • Focused checker regressions: pass.
  • Parser suite: 849/850; only the tracked pre-existing TS8009 diagnostic-count mismatch remains.
14 days ago

Pushed 869c8b123 (fix(ts-checker): propagate contextual callable types) to main as Chris.

This chunk flips 3 exact tsgo fixtures by porting contextual callable propagation through overload arity selection, inherited super construct signatures, conditional/comma wrappers, nested returns, and typed object-literal arrows.

Parity movement:

  • 4000-4999: 994/1000 -> 997/1000
  • leading 0-4999: 4,882/5,000 -> 4,885/5,000

Exact verification:

  • parenthesizedContexualTyping2: 1/1
  • ContextualTyping2 filter: 3/3 (including superCallParameterContextualTyping2)
  • generatedContextualTyping: 1/1
  • 5 focused checker regressions pass

Remaining in the shard: incrementAndDecrement, commaOperatorWithSecondOperandObjectType, and typeOfThisGeneral.

14 days ago

Pushed two small parity chunks to main as Chris (no coauthors):

  • 48fa953ec fix(ts-parser): align operator statement recovery (+37): rejects update-expression assignment at =, honors ASI before postfix !, and restores 2 recovered-object TS8009 diagnostics. This flips commaOperatorWithSecondOperandObjectType, supplies the parser half of incrementAndDecrement, and leaves the parser suite at 852/852.
  • 9f6464c8f fix(ts-checker): complete operator and this parity (+186/-22): assigns contextual-return diagnostics to the correct expression owner, distinguishes bare window TS2304 from member TS2812 under explicit non-DOM libs, honors @strict: false for constructor/globalThis checks, and merges polymorphic-this default parameters with hoisted body var declarations while preserving generic TS2403 text.

Exact results:

  • formerly failing quartet: 4/4 exact
  • contextual/operator/this regression batch: 7/7 exact
  • exact corpus shard 4,000-4,999: 1,000/1,000 (up from 996/1,000 before this batch; parser commit moved it to 997, checker commit completed the final 3)

The canonical tsgo submodule remains configured at _submodules/typescript-go, branch = main, pinned to 24fabe95acba758c05fcb349bf427a3a0c8ad676.

A full checker-unit sweep also identified the next seven-test follow-up queue (predicate this positions, contextual object-union ownership, undefined as this, generic callback inference, two JSDoc contextual-flow cases, and non-array .map spread typing). Those are unit-level parity gaps outside this now-green exact shard and are the next batch.

14 days ago

Pushed three checker parity commits to main as Chris (no co-authors):

  • cc59ccd52 fix(ts-checker): align callable relation ownership - closed 3 focused regressions around explicit-this predicate callbacks, contextual object-union method return ownership, and assertions to polymorphic this.
  • 2cc7800b3 fix(ts-checker): preserve generic instantiation boundaries - closed the qualified typeof node.member<any> inference boundary regression.
  • 13c4de62c fix(ts-checker): close 3 contextual typing gaps - 82 insertions / 20 deletions closing inline JSDoc @satisfies ownership, chained dotted-optional JSDoc TS18048 reporting, and non-array .map callback ownership.

Verification on the pushed tree:

  • full ts_checker suite: pass
  • parser suite remains 852/852 from 48fa953ec
  • exact conformance shard 4000-4999 remains 1000/1000 from 9f6464c8f
  • affected exact conformance fixtures: 4/4 (spreadNonObject1, checkJsdocSatisfiesTag3, both jsDeclarationsOptionalTypeLiteralProps variants)
  • affected exact compiler fixture: 1/1 (symbolToNodeBoundaryNoStackOverflow)

This closes all seven checker unit gaps isolated from the last full checker run with semantic implementations rather than harness exceptions.

14 days ago

TS parity checkpoint: scanner recovery batch

Pushed 40b9a10e0 (fix(ts-parser): recover escaped keywords and null bytes) to main as Chris Breuer with no coauthor trailers.

  • Flipped 2 exact conformance fixtures: scannerUnicodeEscapeInKeyword2 and scannerUnexpectedNullCharacter1.
  • Preserved binary expressions across embedded NUL scanner tokens while retaining both canonical TS1127 diagnostics.
  • Restricted TS1260 ownership to true keyword positions; escaped await/yield bindings, type-alias names, and object keys remain legal IdentifierNames.
  • Matched all 7 canonical TS1260 diagnostics across the two virtual escaped-keyword files.
  • Change size: 72 insertions, 6 deletions in packages/ts_parser/src/ts_parser.zig.

Verification:

  • Parser suite: 854/854 passed.
  • Focused exact conformance: 2/2 passed.
  • Fresh measured full baseline before this batch: 5,624/5,907 (95.21%), 283 failures.
  • Inferred dashboard after these exact flips: 5,626/5,907 (95.25%), 281 failures. A later full exact sweep will remeasure this directly.
14 days ago

TS parity checkpoint: inline JSX scope batch

Pushed ef0506f16 (fix(ts-checker): scope inline JSX factories per file) to main as Chris Breuer with no coauthor trailers.

  • Flipped 2 exact fixtures: inlineJsxAndJsxFragPragma and inlineJsxFactoryWithFragmentIsError.
  • Kept inlineJsxAndJsxFragPragmaOverridesCompilerOptions green in the same focused exact run.
  • Scoped @jsx / @jsxFrag parsing and factory lookup to each virtual file.
  • Counted classic JSX factory and fragment imports as reads for noUnusedLocals.
  • Prevented renderer declarations from leaking into sibling virtual-file scope.
  • Exposed declare global { namespace JSX { ... } } to intrinsic lookup.
  • Reported both classic fragment aliases while preserving TS17017 and TS2879 ownership.
  • Change size: 141 insertions, 27 deletions in packages/ts_checker/src/check.zig.

Verification:

  • Complete checker suite passed.
  • Focused checker regression passed.
  • Focused exact conformance: 3/3 passed.
  • Inferred dashboard after this batch: 5,628/5,907 (95.28%), 279 failures. A later full exact sweep will remeasure directly.
14 days ago

TS parity checkpoint: JSX recovery and value semantics

Pushed two small conventional commits to main as Chris Breuer with no coauthor trailers:

  • 6654d3366 fix(ts-parser): stop malformed fragment sibling recovery
    • Flipped tsxFragmentErrors.
    • Stops TS2657 sibling recovery at a new line after malformed-fragment TS17014/TS17015 recovery.
    • Change size: 21 insertions.
  • 1563c89fb fix(ts-checker): align JSX tags and comma side effects
    • Flipped tsxDynamicTagName9 and tsxEmit3.
    • Treats literal-valued dynamic tags as intrinsic when no IntrinsicElements declaration exists.
    • Treats member/element access as observably effectful comma operands, matching tsgo isSideEffectFree ownership.
    • Change size: 27 insertions, 1 deletion.

Verification:

  • Parser suite: 855/855 passed.
  • Complete checker suite passed.
  • Focused exact conformance: 3/3 passed.
  • Inferred dashboard after these 3 flips: 5,631/5,907 (95.33%), 276 failures. A later full exact sweep will remeasure directly.
14 days ago

TS parity checkpoint: JSX option-matrix ownership

Pushed 3784a7e30 (fix(ts-driver): separate JSX option matrices from pragmas) to main as Chris Breuer with no coauthor trailers.

  • Flipped jsxAttributeInitializer.
  • Prevented comma-separated // @jsx compiler-option matrices from being treated as inline custom JSX factory pragmas.
  • Preserved TS17017 for real block-comment @jsx pragmas without @jsxFrag.
  • Change size: 16 insertions, 1 deletion in packages/ts_driver/src/ts_driver.zig.

Verification:

  • Complete driver suite passed.
  • Focused exact conformance: 1/1 passed.
  • Inferred dashboard: 5,632/5,907 (95.35%), 275 failures. A later full exact sweep will remeasure directly.
14 days ago

TS parity checkpoint: JSX scanner and close recovery

Pushed 929be2243 (fix(ts-parser): align JSX text and closing recovery) to main as Chris Breuer with no coauthor trailers.

  • Flipped jsxParsingError2, jsxParsingError3, and jsxParsingErrorImmediateSpreadInAttributeValue.
  • Ported tsgo parent-closing-tag reattachment so an unclosed nested JSX child leaves its parent close available.
  • Restored the single root EOF TS1005: </ expected diagnostic.
  • Split adjacent greater tokens at the JSX opening/text boundary and removed duplicate internal stray-text diagnostics.
  • Change size: 94 insertions, 8 deletions in packages/ts_parser/src/ts_parser.zig.

Verification:

  • Complete parser suite: 858/858 passed.
  • Focused exact jsxParsingError* family: 5/5 passed.
  • Inferred dashboard: 5,635/5,907 (95.40%), 272 failures. A later full exact sweep will remeasure directly.

Sign in to comment on this issue.