@tsonic/frontend 0.0.74 → 0.0.75
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/.tsbuildinfo +1 -1
- package/dist/core-intrinsics/provenance.d.ts +7 -0
- package/dist/core-intrinsics/provenance.d.ts.map +1 -1
- package/dist/core-intrinsics/provenance.js +27 -4
- package/dist/core-intrinsics/provenance.js.map +1 -1
- package/dist/graph/extraction/imports.d.ts.map +1 -1
- package/dist/graph/extraction/imports.js +2 -0
- package/dist/graph/extraction/imports.js.map +1 -1
- package/dist/ir/binding/binding-call-resolution-calls.d.ts +11 -0
- package/dist/ir/binding/binding-call-resolution-calls.d.ts.map +1 -0
- package/dist/ir/binding/binding-call-resolution-calls.js +974 -0
- package/dist/ir/binding/binding-call-resolution-calls.js.map +1 -0
- package/dist/ir/binding/binding-call-resolution-candidates.d.ts +15 -0
- package/dist/ir/binding/binding-call-resolution-candidates.d.ts.map +1 -0
- package/dist/ir/binding/binding-call-resolution-candidates.js +178 -0
- package/dist/ir/binding/binding-call-resolution-candidates.js.map +1 -0
- package/dist/ir/binding/binding-call-resolution.d.ts +11 -0
- package/dist/ir/binding/binding-call-resolution.d.ts.map +1 -0
- package/dist/ir/binding/binding-call-resolution.js +11 -0
- package/dist/ir/binding/binding-call-resolution.js.map +1 -0
- package/dist/ir/binding/binding-factory.d.ts +7 -4
- package/dist/ir/binding/binding-factory.d.ts.map +1 -1
- package/dist/ir/binding/binding-factory.js +44 -829
- package/dist/ir/binding/binding-factory.js.map +1 -1
- package/dist/ir/binding/binding-helpers.d.ts +1 -0
- package/dist/ir/binding/binding-helpers.d.ts.map +1 -1
- package/dist/ir/binding/binding-helpers.js +37 -14
- package/dist/ir/binding/binding-helpers.js.map +1 -1
- package/dist/ir/binding/binding-registry.d.ts +52 -0
- package/dist/ir/binding/binding-registry.d.ts.map +1 -0
- package/dist/ir/binding/binding-registry.js +582 -0
- package/dist/ir/binding/binding-registry.js.map +1 -0
- package/dist/ir/binding/binding-types.d.ts +2 -0
- package/dist/ir/binding/binding-types.d.ts.map +1 -1
- package/dist/ir/binding-resolution-cases/extension-method-binding.test.d.ts +7 -0
- package/dist/ir/binding-resolution-cases/extension-method-binding.test.d.ts.map +1 -0
- package/dist/ir/binding-resolution-cases/extension-method-binding.test.js +463 -0
- package/dist/ir/binding-resolution-cases/extension-method-binding.test.js.map +1 -0
- package/dist/ir/binding-resolution-cases/extension-method-owner-resolution.test.d.ts +6 -0
- package/dist/ir/binding-resolution-cases/extension-method-owner-resolution.test.d.ts.map +1 -0
- package/dist/ir/binding-resolution-cases/extension-method-owner-resolution.test.js +252 -0
- package/dist/ir/binding-resolution-cases/extension-method-owner-resolution.test.js.map +1 -0
- package/dist/ir/binding-resolution-cases/extension-method-tsbindgen-modifiers.test.d.ts +6 -0
- package/dist/ir/binding-resolution-cases/extension-method-tsbindgen-modifiers.test.d.ts.map +1 -0
- package/dist/ir/binding-resolution-cases/extension-method-tsbindgen-modifiers.test.js +369 -0
- package/dist/ir/binding-resolution-cases/extension-method-tsbindgen-modifiers.test.js.map +1 -0
- package/dist/ir/binding-resolution-cases/extract-type-name.test.d.ts +5 -0
- package/dist/ir/binding-resolution-cases/extract-type-name.test.d.ts.map +1 -0
- package/dist/ir/binding-resolution-cases/extract-type-name.test.js +57 -0
- package/dist/ir/binding-resolution-cases/extract-type-name.test.js.map +1 -0
- package/dist/ir/binding-resolution-cases/global-binding-preferences.test.d.ts +5 -0
- package/dist/ir/binding-resolution-cases/global-binding-preferences.test.d.ts.map +1 -0
- package/dist/ir/binding-resolution-cases/global-binding-preferences.test.js +323 -0
- package/dist/ir/binding-resolution-cases/global-binding-preferences.test.js.map +1 -0
- package/dist/ir/binding-resolution-cases/global-identifier-resolution.test.d.ts +5 -0
- package/dist/ir/binding-resolution-cases/global-identifier-resolution.test.d.ts.map +1 -0
- package/dist/ir/binding-resolution-cases/global-identifier-resolution.test.js +1057 -0
- package/dist/ir/binding-resolution-cases/global-identifier-resolution.test.js.map +1 -0
- package/dist/ir/binding-resolution-cases/helpers.d.ts +38 -0
- package/dist/ir/binding-resolution-cases/helpers.d.ts.map +1 -0
- package/dist/ir/binding-resolution-cases/helpers.js +59 -0
- package/dist/ir/binding-resolution-cases/helpers.js.map +1 -0
- package/dist/ir/binding-resolution-cases/hierarchical-binding-resolution.test.d.ts +5 -0
- package/dist/ir/binding-resolution-cases/hierarchical-binding-resolution.test.d.ts.map +1 -0
- package/dist/ir/binding-resolution-cases/hierarchical-binding-resolution.test.js +259 -0
- package/dist/ir/binding-resolution-cases/hierarchical-binding-resolution.test.js.map +1 -0
- package/dist/ir/binding-resolution-cases/imported-globals-shadowing.test.d.ts +2 -0
- package/dist/ir/binding-resolution-cases/imported-globals-shadowing.test.d.ts.map +1 -0
- package/dist/ir/binding-resolution-cases/imported-globals-shadowing.test.js +566 -0
- package/dist/ir/binding-resolution-cases/imported-globals-shadowing.test.js.map +1 -0
- package/dist/ir/binding-resolution-cases/js-array-member-binding.test.d.ts +5 -0
- package/dist/ir/binding-resolution-cases/js-array-member-binding.test.d.ts.map +1 -0
- package/dist/ir/binding-resolution-cases/js-array-member-binding.test.js +186 -0
- package/dist/ir/binding-resolution-cases/js-array-member-binding.test.js.map +1 -0
- package/dist/ir/binding-resolution-cases/module-import-type-alias-renaming.test.d.ts +6 -0
- package/dist/ir/binding-resolution-cases/module-import-type-alias-renaming.test.d.ts.map +1 -0
- package/dist/ir/binding-resolution-cases/module-import-type-alias-renaming.test.js +198 -0
- package/dist/ir/binding-resolution-cases/module-import-type-alias-renaming.test.js.map +1 -0
- package/dist/ir/binding-resolution.test.d.ts +9 -4
- package/dist/ir/binding-resolution.test.d.ts.map +1 -1
- package/dist/ir/binding-resolution.test.js +9 -1428
- package/dist/ir/binding-resolution.test.js.map +1 -1
- package/dist/ir/bindings-disambiguation-cases/failure-disambiguation.test.d.ts +8 -0
- package/dist/ir/bindings-disambiguation-cases/failure-disambiguation.test.d.ts.map +1 -0
- package/dist/ir/bindings-disambiguation-cases/failure-disambiguation.test.js +255 -0
- package/dist/ir/bindings-disambiguation-cases/failure-disambiguation.test.js.map +1 -0
- package/dist/ir/bindings-disambiguation-cases/success-disambiguation.test.d.ts +11 -0
- package/dist/ir/bindings-disambiguation-cases/success-disambiguation.test.d.ts.map +1 -0
- package/dist/ir/bindings-disambiguation-cases/success-disambiguation.test.js +326 -0
- package/dist/ir/bindings-disambiguation-cases/success-disambiguation.test.js.map +1 -0
- package/dist/ir/bindings-disambiguation.test.d.ts +2 -10
- package/dist/ir/bindings-disambiguation.test.d.ts.map +1 -1
- package/dist/ir/bindings-disambiguation.test.js +2 -561
- package/dist/ir/bindings-disambiguation.test.js.map +1 -1
- package/dist/ir/builder/exports.d.ts +2 -2
- package/dist/ir/builder/exports.d.ts.map +1 -1
- package/dist/ir/builder/exports.js +6 -10
- package/dist/ir/builder/exports.js.map +1 -1
- package/dist/ir/builder/imports.d.ts.map +1 -1
- package/dist/ir/builder/imports.js +104 -58
- package/dist/ir/builder/imports.js.map +1 -1
- package/dist/ir/builder/orchestrator.d.ts.map +1 -1
- package/dist/ir/builder/orchestrator.js +7 -9
- package/dist/ir/builder/orchestrator.js.map +1 -1
- package/dist/ir/builder/statements.d.ts +5 -0
- package/dist/ir/builder/statements.d.ts.map +1 -1
- package/dist/ir/builder/statements.js +16 -5
- package/dist/ir/builder/statements.js.map +1 -1
- package/dist/ir/builder-cases/_test-helpers.d.ts +61 -0
- package/dist/ir/builder-cases/_test-helpers.d.ts.map +1 -0
- package/dist/ir/builder-cases/_test-helpers.js +123 -0
- package/dist/ir/builder-cases/_test-helpers.js.map +1 -0
- package/dist/ir/builder-cases/call-inference-generics/alias-cache.test.d.ts +2 -0
- package/dist/ir/builder-cases/call-inference-generics/alias-cache.test.d.ts.map +1 -0
- package/dist/ir/builder-cases/call-inference-generics/alias-cache.test.js +123 -0
- package/dist/ir/builder-cases/call-inference-generics/alias-cache.test.js.map +1 -0
- package/dist/ir/builder-cases/call-inference-generics/context-threading.test.d.ts +2 -0
- package/dist/ir/builder-cases/call-inference-generics/context-threading.test.d.ts.map +1 -0
- package/dist/ir/builder-cases/call-inference-generics/context-threading.test.js +839 -0
- package/dist/ir/builder-cases/call-inference-generics/context-threading.test.js.map +1 -0
- package/dist/ir/builder-cases/clr-identity.test.d.ts +5 -0
- package/dist/ir/builder-cases/clr-identity.test.d.ts.map +1 -0
- package/dist/ir/builder-cases/clr-identity.test.js +188 -0
- package/dist/ir/builder-cases/clr-identity.test.js.map +1 -0
- package/dist/ir/builder-cases/clr-iterable-overload-resolution.test.d.ts +2 -0
- package/dist/ir/builder-cases/clr-iterable-overload-resolution.test.d.ts.map +1 -0
- package/dist/ir/builder-cases/clr-iterable-overload-resolution.test.js +1436 -0
- package/dist/ir/builder-cases/clr-iterable-overload-resolution.test.js.map +1 -0
- package/dist/ir/builder-cases/conditional-narrowing.test.d.ts +5 -0
- package/dist/ir/builder-cases/conditional-narrowing.test.d.ts.map +1 -0
- package/dist/ir/builder-cases/conditional-narrowing.test.js +598 -0
- package/dist/ir/builder-cases/conditional-narrowing.test.js.map +1 -0
- package/dist/ir/builder-cases/contextual-typing-middleware.test.d.ts +5 -0
- package/dist/ir/builder-cases/contextual-typing-middleware.test.d.ts.map +1 -0
- package/dist/ir/builder-cases/contextual-typing-middleware.test.js +384 -0
- package/dist/ir/builder-cases/contextual-typing-middleware.test.js.map +1 -0
- package/dist/ir/builder-cases/expression-conversion.test.d.ts +5 -0
- package/dist/ir/builder-cases/expression-conversion.test.d.ts.map +1 -0
- package/dist/ir/builder-cases/expression-conversion.test.js +712 -0
- package/dist/ir/builder-cases/expression-conversion.test.js.map +1 -0
- package/dist/ir/builder-cases/fluent-and-nullable-params.test.d.ts +5 -0
- package/dist/ir/builder-cases/fluent-and-nullable-params.test.d.ts.map +1 -0
- package/dist/ir/builder-cases/fluent-and-nullable-params.test.js +170 -0
- package/dist/ir/builder-cases/fluent-and-nullable-params.test.js.map +1 -0
- package/dist/ir/builder-cases/for-of-loops.test.d.ts +5 -0
- package/dist/ir/builder-cases/for-of-loops.test.d.ts.map +1 -0
- package/dist/ir/builder-cases/for-of-loops.test.js +367 -0
- package/dist/ir/builder-cases/for-of-loops.test.js.map +1 -0
- package/dist/ir/builder-cases/generic-call-parameter-specialization.test.d.ts +2 -0
- package/dist/ir/builder-cases/generic-call-parameter-specialization.test.d.ts.map +1 -0
- package/dist/ir/builder-cases/generic-call-parameter-specialization.test.js +192 -0
- package/dist/ir/builder-cases/generic-call-parameter-specialization.test.js.map +1 -0
- package/dist/ir/builder-cases/implements-and-struct.test.d.ts +5 -0
- package/dist/ir/builder-cases/implements-and-struct.test.d.ts.map +1 -0
- package/dist/ir/builder-cases/implements-and-struct.test.js +145 -0
- package/dist/ir/builder-cases/implements-and-struct.test.js.map +1 -0
- package/dist/ir/builder-cases/import-extraction.test.d.ts +5 -0
- package/dist/ir/builder-cases/import-extraction.test.d.ts.map +1 -0
- package/dist/ir/builder-cases/import-extraction.test.js +852 -0
- package/dist/ir/builder-cases/import-extraction.test.js.map +1 -0
- package/dist/ir/builder-cases/imported-null-guard-assignments.test.d.ts +2 -0
- package/dist/ir/builder-cases/imported-null-guard-assignments.test.d.ts.map +1 -0
- package/dist/ir/builder-cases/imported-null-guard-assignments.test.js +185 -0
- package/dist/ir/builder-cases/imported-null-guard-assignments.test.js.map +1 -0
- package/dist/ir/builder-cases/imported-union-aliases.test.d.ts +2 -0
- package/dist/ir/builder-cases/imported-union-aliases.test.d.ts.map +1 -0
- package/dist/ir/builder-cases/imported-union-aliases.test.js +255 -0
- package/dist/ir/builder-cases/imported-union-aliases.test.js.map +1 -0
- package/dist/ir/builder-cases/installed-source-package-deterministic-typing.test.d.ts +2 -0
- package/dist/ir/builder-cases/installed-source-package-deterministic-typing.test.d.ts.map +1 -0
- package/dist/ir/builder-cases/installed-source-package-deterministic-typing.test.js +1267 -0
- package/dist/ir/builder-cases/installed-source-package-deterministic-typing.test.js.map +1 -0
- package/dist/ir/builder-cases/invocation-flow-assertions.test.d.ts +2 -0
- package/dist/ir/builder-cases/invocation-flow-assertions.test.d.ts.map +1 -0
- package/dist/ir/builder-cases/invocation-flow-assertions.test.js +198 -0
- package/dist/ir/builder-cases/invocation-flow-assertions.test.js.map +1 -0
- package/dist/ir/builder-cases/js-surface-helpers.test.d.ts +5 -0
- package/dist/ir/builder-cases/js-surface-helpers.test.d.ts.map +1 -0
- package/dist/ir/builder-cases/js-surface-helpers.test.js +1990 -0
- package/dist/ir/builder-cases/js-surface-helpers.test.js.map +1 -0
- package/dist/ir/builder-cases/module-structure-and-exports.test.d.ts +5 -0
- package/dist/ir/builder-cases/module-structure-and-exports.test.d.ts.map +1 -0
- package/dist/ir/builder-cases/module-structure-and-exports.test.js +97 -0
- package/dist/ir/builder-cases/module-structure-and-exports.test.js.map +1 -0
- package/dist/ir/builder-cases/namespace-imports-and-function-narrowing.test.d.ts +5 -0
- package/dist/ir/builder-cases/namespace-imports-and-function-narrowing.test.d.ts.map +1 -0
- package/dist/ir/builder-cases/namespace-imports-and-function-narrowing.test.js +511 -0
- package/dist/ir/builder-cases/namespace-imports-and-function-narrowing.test.js.map +1 -0
- package/dist/ir/builder-cases/narrowing-isarray-and-typeof.test.d.ts +5 -0
- package/dist/ir/builder-cases/narrowing-isarray-and-typeof.test.d.ts.map +1 -0
- package/dist/ir/builder-cases/narrowing-isarray-and-typeof.test.js +676 -0
- package/dist/ir/builder-cases/narrowing-isarray-and-typeof.test.js.map +1 -0
- package/dist/ir/builder-cases/object-exports-and-member-inference.test.d.ts +5 -0
- package/dist/ir/builder-cases/object-exports-and-member-inference.test.d.ts.map +1 -0
- package/dist/ir/builder-cases/object-exports-and-member-inference.test.js +159 -0
- package/dist/ir/builder-cases/object-exports-and-member-inference.test.js.map +1 -0
- package/dist/ir/builder-cases/object-synthesis-advanced.test.d.ts +5 -0
- package/dist/ir/builder-cases/object-synthesis-advanced.test.d.ts.map +1 -0
- package/dist/ir/builder-cases/object-synthesis-advanced.test.js +250 -0
- package/dist/ir/builder-cases/object-synthesis-advanced.test.js.map +1 -0
- package/dist/ir/builder-cases/object-synthesis.test.d.ts +5 -0
- package/dist/ir/builder-cases/object-synthesis.test.d.ts.map +1 -0
- package/dist/ir/builder-cases/object-synthesis.test.js +254 -0
- package/dist/ir/builder-cases/object-synthesis.test.js.map +1 -0
- package/dist/ir/builder-cases/overload-family-markers.test.d.ts +2 -0
- package/dist/ir/builder-cases/overload-family-markers.test.d.ts.map +1 -0
- package/dist/ir/builder-cases/overload-family-markers.test.js +264 -0
- package/dist/ir/builder-cases/overload-family-markers.test.js.map +1 -0
- package/dist/ir/builder-cases/overload-null-guard-selection.test.d.ts +2 -0
- package/dist/ir/builder-cases/overload-null-guard-selection.test.d.ts.map +1 -0
- package/dist/ir/builder-cases/overload-null-guard-selection.test.js +210 -0
- package/dist/ir/builder-cases/overload-null-guard-selection.test.js.map +1 -0
- package/dist/ir/builder-cases/overload-stub-typing.test.d.ts +2 -0
- package/dist/ir/builder-cases/overload-stub-typing.test.d.ts.map +1 -0
- package/dist/ir/builder-cases/overload-stub-typing.test.js +111 -0
- package/dist/ir/builder-cases/overload-stub-typing.test.js.map +1 -0
- package/dist/ir/builder-cases/private-members-and-instanceof.test.d.ts +5 -0
- package/dist/ir/builder-cases/private-members-and-instanceof.test.d.ts.map +1 -0
- package/dist/ir/builder-cases/private-members-and-instanceof.test.js +239 -0
- package/dist/ir/builder-cases/private-members-and-instanceof.test.js.map +1 -0
- package/dist/ir/builder-cases/promise-callback-typing.test.d.ts +5 -0
- package/dist/ir/builder-cases/promise-callback-typing.test.d.ts.map +1 -0
- package/dist/ir/builder-cases/promise-callback-typing.test.js +977 -0
- package/dist/ir/builder-cases/promise-callback-typing.test.js.map +1 -0
- package/dist/ir/builder-cases/recursive-aliases-and-flow-types.test.d.ts +5 -0
- package/dist/ir/builder-cases/recursive-aliases-and-flow-types.test.d.ts.map +1 -0
- package/dist/ir/builder-cases/recursive-aliases-and-flow-types.test.js +509 -0
- package/dist/ir/builder-cases/recursive-aliases-and-flow-types.test.js.map +1 -0
- package/dist/ir/builder-cases/statement-conversion.test.d.ts +5 -0
- package/dist/ir/builder-cases/statement-conversion.test.d.ts.map +1 -0
- package/dist/ir/builder-cases/statement-conversion.test.js +240 -0
- package/dist/ir/builder-cases/statement-conversion.test.js.map +1 -0
- package/dist/ir/builder-cases/type-access-and-records.test.d.ts +5 -0
- package/dist/ir/builder-cases/type-access-and-records.test.d.ts.map +1 -0
- package/dist/ir/builder-cases/type-access-and-records.test.js +420 -0
- package/dist/ir/builder-cases/type-access-and-records.test.js.map +1 -0
- package/dist/ir/builder-cases/typeof-narrowing-and-intrinsics.test.d.ts +5 -0
- package/dist/ir/builder-cases/typeof-narrowing-and-intrinsics.test.d.ts.map +1 -0
- package/dist/ir/builder-cases/typeof-narrowing-and-intrinsics.test.js +187 -0
- package/dist/ir/builder-cases/typeof-narrowing-and-intrinsics.test.js.map +1 -0
- package/dist/ir/builder.test.d.ts +27 -4
- package/dist/ir/builder.test.d.ts.map +1 -1
- package/dist/ir/builder.test.js +27 -3583
- package/dist/ir/builder.test.js.map +1 -1
- package/dist/ir/converters/access-paths.d.ts +20 -0
- package/dist/ir/converters/access-paths.d.ts.map +1 -0
- package/dist/ir/converters/access-paths.js +163 -0
- package/dist/ir/converters/access-paths.js.map +1 -0
- package/dist/ir/converters/array-type-guards.d.ts +7 -0
- package/dist/ir/converters/array-type-guards.d.ts.map +1 -0
- package/dist/ir/converters/array-type-guards.js +33 -0
- package/dist/ir/converters/array-type-guards.js.map +1 -0
- package/dist/ir/converters/assertion-wrapping.d.ts +4 -0
- package/dist/ir/converters/assertion-wrapping.d.ts.map +1 -0
- package/dist/ir/converters/assertion-wrapping.js +40 -0
- package/dist/ir/converters/assertion-wrapping.js.map +1 -0
- package/dist/ir/converters/expressions/access/access-converter.d.ts.map +1 -1
- package/dist/ir/converters/expressions/access/access-converter.js +104 -40
- package/dist/ir/converters/expressions/access/access-converter.js.map +1 -1
- package/dist/ir/converters/expressions/access/binding-resolution-hierarchical.d.ts +18 -0
- package/dist/ir/converters/expressions/access/binding-resolution-hierarchical.d.ts.map +1 -0
- package/dist/ir/converters/expressions/access/binding-resolution-hierarchical.js +347 -0
- package/dist/ir/converters/expressions/access/binding-resolution-hierarchical.js.map +1 -0
- package/dist/ir/converters/expressions/access/binding-resolution-memberid.d.ts +28 -0
- package/dist/ir/converters/expressions/access/binding-resolution-memberid.d.ts.map +1 -0
- package/dist/ir/converters/expressions/access/binding-resolution-memberid.js +522 -0
- package/dist/ir/converters/expressions/access/binding-resolution-memberid.js.map +1 -0
- package/dist/ir/converters/expressions/access/binding-resolution.d.ts +7 -31
- package/dist/ir/converters/expressions/access/binding-resolution.d.ts.map +1 -1
- package/dist/ir/converters/expressions/access/binding-resolution.js +7 -490
- package/dist/ir/converters/expressions/access/binding-resolution.js.map +1 -1
- package/dist/ir/converters/expressions/access/member-resolution.d.ts +7 -6
- package/dist/ir/converters/expressions/access/member-resolution.d.ts.map +1 -1
- package/dist/ir/converters/expressions/access/member-resolution.js +323 -77
- package/dist/ir/converters/expressions/access/member-resolution.js.map +1 -1
- package/dist/ir/converters/expressions/ambient-global-source-owner.d.ts +5 -0
- package/dist/ir/converters/expressions/ambient-global-source-owner.d.ts.map +1 -0
- package/dist/ir/converters/expressions/ambient-global-source-owner.js +252 -0
- package/dist/ir/converters/expressions/ambient-global-source-owner.js.map +1 -0
- package/dist/ir/converters/expressions/array-literals.d.ts +25 -0
- package/dist/ir/converters/expressions/array-literals.d.ts.map +1 -0
- package/dist/ir/converters/expressions/array-literals.js +356 -0
- package/dist/ir/converters/expressions/array-literals.js.map +1 -0
- package/dist/ir/converters/expressions/calls/bound-global-call-parameters.d.ts +13 -0
- package/dist/ir/converters/expressions/calls/bound-global-call-parameters.d.ts.map +1 -0
- package/dist/ir/converters/expressions/calls/bound-global-call-parameters.js +56 -0
- package/dist/ir/converters/expressions/calls/bound-global-call-parameters.js.map +1 -0
- package/dist/ir/converters/expressions/calls/call-converter.d.ts +7 -17
- package/dist/ir/converters/expressions/calls/call-converter.d.ts.map +1 -1
- package/dist/ir/converters/expressions/calls/call-converter.js +7 -648
- package/dist/ir/converters/expressions/calls/call-converter.js.map +1 -1
- package/dist/ir/converters/expressions/calls/call-expression.d.ts +9 -0
- package/dist/ir/converters/expressions/calls/call-expression.d.ts.map +1 -0
- package/dist/ir/converters/expressions/calls/call-expression.js +9 -0
- package/dist/ir/converters/expressions/calls/call-expression.js.map +1 -0
- package/dist/ir/converters/expressions/calls/call-general.d.ts +25 -0
- package/dist/ir/converters/expressions/calls/call-general.d.ts.map +1 -0
- package/dist/ir/converters/expressions/calls/call-general.js +2237 -0
- package/dist/ir/converters/expressions/calls/call-general.js.map +1 -0
- package/dist/ir/converters/expressions/calls/call-intrinsics.d.ts +16 -0
- package/dist/ir/converters/expressions/calls/call-intrinsics.d.ts.map +1 -0
- package/dist/ir/converters/expressions/calls/call-intrinsics.js +308 -0
- package/dist/ir/converters/expressions/calls/call-intrinsics.js.map +1 -0
- package/dist/ir/converters/expressions/calls/call-resolution.d.ts +58 -0
- package/dist/ir/converters/expressions/calls/call-resolution.d.ts.map +1 -0
- package/dist/ir/converters/expressions/calls/call-resolution.js +293 -0
- package/dist/ir/converters/expressions/calls/call-resolution.js.map +1 -0
- package/dist/ir/converters/expressions/calls/call-site-analysis-argument-passing.d.ts +51 -0
- package/dist/ir/converters/expressions/calls/call-site-analysis-argument-passing.d.ts.map +1 -0
- package/dist/ir/converters/expressions/calls/call-site-analysis-argument-passing.js +313 -0
- package/dist/ir/converters/expressions/calls/call-site-analysis-argument-passing.js.map +1 -0
- package/dist/ir/converters/expressions/calls/call-site-analysis-unification.d.ts +13 -0
- package/dist/ir/converters/expressions/calls/call-site-analysis-unification.d.ts.map +1 -0
- package/dist/ir/converters/expressions/calls/call-site-analysis-unification.js +251 -0
- package/dist/ir/converters/expressions/calls/call-site-analysis-unification.js.map +1 -0
- package/dist/ir/converters/expressions/calls/call-site-analysis-unification.test.d.ts +2 -0
- package/dist/ir/converters/expressions/calls/call-site-analysis-unification.test.d.ts.map +1 -0
- package/dist/ir/converters/expressions/calls/call-site-analysis-unification.test.js +18 -0
- package/dist/ir/converters/expressions/calls/call-site-analysis-unification.test.js.map +1 -0
- package/dist/ir/converters/expressions/calls/call-site-analysis.d.ts +12 -51
- package/dist/ir/converters/expressions/calls/call-site-analysis.d.ts.map +1 -1
- package/dist/ir/converters/expressions/calls/call-site-analysis.js +9 -526
- package/dist/ir/converters/expressions/calls/call-site-analysis.js.map +1 -1
- package/dist/ir/converters/expressions/calls/invocation-finalization.d.ts +56 -0
- package/dist/ir/converters/expressions/calls/invocation-finalization.d.ts.map +1 -0
- package/dist/ir/converters/expressions/calls/invocation-finalization.js +723 -0
- package/dist/ir/converters/expressions/calls/invocation-finalization.js.map +1 -0
- package/dist/ir/converters/expressions/calls/new-converter.d.ts.map +1 -1
- package/dist/ir/converters/expressions/calls/new-converter.js +78 -3
- package/dist/ir/converters/expressions/calls/new-converter.js.map +1 -1
- package/dist/ir/converters/expressions/calls/source-backed-constructor-metadata.d.ts +22 -0
- package/dist/ir/converters/expressions/calls/source-backed-constructor-metadata.d.ts.map +1 -0
- package/dist/ir/converters/expressions/calls/source-backed-constructor-metadata.js +257 -0
- package/dist/ir/converters/expressions/calls/source-backed-constructor-metadata.js.map +1 -0
- package/dist/ir/converters/expressions/collections.d.ts +5 -25
- package/dist/ir/converters/expressions/collections.d.ts.map +1 -1
- package/dist/ir/converters/expressions/collections.js +5 -886
- package/dist/ir/converters/expressions/collections.js.map +1 -1
- package/dist/ir/converters/expressions/functions.d.ts.map +1 -1
- package/dist/ir/converters/expressions/functions.js +80 -65
- package/dist/ir/converters/expressions/functions.js.map +1 -1
- package/dist/ir/converters/expressions/helpers.js +1 -1
- package/dist/ir/converters/expressions/helpers.js.map +1 -1
- package/dist/ir/converters/expressions/import-meta.d.ts +3 -3
- package/dist/ir/converters/expressions/import-meta.d.ts.map +1 -1
- package/dist/ir/converters/expressions/import-meta.js +22 -8
- package/dist/ir/converters/expressions/import-meta.js.map +1 -1
- package/dist/ir/converters/expressions/literals.d.ts.map +1 -1
- package/dist/ir/converters/expressions/literals.js +31 -6
- package/dist/ir/converters/expressions/literals.js.map +1 -1
- package/dist/ir/converters/expressions/numeric-recovery-cases/call-return-and-intent.test.d.ts +9 -0
- package/dist/ir/converters/expressions/numeric-recovery-cases/call-return-and-intent.test.d.ts.map +1 -0
- package/dist/ir/converters/expressions/numeric-recovery-cases/call-return-and-intent.test.js +124 -0
- package/dist/ir/converters/expressions/numeric-recovery-cases/call-return-and-intent.test.js.map +1 -0
- package/dist/ir/converters/expressions/numeric-recovery-cases/e2e-integration.test.d.ts +8 -0
- package/dist/ir/converters/expressions/numeric-recovery-cases/e2e-integration.test.d.ts.map +1 -0
- package/dist/ir/converters/expressions/numeric-recovery-cases/e2e-integration.test.js +117 -0
- package/dist/ir/converters/expressions/numeric-recovery-cases/e2e-integration.test.js.map +1 -0
- package/dist/ir/converters/expressions/numeric-recovery-cases/property-access-recovery.test.d.ts +8 -0
- package/dist/ir/converters/expressions/numeric-recovery-cases/property-access-recovery.test.d.ts.map +1 -0
- package/dist/ir/converters/expressions/numeric-recovery-cases/property-access-recovery.test.js +170 -0
- package/dist/ir/converters/expressions/numeric-recovery-cases/property-access-recovery.test.js.map +1 -0
- package/dist/ir/converters/expressions/numeric-recovery-cases/test-helpers.d.ts +31 -0
- package/dist/ir/converters/expressions/numeric-recovery-cases/test-helpers.d.ts.map +1 -0
- package/dist/ir/converters/expressions/numeric-recovery-cases/test-helpers.js +183 -0
- package/dist/ir/converters/expressions/numeric-recovery-cases/test-helpers.js.map +1 -0
- package/dist/ir/converters/expressions/numeric-recovery.test.d.ts +3 -16
- package/dist/ir/converters/expressions/numeric-recovery.test.d.ts.map +1 -1
- package/dist/ir/converters/expressions/numeric-recovery.test.js +3 -407
- package/dist/ir/converters/expressions/numeric-recovery.test.js.map +1 -1
- package/dist/ir/converters/expressions/object-literal-helpers.d.ts +12 -0
- package/dist/ir/converters/expressions/object-literal-helpers.d.ts.map +1 -0
- package/dist/ir/converters/expressions/object-literal-helpers.js +12 -0
- package/dist/ir/converters/expressions/object-literal-helpers.js.map +1 -0
- package/dist/ir/converters/expressions/object-literal-synthesis.d.ts +27 -0
- package/dist/ir/converters/expressions/object-literal-synthesis.d.ts.map +1 -0
- package/dist/ir/converters/expressions/object-literal-synthesis.js +459 -0
- package/dist/ir/converters/expressions/object-literal-synthesis.js.map +1 -0
- package/dist/ir/converters/expressions/object-literal-type-helpers.d.ts +27 -0
- package/dist/ir/converters/expressions/object-literal-type-helpers.d.ts.map +1 -0
- package/dist/ir/converters/expressions/object-literal-type-helpers.js +267 -0
- package/dist/ir/converters/expressions/object-literal-type-helpers.js.map +1 -0
- package/dist/ir/converters/expressions/object-literals.d.ts +16 -0
- package/dist/ir/converters/expressions/object-literals.d.ts.map +1 -0
- package/dist/ir/converters/expressions/object-literals.js +317 -0
- package/dist/ir/converters/expressions/object-literals.js.map +1 -0
- package/dist/ir/converters/expressions/operators.d.ts.map +1 -1
- package/dist/ir/converters/expressions/operators.js +33 -19
- package/dist/ir/converters/expressions/operators.js.map +1 -1
- package/dist/ir/converters/expressions/other.d.ts +4 -2
- package/dist/ir/converters/expressions/other.d.ts.map +1 -1
- package/dist/ir/converters/expressions/other.js +32 -10
- package/dist/ir/converters/expressions/other.js.map +1 -1
- package/dist/ir/converters/flow-narrowing.d.ts +6 -25
- package/dist/ir/converters/flow-narrowing.d.ts.map +1 -1
- package/dist/ir/converters/flow-narrowing.js +5 -418
- package/dist/ir/converters/flow-narrowing.js.map +1 -1
- package/dist/ir/converters/heritage-reference-type.d.ts +5 -0
- package/dist/ir/converters/heritage-reference-type.d.ts.map +1 -0
- package/dist/ir/converters/heritage-reference-type.js +22 -0
- package/dist/ir/converters/heritage-reference-type.js.map +1 -0
- package/dist/ir/converters/narrowing-candidates.d.ts +7 -0
- package/dist/ir/converters/narrowing-candidates.d.ts.map +1 -0
- package/dist/ir/converters/narrowing-candidates.js +5 -0
- package/dist/ir/converters/narrowing-candidates.js.map +1 -0
- package/dist/ir/converters/narrowing-collection.d.ts +10 -0
- package/dist/ir/converters/narrowing-collection.d.ts.map +1 -0
- package/dist/ir/converters/narrowing-collection.js +10 -0
- package/dist/ir/converters/narrowing-collection.js.map +1 -0
- package/dist/ir/converters/narrowing-environment.d.ts +13 -0
- package/dist/ir/converters/narrowing-environment.d.ts.map +1 -0
- package/dist/ir/converters/narrowing-environment.js +83 -0
- package/dist/ir/converters/narrowing-environment.js.map +1 -0
- package/dist/ir/converters/narrowing-property-helpers.d.ts +8 -0
- package/dist/ir/converters/narrowing-property-helpers.d.ts.map +1 -0
- package/dist/ir/converters/narrowing-property-helpers.js +57 -0
- package/dist/ir/converters/narrowing-property-helpers.js.map +1 -0
- package/dist/ir/converters/narrowing-resolvers-equality.d.ts +22 -0
- package/dist/ir/converters/narrowing-resolvers-equality.d.ts.map +1 -0
- package/dist/ir/converters/narrowing-resolvers-equality.js +309 -0
- package/dist/ir/converters/narrowing-resolvers-equality.js.map +1 -0
- package/dist/ir/converters/narrowing-resolvers-equality.test.d.ts +2 -0
- package/dist/ir/converters/narrowing-resolvers-equality.test.d.ts.map +1 -0
- package/dist/ir/converters/narrowing-resolvers-equality.test.js +159 -0
- package/dist/ir/converters/narrowing-resolvers-equality.test.js.map +1 -0
- package/dist/ir/converters/narrowing-resolvers-typeof.d.ts +41 -0
- package/dist/ir/converters/narrowing-resolvers-typeof.d.ts.map +1 -0
- package/dist/ir/converters/narrowing-resolvers-typeof.js +251 -0
- package/dist/ir/converters/narrowing-resolvers-typeof.js.map +1 -0
- package/dist/ir/converters/narrowing-resolvers.d.ts +12 -0
- package/dist/ir/converters/narrowing-resolvers.d.ts.map +1 -0
- package/dist/ir/converters/narrowing-resolvers.js +10 -0
- package/dist/ir/converters/narrowing-resolvers.js.map +1 -0
- package/dist/ir/converters/narrowing-truthy.d.ts +19 -0
- package/dist/ir/converters/narrowing-truthy.d.ts.map +1 -0
- package/dist/ir/converters/narrowing-truthy.js +355 -0
- package/dist/ir/converters/narrowing-truthy.js.map +1 -0
- package/dist/ir/converters/reference-type-guards.d.ts +8 -0
- package/dist/ir/converters/reference-type-guards.d.ts.map +1 -0
- package/dist/ir/converters/reference-type-guards.js +51 -0
- package/dist/ir/converters/reference-type-guards.js.map +1 -0
- package/dist/ir/converters/reference-type-guards.test.d.ts +2 -0
- package/dist/ir/converters/reference-type-guards.test.d.ts.map +1 -0
- package/dist/ir/converters/reference-type-guards.test.js +51 -0
- package/dist/ir/converters/reference-type-guards.test.js.map +1 -0
- package/dist/ir/converters/return-expression-types.d.ts +3 -0
- package/dist/ir/converters/return-expression-types.d.ts.map +1 -0
- package/dist/ir/converters/return-expression-types.js +10 -0
- package/dist/ir/converters/return-expression-types.js.map +1 -0
- package/dist/ir/converters/statements/control/blocks.d.ts.map +1 -1
- package/dist/ir/converters/statements/control/blocks.js +72 -2
- package/dist/ir/converters/statements/control/blocks.js.map +1 -1
- package/dist/ir/converters/statements/control/conditionals.d.ts.map +1 -1
- package/dist/ir/converters/statements/control/conditionals.js +2 -12
- package/dist/ir/converters/statements/control/conditionals.js.map +1 -1
- package/dist/ir/converters/statements/control/loops.d.ts.map +1 -1
- package/dist/ir/converters/statements/control/loops.js +18 -4
- package/dist/ir/converters/statements/control/loops.js.map +1 -1
- package/dist/ir/converters/statements/declarations/classes/constructors.d.ts.map +1 -1
- package/dist/ir/converters/statements/declarations/classes/constructors.js +36 -19
- package/dist/ir/converters/statements/declarations/classes/constructors.js.map +1 -1
- package/dist/ir/converters/statements/declarations/classes/member-names.d.ts +5 -0
- package/dist/ir/converters/statements/declarations/classes/member-names.d.ts.map +1 -0
- package/dist/ir/converters/statements/declarations/classes/member-names.js +6 -0
- package/dist/ir/converters/statements/declarations/classes/member-names.js.map +1 -0
- package/dist/ir/converters/statements/declarations/classes/method-declaration.d.ts +11 -0
- package/dist/ir/converters/statements/declarations/classes/method-declaration.d.ts.map +1 -0
- package/dist/ir/converters/statements/declarations/classes/method-declaration.js +54 -0
- package/dist/ir/converters/statements/declarations/classes/method-declaration.js.map +1 -0
- package/dist/ir/converters/statements/declarations/classes/methods.d.ts +2 -15
- package/dist/ir/converters/statements/declarations/classes/methods.d.ts.map +1 -1
- package/dist/ir/converters/statements/declarations/classes/methods.js +2 -810
- package/dist/ir/converters/statements/declarations/classes/methods.js.map +1 -1
- package/dist/ir/converters/statements/declarations/classes/orchestrator.d.ts.map +1 -1
- package/dist/ir/converters/statements/declarations/classes/orchestrator.js +15 -41
- package/dist/ir/converters/statements/declarations/classes/orchestrator.js.map +1 -1
- package/dist/ir/converters/statements/declarations/classes/override-detection.d.ts +4 -1
- package/dist/ir/converters/statements/declarations/classes/override-detection.d.ts.map +1 -1
- package/dist/ir/converters/statements/declarations/classes/override-detection.js +18 -10
- package/dist/ir/converters/statements/declarations/classes/override-detection.js.map +1 -1
- package/dist/ir/converters/statements/declarations/classes/properties.d.ts.map +1 -1
- package/dist/ir/converters/statements/declarations/classes/properties.js +10 -3
- package/dist/ir/converters/statements/declarations/classes/properties.js.map +1 -1
- package/dist/ir/converters/statements/declarations/functions.d.ts.map +1 -1
- package/dist/ir/converters/statements/declarations/functions.js +8 -2
- package/dist/ir/converters/statements/declarations/functions.js.map +1 -1
- package/dist/ir/converters/statements/declarations/interfaces.d.ts.map +1 -1
- package/dist/ir/converters/statements/declarations/interfaces.js +67 -2
- package/dist/ir/converters/statements/declarations/interfaces.js.map +1 -1
- package/dist/ir/converters/statements/declarations/overload-family-builders.d.ts +9 -0
- package/dist/ir/converters/statements/declarations/overload-family-builders.d.ts.map +1 -0
- package/dist/ir/converters/statements/declarations/overload-family-builders.js +21 -0
- package/dist/ir/converters/statements/declarations/overload-family-builders.js.map +1 -0
- package/dist/ir/converters/statements/declarations/type-aliases.d.ts.map +1 -1
- package/dist/ir/converters/statements/declarations/type-aliases.js +12 -1
- package/dist/ir/converters/statements/declarations/type-aliases.js.map +1 -1
- package/dist/ir/converters/statements/declarations/variable-generic-lowering.d.ts +50 -0
- package/dist/ir/converters/statements/declarations/variable-generic-lowering.d.ts.map +1 -0
- package/dist/ir/converters/statements/declarations/variable-generic-lowering.js +281 -0
- package/dist/ir/converters/statements/declarations/variable-generic-lowering.js.map +1 -0
- package/dist/ir/converters/statements/declarations/variable-helpers.d.ts +29 -0
- package/dist/ir/converters/statements/declarations/variable-helpers.d.ts.map +1 -0
- package/dist/ir/converters/statements/declarations/variable-helpers.js +58 -0
- package/dist/ir/converters/statements/declarations/variable-helpers.js.map +1 -0
- package/dist/ir/converters/statements/declarations/variables-generic-function-values.d.ts +21 -0
- package/dist/ir/converters/statements/declarations/variables-generic-function-values.d.ts.map +1 -0
- package/dist/ir/converters/statements/declarations/variables-generic-function-values.js +263 -0
- package/dist/ir/converters/statements/declarations/variables-generic-function-values.js.map +1 -0
- package/dist/ir/converters/statements/declarations/variables.d.ts.map +1 -1
- package/dist/ir/converters/statements/declarations/variables.js +3 -262
- package/dist/ir/converters/statements/declarations/variables.js.map +1 -1
- package/dist/ir/converters/synthetic-types.d.ts.map +1 -1
- package/dist/ir/converters/synthetic-types.js +83 -4
- package/dist/ir/converters/synthetic-types.js.map +1 -1
- package/dist/ir/converters/type-env.d.ts +3 -1
- package/dist/ir/converters/type-env.d.ts.map +1 -1
- package/dist/ir/converters/type-env.js +52 -19
- package/dist/ir/converters/type-env.js.map +1 -1
- package/dist/ir/expression-converter-dispatch.d.ts +21 -0
- package/dist/ir/expression-converter-dispatch.d.ts.map +1 -0
- package/dist/ir/expression-converter-dispatch.js +550 -0
- package/dist/ir/expression-converter-dispatch.js.map +1 -0
- package/dist/ir/expression-converter-helpers.d.ts +27 -0
- package/dist/ir/expression-converter-helpers.d.ts.map +1 -0
- package/dist/ir/expression-converter-helpers.js +172 -0
- package/dist/ir/expression-converter-helpers.js.map +1 -0
- package/dist/ir/expression-converter.d.ts +5 -15
- package/dist/ir/expression-converter.d.ts.map +1 -1
- package/dist/ir/expression-converter.js +5 -410
- package/dist/ir/expression-converter.js.map +1 -1
- package/dist/ir/field-marker.test.js +1 -1
- package/dist/ir/field-marker.test.js.map +1 -1
- package/dist/ir/json-global-typing.test.d.ts +2 -0
- package/dist/ir/json-global-typing.test.d.ts.map +1 -0
- package/dist/ir/json-global-typing.test.js +80 -0
- package/dist/ir/json-global-typing.test.js.map +1 -0
- package/dist/ir/program-context-factory.d.ts +25 -0
- package/dist/ir/program-context-factory.d.ts.map +1 -0
- package/dist/ir/program-context-factory.js +196 -0
- package/dist/ir/program-context-factory.js.map +1 -0
- package/dist/ir/program-context-types.d.ts +147 -0
- package/dist/ir/program-context-types.d.ts.map +1 -0
- package/dist/ir/program-context-types.js +123 -0
- package/dist/ir/program-context-types.js.map +1 -0
- package/dist/ir/program-context.d.ts +6 -122
- package/dist/ir/program-context.d.ts.map +1 -1
- package/dist/ir/program-context.js +5 -347
- package/dist/ir/program-context.js.map +1 -1
- package/dist/ir/program-context.test.js +20 -0
- package/dist/ir/program-context.test.js.map +1 -1
- package/dist/ir/syntax/overload-stubs.d.ts +4 -0
- package/dist/ir/syntax/overload-stubs.d.ts.map +1 -0
- package/dist/ir/syntax/overload-stubs.js +32 -0
- package/dist/ir/syntax/overload-stubs.js.map +1 -0
- package/dist/ir/syntax/property-names.d.ts +6 -0
- package/dist/ir/syntax/property-names.d.ts.map +1 -0
- package/dist/ir/syntax/property-names.js +116 -0
- package/dist/ir/syntax/property-names.js.map +1 -0
- package/dist/ir/type-system/call-resolution-callable-types.d.ts +10 -0
- package/dist/ir/type-system/call-resolution-callable-types.d.ts.map +1 -0
- package/dist/ir/type-system/call-resolution-callable-types.js +288 -0
- package/dist/ir/type-system/call-resolution-callable-types.js.map +1 -0
- package/dist/ir/type-system/call-resolution-candidate-selection.d.ts +9 -0
- package/dist/ir/type-system/call-resolution-candidate-selection.d.ts.map +1 -0
- package/dist/ir/type-system/call-resolution-candidate-selection.js +413 -0
- package/dist/ir/type-system/call-resolution-candidate-selection.js.map +1 -0
- package/dist/ir/type-system/call-resolution-inference.d.ts +12 -0
- package/dist/ir/type-system/call-resolution-inference.d.ts.map +1 -0
- package/dist/ir/type-system/call-resolution-inference.js +12 -0
- package/dist/ir/type-system/call-resolution-inference.js.map +1 -0
- package/dist/ir/type-system/call-resolution-method-substitution.d.ts +12 -0
- package/dist/ir/type-system/call-resolution-method-substitution.d.ts.map +1 -0
- package/dist/ir/type-system/call-resolution-method-substitution.js +115 -0
- package/dist/ir/type-system/call-resolution-method-substitution.js.map +1 -0
- package/dist/ir/type-system/call-resolution-parameters.d.ts +30 -0
- package/dist/ir/type-system/call-resolution-parameters.d.ts.map +1 -0
- package/dist/ir/type-system/call-resolution-parameters.js +167 -0
- package/dist/ir/type-system/call-resolution-parameters.js.map +1 -0
- package/dist/ir/type-system/call-resolution-receiver-substitution.d.ts +12 -0
- package/dist/ir/type-system/call-resolution-receiver-substitution.d.ts.map +1 -0
- package/dist/ir/type-system/call-resolution-receiver-substitution.js +134 -0
- package/dist/ir/type-system/call-resolution-receiver-substitution.js.map +1 -0
- package/dist/ir/type-system/call-resolution-resolve.d.ts +12 -0
- package/dist/ir/type-system/call-resolution-resolve.d.ts.map +1 -0
- package/dist/ir/type-system/call-resolution-resolve.js +275 -0
- package/dist/ir/type-system/call-resolution-resolve.js.map +1 -0
- package/dist/ir/type-system/call-resolution-scoring.d.ts +18 -0
- package/dist/ir/type-system/call-resolution-scoring.d.ts.map +1 -0
- package/dist/ir/type-system/call-resolution-scoring.js +166 -0
- package/dist/ir/type-system/call-resolution-scoring.js.map +1 -0
- package/dist/ir/type-system/call-resolution-signatures-catalog.d.ts +19 -0
- package/dist/ir/type-system/call-resolution-signatures-catalog.d.ts.map +1 -0
- package/dist/ir/type-system/call-resolution-signatures-catalog.js +121 -0
- package/dist/ir/type-system/call-resolution-signatures-catalog.js.map +1 -0
- package/dist/ir/type-system/call-resolution-signatures-catalog.test.d.ts +2 -0
- package/dist/ir/type-system/call-resolution-signatures-catalog.test.d.ts.map +1 -0
- package/dist/ir/type-system/call-resolution-signatures-catalog.test.js +88 -0
- package/dist/ir/type-system/call-resolution-signatures-catalog.test.js.map +1 -0
- package/dist/ir/type-system/call-resolution-signatures-raw.d.ts +21 -0
- package/dist/ir/type-system/call-resolution-signatures-raw.d.ts.map +1 -0
- package/dist/ir/type-system/call-resolution-signatures-raw.js +242 -0
- package/dist/ir/type-system/call-resolution-signatures-raw.js.map +1 -0
- package/dist/ir/type-system/call-resolution-signatures.d.ts +10 -0
- package/dist/ir/type-system/call-resolution-signatures.d.ts.map +1 -0
- package/dist/ir/type-system/call-resolution-signatures.js +10 -0
- package/dist/ir/type-system/call-resolution-signatures.js.map +1 -0
- package/dist/ir/type-system/call-resolution-type-ids.d.ts +43 -0
- package/dist/ir/type-system/call-resolution-type-ids.d.ts.map +1 -0
- package/dist/ir/type-system/call-resolution-type-ids.js +465 -0
- package/dist/ir/type-system/call-resolution-type-ids.js.map +1 -0
- package/dist/ir/type-system/call-resolution-type-ids.test.d.ts +2 -0
- package/dist/ir/type-system/call-resolution-type-ids.test.d.ts.map +1 -0
- package/dist/ir/type-system/call-resolution-type-ids.test.js +63 -0
- package/dist/ir/type-system/call-resolution-type-ids.test.js.map +1 -0
- package/dist/ir/type-system/call-resolution-unification.d.ts +18 -0
- package/dist/ir/type-system/call-resolution-unification.d.ts.map +1 -0
- package/dist/ir/type-system/call-resolution-unification.js +637 -0
- package/dist/ir/type-system/call-resolution-unification.js.map +1 -0
- package/dist/ir/type-system/call-resolution-utilities.d.ts +11 -0
- package/dist/ir/type-system/call-resolution-utilities.d.ts.map +1 -0
- package/dist/ir/type-system/call-resolution-utilities.js +11 -0
- package/dist/ir/type-system/call-resolution-utilities.js.map +1 -0
- package/dist/ir/type-system/inference-declarations-overrides.d.ts +33 -0
- package/dist/ir/type-system/inference-declarations-overrides.d.ts.map +1 -0
- package/dist/ir/type-system/inference-declarations-overrides.js +241 -0
- package/dist/ir/type-system/inference-declarations-overrides.js.map +1 -0
- package/dist/ir/type-system/inference-declarations-types.d.ts +20 -0
- package/dist/ir/type-system/inference-declarations-types.d.ts.map +1 -0
- package/dist/ir/type-system/inference-declarations-types.js +475 -0
- package/dist/ir/type-system/inference-declarations-types.js.map +1 -0
- package/dist/ir/type-system/inference-declarations.d.ts +10 -0
- package/dist/ir/type-system/inference-declarations.d.ts.map +1 -0
- package/dist/ir/type-system/inference-declarations.js +10 -0
- package/dist/ir/type-system/inference-declarations.js.map +1 -0
- package/dist/ir/type-system/inference-expressions-infer.d.ts +25 -0
- package/dist/ir/type-system/inference-expressions-infer.d.ts.map +1 -0
- package/dist/ir/type-system/inference-expressions-infer.js +427 -0
- package/dist/ir/type-system/inference-expressions-infer.js.map +1 -0
- package/dist/ir/type-system/inference-expressions-lambda.d.ts +13 -0
- package/dist/ir/type-system/inference-expressions-lambda.d.ts.map +1 -0
- package/dist/ir/type-system/inference-expressions-lambda.js +101 -0
- package/dist/ir/type-system/inference-expressions-lambda.js.map +1 -0
- package/dist/ir/type-system/inference-expressions.d.ts +10 -0
- package/dist/ir/type-system/inference-expressions.d.ts.map +1 -0
- package/dist/ir/type-system/inference-expressions.js +10 -0
- package/dist/ir/type-system/inference-expressions.js.map +1 -0
- package/dist/ir/type-system/inference-initializers-call.d.ts +37 -0
- package/dist/ir/type-system/inference-initializers-call.d.ts.map +1 -0
- package/dist/ir/type-system/inference-initializers-call.js +242 -0
- package/dist/ir/type-system/inference-initializers-call.js.map +1 -0
- package/dist/ir/type-system/inference-initializers-variable.d.ts +14 -0
- package/dist/ir/type-system/inference-initializers-variable.d.ts.map +1 -0
- package/dist/ir/type-system/inference-initializers-variable.js +178 -0
- package/dist/ir/type-system/inference-initializers-variable.js.map +1 -0
- package/dist/ir/type-system/inference-initializers.d.ts +10 -0
- package/dist/ir/type-system/inference-initializers.d.ts.map +1 -0
- package/dist/ir/type-system/inference-initializers.js +10 -0
- package/dist/ir/type-system/inference-initializers.js.map +1 -0
- package/dist/ir/type-system/inference-member-id.d.ts +21 -0
- package/dist/ir/type-system/inference-member-id.d.ts.map +1 -0
- package/dist/ir/type-system/inference-member-id.js +402 -0
- package/dist/ir/type-system/inference-member-id.js.map +1 -0
- package/dist/ir/type-system/inference-member-lookup.d.ts +15 -0
- package/dist/ir/type-system/inference-member-lookup.d.ts.map +1 -0
- package/dist/ir/type-system/inference-member-lookup.js +567 -0
- package/dist/ir/type-system/inference-member-lookup.js.map +1 -0
- package/dist/ir/type-system/inference-member-resolution.d.ts +10 -0
- package/dist/ir/type-system/inference-member-resolution.d.ts.map +1 -0
- package/dist/ir/type-system/inference-member-resolution.js +10 -0
- package/dist/ir/type-system/inference-member-resolution.js.map +1 -0
- package/dist/ir/type-system/inference-type-preference.d.ts +9 -0
- package/dist/ir/type-system/inference-type-preference.d.ts.map +1 -0
- package/dist/ir/type-system/inference-type-preference.js +67 -0
- package/dist/ir/type-system/inference-type-preference.js.map +1 -0
- package/dist/ir/type-system/inference-utilities.d.ts +48 -0
- package/dist/ir/type-system/inference-utilities.d.ts.map +1 -0
- package/dist/ir/type-system/inference-utilities.js +182 -0
- package/dist/ir/type-system/inference-utilities.js.map +1 -0
- package/dist/ir/type-system/internal/handle-types.d.ts +12 -0
- package/dist/ir/type-system/internal/handle-types.d.ts.map +1 -1
- package/dist/ir/type-system/internal/nominal-env.d.ts +1 -1
- package/dist/ir/type-system/internal/nominal-env.d.ts.map +1 -1
- package/dist/ir/type-system/internal/nominal-env.js +12 -114
- package/dist/ir/type-system/internal/nominal-env.js.map +1 -1
- package/dist/ir/type-system/internal/registry-builder.d.ts +19 -0
- package/dist/ir/type-system/internal/registry-builder.d.ts.map +1 -0
- package/dist/ir/type-system/internal/registry-builder.js +292 -0
- package/dist/ir/type-system/internal/registry-builder.js.map +1 -0
- package/dist/ir/type-system/internal/registry-helpers-extraction.d.ts +69 -0
- package/dist/ir/type-system/internal/registry-helpers-extraction.d.ts.map +1 -0
- package/dist/ir/type-system/internal/registry-helpers-extraction.js +429 -0
- package/dist/ir/type-system/internal/registry-helpers-extraction.js.map +1 -0
- package/dist/ir/type-system/internal/registry-helpers-inference.d.ts +19 -0
- package/dist/ir/type-system/internal/registry-helpers-inference.d.ts.map +1 -0
- package/dist/ir/type-system/internal/registry-helpers-inference.js +237 -0
- package/dist/ir/type-system/internal/registry-helpers-inference.js.map +1 -0
- package/dist/ir/type-system/internal/registry-helpers.d.ts +12 -0
- package/dist/ir/type-system/internal/registry-helpers.d.ts.map +1 -0
- package/dist/ir/type-system/internal/registry-helpers.js +12 -0
- package/dist/ir/type-system/internal/registry-helpers.js.map +1 -0
- package/dist/ir/type-system/internal/type-converter/conditional-utility-types-core.d.ts +53 -0
- package/dist/ir/type-system/internal/type-converter/conditional-utility-types-core.d.ts.map +1 -0
- package/dist/ir/type-system/internal/type-converter/conditional-utility-types-core.js +281 -0
- package/dist/ir/type-system/internal/type-converter/conditional-utility-types-core.js.map +1 -0
- package/dist/ir/type-system/internal/type-converter/conditional-utility-types-extract.d.ts +35 -0
- package/dist/ir/type-system/internal/type-converter/conditional-utility-types-extract.d.ts.map +1 -0
- package/dist/ir/type-system/internal/type-converter/conditional-utility-types-extract.js +308 -0
- package/dist/ir/type-system/internal/type-converter/conditional-utility-types-extract.js.map +1 -0
- package/dist/ir/type-system/internal/type-converter/conditional-utility-types.d.ts +23 -0
- package/dist/ir/type-system/internal/type-converter/conditional-utility-types.d.ts.map +1 -0
- package/dist/ir/type-system/internal/type-converter/conditional-utility-types.js +23 -0
- package/dist/ir/type-system/internal/type-converter/conditional-utility-types.js.map +1 -0
- package/dist/ir/type-system/internal/type-converter/direct-alias-expansion.d.ts +5 -0
- package/dist/ir/type-system/internal/type-converter/direct-alias-expansion.d.ts.map +1 -0
- package/dist/ir/type-system/internal/type-converter/direct-alias-expansion.js +232 -0
- package/dist/ir/type-system/internal/type-converter/direct-alias-expansion.js.map +1 -0
- package/dist/ir/type-system/internal/type-converter/functions.d.ts.map +1 -1
- package/dist/ir/type-system/internal/type-converter/functions.js +21 -0
- package/dist/ir/type-system/internal/type-converter/functions.js.map +1 -1
- package/dist/ir/type-system/internal/type-converter/mapped-utility-expansion.d.ts +37 -0
- package/dist/ir/type-system/internal/type-converter/mapped-utility-expansion.d.ts.map +1 -0
- package/dist/ir/type-system/internal/type-converter/mapped-utility-expansion.js +334 -0
- package/dist/ir/type-system/internal/type-converter/mapped-utility-expansion.js.map +1 -0
- package/dist/ir/type-system/internal/type-converter/mapped-utility-record.d.ts +27 -0
- package/dist/ir/type-system/internal/type-converter/mapped-utility-record.d.ts.map +1 -0
- package/dist/ir/type-system/internal/type-converter/mapped-utility-record.js +174 -0
- package/dist/ir/type-system/internal/type-converter/mapped-utility-record.js.map +1 -0
- package/dist/ir/type-system/internal/type-converter/mapped-utility-types.d.ts +10 -0
- package/dist/ir/type-system/internal/type-converter/mapped-utility-types.d.ts.map +1 -0
- package/dist/ir/type-system/internal/type-converter/mapped-utility-types.js +10 -0
- package/dist/ir/type-system/internal/type-converter/mapped-utility-types.js.map +1 -0
- package/dist/ir/type-system/internal/type-converter/objects.d.ts.map +1 -1
- package/dist/ir/type-system/internal/type-converter/objects.js +11 -6
- package/dist/ir/type-system/internal/type-converter/objects.js.map +1 -1
- package/dist/ir/type-system/internal/type-converter/orchestrator.d.ts +6 -5
- package/dist/ir/type-system/internal/type-converter/orchestrator.d.ts.map +1 -1
- package/dist/ir/type-system/internal/type-converter/orchestrator.js +80 -463
- package/dist/ir/type-system/internal/type-converter/orchestrator.js.map +1 -1
- package/dist/ir/type-system/internal/type-converter/orchestrator.test.js +47 -57
- package/dist/ir/type-system/internal/type-converter/orchestrator.test.js.map +1 -1
- package/dist/ir/type-system/internal/type-converter/primitives.d.ts.map +1 -1
- package/dist/ir/type-system/internal/type-converter/primitives.js +9 -1
- package/dist/ir/type-system/internal/type-converter/primitives.js.map +1 -1
- package/dist/ir/type-system/internal/type-converter/references-alias.d.ts +21 -0
- package/dist/ir/type-system/internal/type-converter/references-alias.d.ts.map +1 -0
- package/dist/ir/type-system/internal/type-converter/references-alias.js +267 -0
- package/dist/ir/type-system/internal/type-converter/references-alias.js.map +1 -0
- package/dist/ir/type-system/internal/type-converter/references-converter.d.ts +16 -0
- package/dist/ir/type-system/internal/type-converter/references-converter.d.ts.map +1 -0
- package/dist/ir/type-system/internal/type-converter/references-converter.js +203 -0
- package/dist/ir/type-system/internal/type-converter/references-converter.js.map +1 -0
- package/dist/ir/type-system/internal/type-converter/references-normalize.d.ts +49 -0
- package/dist/ir/type-system/internal/type-converter/references-normalize.d.ts.map +1 -0
- package/dist/ir/type-system/internal/type-converter/references-normalize.js +162 -0
- package/dist/ir/type-system/internal/type-converter/references-normalize.js.map +1 -0
- package/dist/ir/type-system/internal/type-converter/references-structural-bindings.d.ts +52 -0
- package/dist/ir/type-system/internal/type-converter/references-structural-bindings.d.ts.map +1 -0
- package/dist/ir/type-system/internal/type-converter/references-structural-bindings.js +295 -0
- package/dist/ir/type-system/internal/type-converter/references-structural-bindings.js.map +1 -0
- package/dist/ir/type-system/internal/type-converter/references-structural-members.d.ts +55 -0
- package/dist/ir/type-system/internal/type-converter/references-structural-members.d.ts.map +1 -0
- package/dist/ir/type-system/internal/type-converter/references-structural-members.js +334 -0
- package/dist/ir/type-system/internal/type-converter/references-structural-members.js.map +1 -0
- package/dist/ir/type-system/internal/type-converter/references-structural.d.ts +12 -0
- package/dist/ir/type-system/internal/type-converter/references-structural.d.ts.map +1 -0
- package/dist/ir/type-system/internal/type-converter/references-structural.js +12 -0
- package/dist/ir/type-system/internal/type-converter/references-structural.js.map +1 -0
- package/dist/ir/type-system/internal/type-converter/references.d.ts +8 -9
- package/dist/ir/type-system/internal/type-converter/references.d.ts.map +1 -1
- package/dist/ir/type-system/internal/type-converter/references.js +7 -981
- package/dist/ir/type-system/internal/type-converter/references.js.map +1 -1
- package/dist/ir/type-system/internal/type-converter/type-operators.d.ts +16 -0
- package/dist/ir/type-system/internal/type-converter/type-operators.d.ts.map +1 -0
- package/dist/ir/type-system/internal/type-converter/type-operators.js +197 -0
- package/dist/ir/type-system/internal/type-converter/type-operators.js.map +1 -0
- package/dist/ir/type-system/internal/type-converter/unions-intersections.d.ts.map +1 -1
- package/dist/ir/type-system/internal/type-converter/unions-intersections.js +2 -4
- package/dist/ir/type-system/internal/type-converter/unions-intersections.js.map +1 -1
- package/dist/ir/type-system/internal/type-converter/utility-types-cases/comprehensive-expansion.test.d.ts +2 -0
- package/dist/ir/type-system/internal/type-converter/utility-types-cases/comprehensive-expansion.test.d.ts.map +1 -0
- package/dist/ir/type-system/internal/type-converter/utility-types-cases/comprehensive-expansion.test.js +246 -0
- package/dist/ir/type-system/internal/type-converter/utility-types-cases/comprehensive-expansion.test.js.map +1 -0
- package/dist/ir/type-system/internal/type-converter/utility-types-cases/conditional-awaited-constructor-instance.test.d.ts +2 -0
- package/dist/ir/type-system/internal/type-converter/utility-types-cases/conditional-awaited-constructor-instance.test.d.ts.map +1 -0
- package/dist/ir/type-system/internal/type-converter/utility-types-cases/conditional-awaited-constructor-instance.test.js +179 -0
- package/dist/ir/type-system/internal/type-converter/utility-types-cases/conditional-awaited-constructor-instance.test.js.map +1 -0
- package/dist/ir/type-system/internal/type-converter/utility-types-cases/conditional-nonnullable-exclude-extract.test.d.ts +2 -0
- package/dist/ir/type-system/internal/type-converter/utility-types-cases/conditional-nonnullable-exclude-extract.test.d.ts.map +1 -0
- package/dist/ir/type-system/internal/type-converter/utility-types-cases/conditional-nonnullable-exclude-extract.test.js +277 -0
- package/dist/ir/type-system/internal/type-converter/utility-types-cases/conditional-nonnullable-exclude-extract.test.js.map +1 -0
- package/dist/ir/type-system/internal/type-converter/utility-types-cases/conditional-return-params.test.d.ts +2 -0
- package/dist/ir/type-system/internal/type-converter/utility-types-cases/conditional-return-params.test.d.ts.map +1 -0
- package/dist/ir/type-system/internal/type-converter/utility-types-cases/conditional-return-params.test.js +163 -0
- package/dist/ir/type-system/internal/type-converter/utility-types-cases/conditional-return-params.test.js.map +1 -0
- package/dist/ir/type-system/internal/type-converter/utility-types-cases/expansion-safety.test.d.ts +2 -0
- package/dist/ir/type-system/internal/type-converter/utility-types-cases/expansion-safety.test.d.ts.map +1 -0
- package/dist/ir/type-system/internal/type-converter/utility-types-cases/expansion-safety.test.js +305 -0
- package/dist/ir/type-system/internal/type-converter/utility-types-cases/expansion-safety.test.js.map +1 -0
- package/dist/ir/type-system/internal/type-converter/utility-types-cases/helpers.d.ts +38 -0
- package/dist/ir/type-system/internal/type-converter/utility-types-cases/helpers.d.ts.map +1 -0
- package/dist/ir/type-system/internal/type-converter/utility-types-cases/helpers.js +127 -0
- package/dist/ir/type-system/internal/type-converter/utility-types-cases/helpers.js.map +1 -0
- package/dist/ir/type-system/internal/type-converter/utility-types-cases/record-expansion.test.d.ts +2 -0
- package/dist/ir/type-system/internal/type-converter/utility-types-cases/record-expansion.test.d.ts.map +1 -0
- package/dist/ir/type-system/internal/type-converter/utility-types-cases/record-expansion.test.js +145 -0
- package/dist/ir/type-system/internal/type-converter/utility-types-cases/record-expansion.test.js.map +1 -0
- package/dist/ir/type-system/internal/type-converter/utility-types.d.ts +6 -76
- package/dist/ir/type-system/internal/type-converter/utility-types.d.ts.map +1 -1
- package/dist/ir/type-system/internal/type-converter/utility-types.js +6 -1031
- package/dist/ir/type-system/internal/type-converter/utility-types.js.map +1 -1
- package/dist/ir/type-system/internal/type-converter/utility-types.test.d.ts +6 -9
- package/dist/ir/type-system/internal/type-converter/utility-types.test.d.ts.map +1 -1
- package/dist/ir/type-system/internal/type-converter/utility-types.test.js +6 -1416
- package/dist/ir/type-system/internal/type-converter/utility-types.test.js.map +1 -1
- package/dist/ir/type-system/internal/type-converter/value-inference.d.ts +13 -0
- package/dist/ir/type-system/internal/type-converter/value-inference.d.ts.map +1 -0
- package/dist/ir/type-system/internal/type-converter/value-inference.js +311 -0
- package/dist/ir/type-system/internal/type-converter/value-inference.js.map +1 -0
- package/dist/ir/type-system/internal/type-registry.d.ts +12 -12
- package/dist/ir/type-system/internal/type-registry.d.ts.map +1 -1
- package/dist/ir/type-system/internal/type-registry.js +4 -529
- package/dist/ir/type-system/internal/type-registry.js.map +1 -1
- package/dist/ir/type-system/internal/universe/catalog-types.d.ts +260 -0
- package/dist/ir/type-system/internal/universe/catalog-types.d.ts.map +1 -0
- package/dist/ir/type-system/internal/universe/catalog-types.js +12 -0
- package/dist/ir/type-system/internal/universe/catalog-types.js.map +1 -0
- package/dist/ir/type-system/internal/universe/clr-catalog.d.ts +7 -5
- package/dist/ir/type-system/internal/universe/clr-catalog.d.ts.map +1 -1
- package/dist/ir/type-system/internal/universe/clr-catalog.js +160 -90
- package/dist/ir/type-system/internal/universe/clr-catalog.js.map +1 -1
- package/dist/ir/type-system/internal/universe/clr-catalog.test.js +166 -72
- package/dist/ir/type-system/internal/universe/clr-catalog.test.js.map +1 -1
- package/dist/ir/type-system/internal/universe/clr-entry-converter.d.ts +7 -47
- package/dist/ir/type-system/internal/universe/clr-entry-converter.d.ts.map +1 -1
- package/dist/ir/type-system/internal/universe/clr-entry-converter.js +6 -695
- package/dist/ir/type-system/internal/universe/clr-entry-converter.js.map +1 -1
- package/dist/ir/type-system/internal/universe/clr-heritage-enrichment.d.ts +10 -0
- package/dist/ir/type-system/internal/universe/clr-heritage-enrichment.d.ts.map +1 -0
- package/dist/ir/type-system/internal/universe/clr-heritage-enrichment.js +168 -0
- package/dist/ir/type-system/internal/universe/clr-heritage-enrichment.js.map +1 -0
- package/dist/ir/type-system/internal/universe/clr-heritage-extraction.d.ts +28 -0
- package/dist/ir/type-system/internal/universe/clr-heritage-extraction.d.ts.map +1 -0
- package/dist/ir/type-system/internal/universe/clr-heritage-extraction.js +307 -0
- package/dist/ir/type-system/internal/universe/clr-heritage-extraction.js.map +1 -0
- package/dist/ir/type-system/internal/universe/clr-heritage-extractor.d.ts +11 -0
- package/dist/ir/type-system/internal/universe/clr-heritage-extractor.d.ts.map +1 -0
- package/dist/ir/type-system/internal/universe/clr-heritage-extractor.js +10 -0
- package/dist/ir/type-system/internal/universe/clr-heritage-extractor.js.map +1 -0
- package/dist/ir/type-system/internal/universe/clr-raw-converter.d.ts +41 -0
- package/dist/ir/type-system/internal/universe/clr-raw-converter.d.ts.map +1 -0
- package/dist/ir/type-system/internal/universe/clr-raw-converter.js +364 -0
- package/dist/ir/type-system/internal/universe/clr-raw-converter.js.map +1 -0
- package/dist/ir/type-system/internal/universe/clr-type-parser.d.ts +3 -41
- package/dist/ir/type-system/internal/universe/clr-type-parser.d.ts.map +1 -1
- package/dist/ir/type-system/internal/universe/clr-type-parser.js +3 -470
- package/dist/ir/type-system/internal/universe/clr-type-parser.js.map +1 -1
- package/dist/ir/type-system/internal/universe/clr-type-parser.test.js +13 -2
- package/dist/ir/type-system/internal/universe/clr-type-parser.test.js.map +1 -1
- package/dist/ir/type-system/internal/universe/clr-type-string-parsing.d.ts +28 -0
- package/dist/ir/type-system/internal/universe/clr-type-string-parsing.d.ts.map +1 -0
- package/dist/ir/type-system/internal/universe/clr-type-string-parsing.js +208 -0
- package/dist/ir/type-system/internal/universe/clr-type-string-parsing.js.map +1 -0
- package/dist/ir/type-system/internal/universe/dts-type-node-conversion.d.ts +28 -0
- package/dist/ir/type-system/internal/universe/dts-type-node-conversion.d.ts.map +1 -0
- package/dist/ir/type-system/internal/universe/dts-type-node-conversion.js +279 -0
- package/dist/ir/type-system/internal/universe/dts-type-node-conversion.js.map +1 -0
- package/dist/ir/type-system/internal/universe/index.d.ts +1 -1
- package/dist/ir/type-system/internal/universe/index.d.ts.map +1 -1
- package/dist/ir/type-system/internal/universe/index.js.map +1 -1
- package/dist/ir/type-system/internal/universe/raw-bindings-types.d.ts +167 -0
- package/dist/ir/type-system/internal/universe/raw-bindings-types.d.ts.map +1 -0
- package/dist/ir/type-system/internal/universe/raw-bindings-types.js +79 -0
- package/dist/ir/type-system/internal/universe/raw-bindings-types.js.map +1 -0
- package/dist/ir/type-system/internal/universe/source-catalog.d.ts +1 -1
- package/dist/ir/type-system/internal/universe/source-catalog.d.ts.map +1 -1
- package/dist/ir/type-system/internal/universe/source-catalog.js.map +1 -1
- package/dist/ir/type-system/internal/universe/types.d.ts +4 -388
- package/dist/ir/type-system/internal/universe/types.d.ts.map +1 -1
- package/dist/ir/type-system/internal/universe/types.js +2 -60
- package/dist/ir/type-system/internal/universe/types.js.map +1 -1
- package/dist/ir/type-system/internal/universe/unified-universe.d.ts +2 -2
- package/dist/ir/type-system/internal/universe/unified-universe.d.ts.map +1 -1
- package/dist/ir/type-system/internal/universe/unified-universe.js +467 -19
- package/dist/ir/type-system/internal/universe/unified-universe.js.map +1 -1
- package/dist/ir/type-system/internal/universe/unified-universe.test.js +7 -2
- package/dist/ir/type-system/internal/universe/unified-universe.test.js.map +1 -1
- package/dist/ir/type-system/iterable-type-shapes.d.ts +8 -0
- package/dist/ir/type-system/iterable-type-shapes.d.ts.map +1 -0
- package/dist/ir/type-system/iterable-type-shapes.js +229 -0
- package/dist/ir/type-system/iterable-type-shapes.js.map +1 -0
- package/dist/ir/type-system/type-alias-expansion.d.ts +4 -0
- package/dist/ir/type-system/type-alias-expansion.d.ts.map +1 -0
- package/dist/ir/type-system/type-alias-expansion.js +27 -0
- package/dist/ir/type-system/type-alias-expansion.js.map +1 -0
- package/dist/ir/type-system/type-system-call-resolution.d.ts +16 -68
- package/dist/ir/type-system/type-system-call-resolution.d.ts.map +1 -1
- package/dist/ir/type-system/type-system-call-resolution.js +17 -1407
- package/dist/ir/type-system/type-system-call-resolution.js.map +1 -1
- package/dist/ir/type-system/type-system-factory.d.ts +24 -0
- package/dist/ir/type-system/type-system-factory.d.ts.map +1 -0
- package/dist/ir/type-system/type-system-factory.js +145 -0
- package/dist/ir/type-system/type-system-factory.js.map +1 -0
- package/dist/ir/type-system/type-system-inference.d.ts +13 -92
- package/dist/ir/type-system/type-system-inference.d.ts.map +1 -1
- package/dist/ir/type-system/type-system-inference.js +18 -1315
- package/dist/ir/type-system/type-system-inference.js.map +1 -1
- package/dist/ir/type-system/type-system-relations.d.ts +1 -0
- package/dist/ir/type-system/type-system-relations.d.ts.map +1 -1
- package/dist/ir/type-system/type-system-relations.js +332 -19
- package/dist/ir/type-system/type-system-relations.js.map +1 -1
- package/dist/ir/type-system/type-system-state-call-types.d.ts +62 -0
- package/dist/ir/type-system/type-system-state-call-types.d.ts.map +1 -0
- package/dist/ir/type-system/type-system-state-call-types.js +2 -0
- package/dist/ir/type-system/type-system-state-call-types.js.map +1 -0
- package/dist/ir/type-system/type-system-state-handle-types.d.ts +134 -0
- package/dist/ir/type-system/type-system-state-handle-types.d.ts.map +1 -0
- package/dist/ir/type-system/type-system-state-handle-types.js +2 -0
- package/dist/ir/type-system/type-system-state-handle-types.js.map +1 -0
- package/dist/ir/type-system/type-system-state-helpers.d.ts +56 -0
- package/dist/ir/type-system/type-system-state-helpers.d.ts.map +1 -0
- package/dist/ir/type-system/type-system-state-helpers.js +291 -0
- package/dist/ir/type-system/type-system-state-helpers.js.map +1 -0
- package/dist/ir/type-system/type-system-state-model.d.ts +33 -0
- package/dist/ir/type-system/type-system-state-model.d.ts.map +1 -0
- package/dist/ir/type-system/type-system-state-model.js +3 -0
- package/dist/ir/type-system/type-system-state-model.js.map +1 -0
- package/dist/ir/type-system/type-system-state-registry-types.d.ts +11 -0
- package/dist/ir/type-system/type-system-state-registry-types.d.ts.map +1 -0
- package/dist/ir/type-system/type-system-state-registry-types.js +17 -0
- package/dist/ir/type-system/type-system-state-registry-types.js.map +1 -0
- package/dist/ir/type-system/type-system-state-types.d.ts +4 -0
- package/dist/ir/type-system/type-system-state-types.d.ts.map +1 -0
- package/dist/ir/type-system/type-system-state-types.js +4 -0
- package/dist/ir/type-system/type-system-state-types.js.map +1 -0
- package/dist/ir/type-system/type-system-state.d.ts +4 -454
- package/dist/ir/type-system/type-system-state.d.ts.map +1 -1
- package/dist/ir/type-system/type-system-state.js +4 -228
- package/dist/ir/type-system/type-system-state.js.map +1 -1
- package/dist/ir/type-system/type-system-types-api.d.ts +341 -0
- package/dist/ir/type-system/type-system-types-api.d.ts.map +1 -0
- package/dist/ir/type-system/type-system-types-api.js +11 -0
- package/dist/ir/type-system/type-system-types-api.js.map +1 -0
- package/dist/ir/type-system/type-system-utilities.d.ts +4 -48
- package/dist/ir/type-system/type-system-utilities.d.ts.map +1 -1
- package/dist/ir/type-system/type-system-utilities.js +4 -349
- package/dist/ir/type-system/type-system-utilities.js.map +1 -1
- package/dist/ir/type-system/type-system.d.ts +8 -313
- package/dist/ir/type-system/type-system.d.ts.map +1 -1
- package/dist/ir/type-system/type-system.js +7 -131
- package/dist/ir/type-system/type-system.js.map +1 -1
- package/dist/ir/type-system/types.d.ts +2 -0
- package/dist/ir/type-system/types.d.ts.map +1 -1
- package/dist/ir/type-system/types.js +5 -0
- package/dist/ir/type-system/types.js.map +1 -1
- package/dist/ir/type-system/utility-type-filter-helpers.d.ts +40 -0
- package/dist/ir/type-system/utility-type-filter-helpers.d.ts.map +1 -0
- package/dist/ir/type-system/utility-type-filter-helpers.js +142 -0
- package/dist/ir/type-system/utility-type-filter-helpers.js.map +1 -0
- package/dist/ir/type-system/utility-type-mapped-helpers.d.ts +34 -0
- package/dist/ir/type-system/utility-type-mapped-helpers.d.ts.map +1 -0
- package/dist/ir/type-system/utility-type-mapped-helpers.js +243 -0
- package/dist/ir/type-system/utility-type-mapped-helpers.js.map +1 -0
- package/dist/ir/types/expressions-core.d.ts +331 -0
- package/dist/ir/types/expressions-core.d.ts.map +1 -0
- package/dist/ir/types/expressions-core.js +5 -0
- package/dist/ir/types/expressions-core.js.map +1 -0
- package/dist/ir/types/expressions-extended.d.ts +232 -0
- package/dist/ir/types/expressions-extended.d.ts.map +1 -0
- package/dist/ir/types/expressions-extended.js +6 -0
- package/dist/ir/types/expressions-extended.js.map +1 -0
- package/dist/ir/types/expressions.d.ts +6 -480
- package/dist/ir/types/expressions.d.ts.map +1 -1
- package/dist/ir/types/expressions.js +5 -1
- package/dist/ir/types/expressions.js.map +1 -1
- package/dist/ir/types/helpers.d.ts +4 -0
- package/dist/ir/types/helpers.d.ts.map +1 -1
- package/dist/ir/types/index.d.ts +4 -2
- package/dist/ir/types/index.d.ts.map +1 -1
- package/dist/ir/types/index.js +2 -1
- package/dist/ir/types/index.js.map +1 -1
- package/dist/ir/types/ir-substitution-builders.d.ts +91 -0
- package/dist/ir/types/ir-substitution-builders.d.ts.map +1 -0
- package/dist/ir/types/ir-substitution-builders.js +340 -0
- package/dist/ir/types/ir-substitution-builders.js.map +1 -0
- package/dist/ir/types/ir-substitution-core.d.ts +55 -0
- package/dist/ir/types/ir-substitution-core.d.ts.map +1 -0
- package/dist/ir/types/ir-substitution-core.js +402 -0
- package/dist/ir/types/ir-substitution-core.js.map +1 -0
- package/dist/ir/types/ir-substitution.d.ts +13 -142
- package/dist/ir/types/ir-substitution.d.ts.map +1 -1
- package/dist/ir/types/ir-substitution.js +9 -565
- package/dist/ir/types/ir-substitution.js.map +1 -1
- package/dist/ir/types/ir-types.d.ts +80 -4
- package/dist/ir/types/ir-types.d.ts.map +1 -1
- package/dist/ir/types/overload-family.d.ts +36 -0
- package/dist/ir/types/overload-family.d.ts.map +1 -0
- package/dist/ir/types/overload-family.js +9 -0
- package/dist/ir/types/overload-family.js.map +1 -0
- package/dist/ir/types/statements.d.ts +8 -1
- package/dist/ir/types/statements.d.ts.map +1 -1
- package/dist/ir/types/type-ops.d.ts +41 -2
- package/dist/ir/types/type-ops.d.ts.map +1 -1
- package/dist/ir/types/type-ops.js +744 -45
- package/dist/ir/types/type-ops.js.map +1 -1
- package/dist/ir/types/type-ops.test.js +443 -1
- package/dist/ir/types/type-ops.test.js.map +1 -1
- package/dist/ir/types.d.ts +2 -2
- package/dist/ir/types.d.ts.map +1 -1
- package/dist/ir/types.js +1 -1
- package/dist/ir/types.js.map +1 -1
- package/dist/ir/validation/anon-type-declaration-synthesis.d.ts +11 -0
- package/dist/ir/validation/anon-type-declaration-synthesis.d.ts.map +1 -0
- package/dist/ir/validation/anon-type-declaration-synthesis.js +11 -0
- package/dist/ir/validation/anon-type-declaration-synthesis.js.map +1 -0
- package/dist/ir/validation/anon-type-ir-rewriting.d.ts +10 -0
- package/dist/ir/validation/anon-type-ir-rewriting.d.ts.map +1 -0
- package/dist/ir/validation/anon-type-ir-rewriting.js +3 -0
- package/dist/ir/validation/anon-type-ir-rewriting.js.map +1 -0
- package/dist/ir/validation/anon-type-lower-expressions.d.ts +10 -0
- package/dist/ir/validation/anon-type-lower-expressions.d.ts.map +1 -0
- package/dist/ir/validation/anon-type-lower-expressions.js +364 -0
- package/dist/ir/validation/anon-type-lower-expressions.js.map +1 -0
- package/dist/ir/validation/anon-type-lower-statements.d.ts +13 -0
- package/dist/ir/validation/anon-type-lower-statements.d.ts.map +1 -0
- package/dist/ir/validation/anon-type-lower-statements.js +270 -0
- package/dist/ir/validation/anon-type-lower-statements.js.map +1 -0
- package/dist/ir/validation/anon-type-lower-types.d.ts +60 -0
- package/dist/ir/validation/anon-type-lower-types.d.ts.map +1 -0
- package/dist/ir/validation/anon-type-lower-types.js +287 -0
- package/dist/ir/validation/anon-type-lower-types.js.map +1 -0
- package/dist/ir/validation/anon-type-naming.d.ts +20 -0
- package/dist/ir/validation/anon-type-naming.d.ts.map +1 -0
- package/dist/ir/validation/anon-type-naming.js +153 -0
- package/dist/ir/validation/anon-type-naming.js.map +1 -0
- package/dist/ir/validation/anon-type-shape-analysis.d.ts +13 -0
- package/dist/ir/validation/anon-type-shape-analysis.d.ts.map +1 -0
- package/dist/ir/validation/anon-type-shape-analysis.js +12 -0
- package/dist/ir/validation/anon-type-shape-analysis.js.map +1 -0
- package/dist/ir/validation/anon-type-shape-collectors.d.ts +39 -0
- package/dist/ir/validation/anon-type-shape-collectors.d.ts.map +1 -0
- package/dist/ir/validation/anon-type-shape-collectors.js +369 -0
- package/dist/ir/validation/anon-type-shape-collectors.js.map +1 -0
- package/dist/ir/validation/anon-type-shape-serialization.d.ts +38 -0
- package/dist/ir/validation/anon-type-shape-serialization.d.ts.map +1 -0
- package/dist/ir/validation/anon-type-shape-serialization.js +241 -0
- package/dist/ir/validation/anon-type-shape-serialization.js.map +1 -0
- package/dist/ir/validation/anon-type-template-inference.d.ts +12 -0
- package/dist/ir/validation/anon-type-template-inference.d.ts.map +1 -0
- package/dist/ir/validation/anon-type-template-inference.js +296 -0
- package/dist/ir/validation/anon-type-template-inference.js.map +1 -0
- package/dist/ir/validation/anonymous-type-lowering-pass.d.ts +7 -1
- package/dist/ir/validation/anonymous-type-lowering-pass.d.ts.map +1 -1
- package/dist/ir/validation/anonymous-type-lowering-pass.js +315 -1166
- package/dist/ir/validation/anonymous-type-lowering-pass.js.map +1 -1
- package/dist/ir/validation/anonymous-type-lowering-regressions-cases/basic-lowering.test.d.ts +2 -0
- package/dist/ir/validation/anonymous-type-lowering-regressions-cases/basic-lowering.test.d.ts.map +1 -0
- package/dist/ir/validation/anonymous-type-lowering-regressions-cases/basic-lowering.test.js +332 -0
- package/dist/ir/validation/anonymous-type-lowering-regressions-cases/basic-lowering.test.js.map +1 -0
- package/dist/ir/validation/anonymous-type-lowering-regressions-cases/cross-module-reuse.test.d.ts +2 -0
- package/dist/ir/validation/anonymous-type-lowering-regressions-cases/cross-module-reuse.test.d.ts.map +1 -0
- package/dist/ir/validation/anonymous-type-lowering-regressions-cases/cross-module-reuse.test.js +255 -0
- package/dist/ir/validation/anonymous-type-lowering-regressions-cases/cross-module-reuse.test.js.map +1 -0
- package/dist/ir/validation/anonymous-type-lowering-regressions-cases/structural-references.test.d.ts +2 -0
- package/dist/ir/validation/anonymous-type-lowering-regressions-cases/structural-references.test.d.ts.map +1 -0
- package/dist/ir/validation/anonymous-type-lowering-regressions-cases/structural-references.test.js +715 -0
- package/dist/ir/validation/anonymous-type-lowering-regressions-cases/structural-references.test.js.map +1 -0
- package/dist/ir/validation/anonymous-type-lowering-regressions-cases/test-helpers.d.ts +4 -0
- package/dist/ir/validation/anonymous-type-lowering-regressions-cases/test-helpers.d.ts.map +1 -0
- package/dist/ir/validation/anonymous-type-lowering-regressions-cases/test-helpers.js +85 -0
- package/dist/ir/validation/anonymous-type-lowering-regressions-cases/test-helpers.js.map +1 -0
- package/dist/ir/validation/anonymous-type-lowering-regressions.test.d.ts +3 -1
- package/dist/ir/validation/anonymous-type-lowering-regressions.test.d.ts.map +1 -1
- package/dist/ir/validation/anonymous-type-lowering-regressions.test.js +3 -120
- package/dist/ir/validation/anonymous-type-lowering-regressions.test.js.map +1 -1
- package/dist/ir/validation/arrow-return-expression-walk.d.ts +13 -0
- package/dist/ir/validation/arrow-return-expression-walk.d.ts.map +1 -0
- package/dist/ir/validation/arrow-return-expression-walk.js +224 -0
- package/dist/ir/validation/arrow-return-expression-walk.js.map +1 -0
- package/dist/ir/validation/arrow-return-finalization-pass.d.ts +3 -17
- package/dist/ir/validation/arrow-return-finalization-pass.d.ts.map +1 -1
- package/dist/ir/validation/arrow-return-finalization-pass.js +2 -418
- package/dist/ir/validation/arrow-return-finalization-pass.js.map +1 -1
- package/dist/ir/validation/arrow-return-statement-walk.d.ts +27 -0
- package/dist/ir/validation/arrow-return-statement-walk.d.ts.map +1 -0
- package/dist/ir/validation/arrow-return-statement-walk.js +206 -0
- package/dist/ir/validation/arrow-return-statement-walk.js.map +1 -0
- package/dist/ir/validation/attribute-collection/arg-extractor.d.ts +8 -2
- package/dist/ir/validation/attribute-collection/arg-extractor.d.ts.map +1 -1
- package/dist/ir/validation/attribute-collection/arg-extractor.js.map +1 -1
- package/dist/ir/validation/attribute-collection/marker-chain-parser.d.ts +21 -0
- package/dist/ir/validation/attribute-collection/marker-chain-parser.d.ts.map +1 -0
- package/dist/ir/validation/attribute-collection/marker-chain-parser.js +261 -0
- package/dist/ir/validation/attribute-collection/marker-chain-parser.js.map +1 -0
- package/dist/ir/validation/attribute-collection/marker-collection.d.ts +28 -0
- package/dist/ir/validation/attribute-collection/marker-collection.d.ts.map +1 -0
- package/dist/ir/validation/attribute-collection/marker-collection.js +343 -0
- package/dist/ir/validation/attribute-collection/marker-collection.js.map +1 -0
- package/dist/ir/validation/attribute-collection/marker-detection.d.ts +25 -0
- package/dist/ir/validation/attribute-collection/marker-detection.d.ts.map +1 -0
- package/dist/ir/validation/attribute-collection/marker-detection.js +214 -0
- package/dist/ir/validation/attribute-collection/marker-detection.js.map +1 -0
- package/dist/ir/validation/attribute-collection/marker-parser.d.ts +7 -24
- package/dist/ir/validation/attribute-collection/marker-parser.d.ts.map +1 -1
- package/dist/ir/validation/attribute-collection/marker-parser.js +7 -400
- package/dist/ir/validation/attribute-collection/marker-parser.js.map +1 -1
- package/dist/ir/validation/attribute-collection/module-rebuild.d.ts +28 -0
- package/dist/ir/validation/attribute-collection/module-rebuild.d.ts.map +1 -0
- package/dist/ir/validation/attribute-collection/module-rebuild.js +176 -0
- package/dist/ir/validation/attribute-collection/module-rebuild.js.map +1 -0
- package/dist/ir/validation/attribute-collection/orchestrator.d.ts +3 -19
- package/dist/ir/validation/attribute-collection/orchestrator.d.ts.map +1 -1
- package/dist/ir/validation/attribute-collection/orchestrator.js +2 -323
- package/dist/ir/validation/attribute-collection/orchestrator.js.map +1 -1
- package/dist/ir/validation/attribute-collection-cases/ctor-add.test.d.ts +5 -0
- package/dist/ir/validation/attribute-collection-cases/ctor-add.test.d.ts.map +1 -0
- package/dist/ir/validation/attribute-collection-cases/ctor-add.test.js +62 -0
- package/dist/ir/validation/attribute-collection-cases/ctor-add.test.js.map +1 -0
- package/dist/ir/validation/attribute-collection-cases/error-cases.test.d.ts +5 -0
- package/dist/ir/validation/attribute-collection-cases/error-cases.test.d.ts.map +1 -0
- package/dist/ir/validation/attribute-collection-cases/error-cases.test.js +246 -0
- package/dist/ir/validation/attribute-collection-cases/error-cases.test.js.map +1 -0
- package/dist/ir/validation/attribute-collection-cases/function-and-misc.test.d.ts +6 -0
- package/dist/ir/validation/attribute-collection-cases/function-and-misc.test.d.ts.map +1 -0
- package/dist/ir/validation/attribute-collection-cases/function-and-misc.test.js +77 -0
- package/dist/ir/validation/attribute-collection-cases/function-and-misc.test.js.map +1 -0
- package/dist/ir/validation/attribute-collection-cases/helpers.d.ts +186 -0
- package/dist/ir/validation/attribute-collection-cases/helpers.d.ts.map +1 -0
- package/dist/ir/validation/attribute-collection-cases/helpers.js +239 -0
- package/dist/ir/validation/attribute-collection-cases/helpers.js.map +1 -0
- package/dist/ir/validation/attribute-collection-cases/method-selector.test.d.ts +5 -0
- package/dist/ir/validation/attribute-collection-cases/method-selector.test.d.ts.map +1 -0
- package/dist/ir/validation/attribute-collection-cases/method-selector.test.js +371 -0
- package/dist/ir/validation/attribute-collection-cases/method-selector.test.js.map +1 -0
- package/dist/ir/validation/attribute-collection-cases/prop-selector.test.d.ts +5 -0
- package/dist/ir/validation/attribute-collection-cases/prop-selector.test.d.ts.map +1 -0
- package/dist/ir/validation/attribute-collection-cases/prop-selector.test.js +209 -0
- package/dist/ir/validation/attribute-collection-cases/prop-selector.test.js.map +1 -0
- package/dist/ir/validation/attribute-collection-cases/type-add.test.d.ts +5 -0
- package/dist/ir/validation/attribute-collection-cases/type-add.test.d.ts.map +1 -0
- package/dist/ir/validation/attribute-collection-cases/type-add.test.js +330 -0
- package/dist/ir/validation/attribute-collection-cases/type-add.test.js.map +1 -0
- package/dist/ir/validation/attribute-collection-pass.d.ts +5 -4
- package/dist/ir/validation/attribute-collection-pass.d.ts.map +1 -1
- package/dist/ir/validation/attribute-collection-pass.js +5 -4
- package/dist/ir/validation/attribute-collection-pass.js.map +1 -1
- package/dist/ir/validation/attribute-collection-pass.test.d.ts +8 -1
- package/dist/ir/validation/attribute-collection-pass.test.d.ts.map +1 -1
- package/dist/ir/validation/attribute-collection-pass.test.js +8 -1331
- package/dist/ir/validation/attribute-collection-pass.test.js.map +1 -1
- package/dist/ir/validation/call-resolution-refresh-pass.d.ts +8 -0
- package/dist/ir/validation/call-resolution-refresh-pass.d.ts.map +1 -0
- package/dist/ir/validation/call-resolution-refresh-pass.js +616 -0
- package/dist/ir/validation/call-resolution-refresh-pass.js.map +1 -0
- package/dist/ir/validation/char-validation-expressions.d.ts +13 -0
- package/dist/ir/validation/char-validation-expressions.d.ts.map +1 -0
- package/dist/ir/validation/char-validation-expressions.js +362 -0
- package/dist/ir/validation/char-validation-expressions.js.map +1 -0
- package/dist/ir/validation/char-validation-pass.d.ts +7 -22
- package/dist/ir/validation/char-validation-pass.d.ts.map +1 -1
- package/dist/ir/validation/char-validation-pass.js +6 -504
- package/dist/ir/validation/char-validation-pass.js.map +1 -1
- package/dist/ir/validation/char-validation-types.d.ts +28 -0
- package/dist/ir/validation/char-validation-types.d.ts.map +1 -0
- package/dist/ir/validation/char-validation-types.js +144 -0
- package/dist/ir/validation/char-validation-types.js.map +1 -0
- package/dist/ir/validation/index.d.ts +3 -0
- package/dist/ir/validation/index.d.ts.map +1 -1
- package/dist/ir/validation/index.js +3 -0
- package/dist/ir/validation/index.js.map +1 -1
- package/dist/ir/validation/known-builtin-reference-types.d.ts +12 -0
- package/dist/ir/validation/known-builtin-reference-types.d.ts.map +1 -0
- package/dist/ir/validation/known-builtin-reference-types.js +29 -0
- package/dist/ir/validation/known-builtin-reference-types.js.map +1 -0
- package/dist/ir/validation/numeric-classification.d.ts +105 -0
- package/dist/ir/validation/numeric-classification.d.ts.map +1 -0
- package/dist/ir/validation/numeric-classification.js +368 -0
- package/dist/ir/validation/numeric-classification.js.map +1 -0
- package/dist/ir/validation/numeric-coercion-pass.d.ts +3 -50
- package/dist/ir/validation/numeric-coercion-pass.d.ts.map +1 -1
- package/dist/ir/validation/numeric-coercion-pass.js +3 -777
- package/dist/ir/validation/numeric-coercion-pass.js.map +1 -1
- package/dist/ir/validation/numeric-expression-validation.d.ts +26 -0
- package/dist/ir/validation/numeric-expression-validation.d.ts.map +1 -0
- package/dist/ir/validation/numeric-expression-validation.js +253 -0
- package/dist/ir/validation/numeric-expression-validation.js.map +1 -0
- package/dist/ir/validation/numeric-invariants-cases/array-index-proofs.test.d.ts +11 -0
- package/dist/ir/validation/numeric-invariants-cases/array-index-proofs.test.d.ts.map +1 -0
- package/dist/ir/validation/numeric-invariants-cases/array-index-proofs.test.js +185 -0
- package/dist/ir/validation/numeric-invariants-cases/array-index-proofs.test.js.map +1 -0
- package/dist/ir/validation/numeric-invariants-cases/arrow-function-proofs.test.d.ts +16 -0
- package/dist/ir/validation/numeric-invariants-cases/arrow-function-proofs.test.d.ts.map +1 -0
- package/dist/ir/validation/numeric-invariants-cases/arrow-function-proofs.test.js +364 -0
- package/dist/ir/validation/numeric-invariants-cases/arrow-function-proofs.test.js.map +1 -0
- package/dist/ir/validation/numeric-invariants-cases/binary-promotion.test.d.ts +9 -0
- package/dist/ir/validation/numeric-invariants-cases/binary-promotion.test.d.ts.map +1 -0
- package/dist/ir/validation/numeric-invariants-cases/binary-promotion.test.js +119 -0
- package/dist/ir/validation/numeric-invariants-cases/binary-promotion.test.js.map +1 -0
- package/dist/ir/validation/numeric-invariants-cases/helpers.d.ts +60 -0
- package/dist/ir/validation/numeric-invariants-cases/helpers.d.ts.map +1 -0
- package/dist/ir/validation/numeric-invariants-cases/helpers.js +163 -0
- package/dist/ir/validation/numeric-invariants-cases/helpers.js.map +1 -0
- package/dist/ir/validation/numeric-invariants-cases/literal-range-validation.test.d.ts +8 -0
- package/dist/ir/validation/numeric-invariants-cases/literal-range-validation.test.d.ts.map +1 -0
- package/dist/ir/validation/numeric-invariants-cases/literal-range-validation.test.js +110 -0
- package/dist/ir/validation/numeric-invariants-cases/literal-range-validation.test.js.map +1 -0
- package/dist/ir/validation/numeric-invariants-cases/narrowing-intent.test.d.ts +12 -0
- package/dist/ir/validation/numeric-invariants-cases/narrowing-intent.test.d.ts.map +1 -0
- package/dist/ir/validation/numeric-invariants-cases/narrowing-intent.test.js +188 -0
- package/dist/ir/validation/numeric-invariants-cases/narrowing-intent.test.js.map +1 -0
- package/dist/ir/validation/numeric-invariants.test.d.ts +5 -14
- package/dist/ir/validation/numeric-invariants.test.d.ts.map +1 -1
- package/dist/ir/validation/numeric-invariants.test.js +5 -932
- package/dist/ir/validation/numeric-invariants.test.js.map +1 -1
- package/dist/ir/validation/numeric-proof-analysis.d.ts +9 -0
- package/dist/ir/validation/numeric-proof-analysis.d.ts.map +1 -0
- package/dist/ir/validation/numeric-proof-analysis.js +8 -0
- package/dist/ir/validation/numeric-proof-analysis.js.map +1 -0
- package/dist/ir/validation/numeric-proof-expression-walk.d.ts +18 -0
- package/dist/ir/validation/numeric-proof-expression-walk.d.ts.map +1 -0
- package/dist/ir/validation/numeric-proof-expression-walk.js +331 -0
- package/dist/ir/validation/numeric-proof-expression-walk.js.map +1 -0
- package/dist/ir/validation/numeric-proof-guard-facts.d.ts +29 -0
- package/dist/ir/validation/numeric-proof-guard-facts.d.ts.map +1 -0
- package/dist/ir/validation/numeric-proof-guard-facts.js +213 -0
- package/dist/ir/validation/numeric-proof-guard-facts.js.map +1 -0
- package/dist/ir/validation/numeric-proof-inference.d.ts +33 -0
- package/dist/ir/validation/numeric-proof-inference.d.ts.map +1 -0
- package/dist/ir/validation/numeric-proof-inference.js +222 -0
- package/dist/ir/validation/numeric-proof-inference.js.map +1 -0
- package/dist/ir/validation/numeric-proof-pass.d.ts +5 -25
- package/dist/ir/validation/numeric-proof-pass.d.ts.map +1 -1
- package/dist/ir/validation/numeric-proof-pass.js +5 -1165
- package/dist/ir/validation/numeric-proof-pass.js.map +1 -1
- package/dist/ir/validation/numeric-proof-proving.d.ts +21 -0
- package/dist/ir/validation/numeric-proof-proving.d.ts.map +1 -0
- package/dist/ir/validation/numeric-proof-proving.js +261 -0
- package/dist/ir/validation/numeric-proof-proving.js.map +1 -0
- package/dist/ir/validation/numeric-proof-statement-walk.d.ts +37 -0
- package/dist/ir/validation/numeric-proof-statement-walk.d.ts.map +1 -0
- package/dist/ir/validation/numeric-proof-statement-walk.js +295 -0
- package/dist/ir/validation/numeric-proof-statement-walk.js.map +1 -0
- package/dist/ir/validation/numeric-proof-walk.d.ts +10 -0
- package/dist/ir/validation/numeric-proof-walk.d.ts.map +1 -0
- package/dist/ir/validation/numeric-proof-walk.js +9 -0
- package/dist/ir/validation/numeric-proof-walk.js.map +1 -0
- package/dist/ir/validation/numeric-statement-processing.d.ts +39 -0
- package/dist/ir/validation/numeric-statement-processing.d.ts.map +1 -0
- package/dist/ir/validation/numeric-statement-processing.js +229 -0
- package/dist/ir/validation/numeric-statement-processing.js.map +1 -0
- package/dist/ir/validation/numeric-validation.d.ts +13 -0
- package/dist/ir/validation/numeric-validation.d.ts.map +1 -0
- package/dist/ir/validation/numeric-validation.js +12 -0
- package/dist/ir/validation/numeric-validation.js.map +1 -0
- package/dist/ir/validation/overload-collection-cases/basic.test.d.ts +2 -0
- package/dist/ir/validation/overload-collection-cases/basic.test.d.ts.map +1 -0
- package/dist/ir/validation/overload-collection-cases/basic.test.js +103 -0
- package/dist/ir/validation/overload-collection-cases/basic.test.js.map +1 -0
- package/dist/ir/validation/overload-collection-cases/consistency.test.d.ts +2 -0
- package/dist/ir/validation/overload-collection-cases/consistency.test.d.ts.map +1 -0
- package/dist/ir/validation/overload-collection-cases/consistency.test.js +79 -0
- package/dist/ir/validation/overload-collection-cases/consistency.test.js.map +1 -0
- package/dist/ir/validation/overload-collection-cases/error-cases.test.d.ts +2 -0
- package/dist/ir/validation/overload-collection-cases/error-cases.test.d.ts.map +1 -0
- package/dist/ir/validation/overload-collection-cases/error-cases.test.js +24 -0
- package/dist/ir/validation/overload-collection-cases/error-cases.test.js.map +1 -0
- package/dist/ir/validation/overload-collection-cases/helpers.d.ts +107 -0
- package/dist/ir/validation/overload-collection-cases/helpers.d.ts.map +1 -0
- package/dist/ir/validation/overload-collection-cases/helpers.js +142 -0
- package/dist/ir/validation/overload-collection-cases/helpers.js.map +1 -0
- package/dist/ir/validation/overload-collection-pass.d.ts +16 -0
- package/dist/ir/validation/overload-collection-pass.d.ts.map +1 -0
- package/dist/ir/validation/overload-collection-pass.js +930 -0
- package/dist/ir/validation/overload-collection-pass.js.map +1 -0
- package/dist/ir/validation/overload-collection-pass.test.d.ts +4 -0
- package/dist/ir/validation/overload-collection-pass.test.d.ts.map +1 -0
- package/dist/ir/validation/overload-collection-pass.test.js +4 -0
- package/dist/ir/validation/overload-collection-pass.test.js.map +1 -0
- package/dist/ir/validation/overload-family-consistency-pass.d.ts +9 -0
- package/dist/ir/validation/overload-family-consistency-pass.d.ts.map +1 -0
- package/dist/ir/validation/overload-family-consistency-pass.js +161 -0
- package/dist/ir/validation/overload-family-consistency-pass.js.map +1 -0
- package/dist/ir/validation/rest-type-synthesis-helpers.d.ts +52 -0
- package/dist/ir/validation/rest-type-synthesis-helpers.d.ts.map +1 -0
- package/dist/ir/validation/rest-type-synthesis-helpers.js +250 -0
- package/dist/ir/validation/rest-type-synthesis-helpers.js.map +1 -0
- package/dist/ir/validation/rest-type-synthesis-pass.d.ts +6 -20
- package/dist/ir/validation/rest-type-synthesis-pass.d.ts.map +1 -1
- package/dist/ir/validation/rest-type-synthesis-pass.js +5 -461
- package/dist/ir/validation/rest-type-synthesis-pass.js.map +1 -1
- package/dist/ir/validation/rest-type-synthesis-processing.d.ts +14 -0
- package/dist/ir/validation/rest-type-synthesis-processing.d.ts.map +1 -0
- package/dist/ir/validation/rest-type-synthesis-processing.js +220 -0
- package/dist/ir/validation/rest-type-synthesis-processing.js.map +1 -0
- package/dist/ir/validation/soundness-gate-cases/any-type-and-primitives.test.d.ts +12 -0
- package/dist/ir/validation/soundness-gate-cases/any-type-and-primitives.test.d.ts.map +1 -0
- package/dist/ir/validation/soundness-gate-cases/any-type-and-primitives.test.js +99 -0
- package/dist/ir/validation/soundness-gate-cases/any-type-and-primitives.test.js.map +1 -0
- package/dist/ir/validation/soundness-gate-cases/computed-member-access.test.d.ts +10 -0
- package/dist/ir/validation/soundness-gate-cases/computed-member-access.test.d.ts.map +1 -0
- package/dist/ir/validation/soundness-gate-cases/computed-member-access.test.js +139 -0
- package/dist/ir/validation/soundness-gate-cases/computed-member-access.test.js.map +1 -0
- package/dist/ir/validation/soundness-gate-cases/inference-diagnostics.test.d.ts +10 -0
- package/dist/ir/validation/soundness-gate-cases/inference-diagnostics.test.d.ts.map +1 -0
- package/dist/ir/validation/soundness-gate-cases/inference-diagnostics.test.js +123 -0
- package/dist/ir/validation/soundness-gate-cases/inference-diagnostics.test.js.map +1 -0
- package/dist/ir/validation/soundness-gate-cases/reference-type-resolution.test.d.ts +15 -0
- package/dist/ir/validation/soundness-gate-cases/reference-type-resolution.test.d.ts.map +1 -0
- package/dist/ir/validation/soundness-gate-cases/reference-type-resolution.test.js +292 -0
- package/dist/ir/validation/soundness-gate-cases/reference-type-resolution.test.js.map +1 -0
- package/dist/ir/validation/soundness-gate-cases/test-helpers.d.ts +12 -0
- package/dist/ir/validation/soundness-gate-cases/test-helpers.d.ts.map +1 -0
- package/dist/ir/validation/soundness-gate-cases/test-helpers.js +36 -0
- package/dist/ir/validation/soundness-gate-cases/test-helpers.js.map +1 -0
- package/dist/ir/validation/soundness-gate-cases/type-params-and-intrinsics.test.d.ts +11 -0
- package/dist/ir/validation/soundness-gate-cases/type-params-and-intrinsics.test.d.ts.map +1 -0
- package/dist/ir/validation/soundness-gate-cases/type-params-and-intrinsics.test.js +249 -0
- package/dist/ir/validation/soundness-gate-cases/type-params-and-intrinsics.test.js.map +1 -0
- package/dist/ir/validation/soundness-gate-expression-validation.d.ts +3 -0
- package/dist/ir/validation/soundness-gate-expression-validation.d.ts.map +1 -0
- package/dist/ir/validation/soundness-gate-expression-validation.js +205 -0
- package/dist/ir/validation/soundness-gate-expression-validation.js.map +1 -0
- package/dist/ir/validation/soundness-gate-shared.d.ts +26 -0
- package/dist/ir/validation/soundness-gate-shared.d.ts.map +1 -0
- package/dist/ir/validation/soundness-gate-shared.js +46 -0
- package/dist/ir/validation/soundness-gate-shared.js.map +1 -0
- package/dist/ir/validation/soundness-gate-statement-validation.d.ts +5 -0
- package/dist/ir/validation/soundness-gate-statement-validation.d.ts.map +1 -0
- package/dist/ir/validation/soundness-gate-statement-validation.js +199 -0
- package/dist/ir/validation/soundness-gate-statement-validation.js.map +1 -0
- package/dist/ir/validation/soundness-gate-type-validation.d.ts +9 -0
- package/dist/ir/validation/soundness-gate-type-validation.d.ts.map +1 -0
- package/dist/ir/validation/soundness-gate-type-validation.js +149 -0
- package/dist/ir/validation/soundness-gate-type-validation.js.map +1 -0
- package/dist/ir/validation/soundness-gate.d.ts +2 -18
- package/dist/ir/validation/soundness-gate.d.ts.map +1 -1
- package/dist/ir/validation/soundness-gate.js +15 -608
- package/dist/ir/validation/soundness-gate.js.map +1 -1
- package/dist/ir/validation/soundness-gate.test.d.ts +5 -12
- package/dist/ir/validation/soundness-gate.test.d.ts.map +1 -1
- package/dist/ir/validation/soundness-gate.test.js +5 -696
- package/dist/ir/validation/soundness-gate.test.js.map +1 -1
- package/dist/ir/validation/virtual-marking-pass.d.ts +10 -2
- package/dist/ir/validation/virtual-marking-pass.d.ts.map +1 -1
- package/dist/ir/validation/virtual-marking-pass.js +347 -59
- package/dist/ir/validation/virtual-marking-pass.js.map +1 -1
- package/dist/ir/validation/virtual-marking-pass.test.d.ts +2 -0
- package/dist/ir/validation/virtual-marking-pass.test.d.ts.map +1 -0
- package/dist/ir/validation/virtual-marking-pass.test.js +314 -0
- package/dist/ir/validation/virtual-marking-pass.test.js.map +1 -0
- package/dist/ir/validation/yield-expression-lowering.d.ts +13 -0
- package/dist/ir/validation/yield-expression-lowering.d.ts.map +1 -0
- package/dist/ir/validation/yield-expression-lowering.js +13 -0
- package/dist/ir/validation/yield-expression-lowering.js.map +1 -0
- package/dist/ir/validation/yield-lowering-cases/assignment-yield.test.d.ts +14 -0
- package/dist/ir/validation/yield-lowering-cases/assignment-yield.test.d.ts.map +1 -0
- package/dist/ir/validation/yield-lowering-cases/assignment-yield.test.js +383 -0
- package/dist/ir/validation/yield-lowering-cases/assignment-yield.test.js.map +1 -0
- package/dist/ir/validation/yield-lowering-cases/basic-yield.test.d.ts +12 -0
- package/dist/ir/validation/yield-lowering-cases/basic-yield.test.d.ts.map +1 -0
- package/dist/ir/validation/yield-lowering-cases/basic-yield.test.js +120 -0
- package/dist/ir/validation/yield-lowering-cases/basic-yield.test.js.map +1 -0
- package/dist/ir/validation/yield-lowering-cases/control-flow.test.d.ts +13 -0
- package/dist/ir/validation/yield-lowering-cases/control-flow.test.d.ts.map +1 -0
- package/dist/ir/validation/yield-lowering-cases/control-flow.test.js +284 -0
- package/dist/ir/validation/yield-lowering-cases/control-flow.test.js.map +1 -0
- package/dist/ir/validation/yield-lowering-cases/destructuring-and-unsupported.test.d.ts +13 -0
- package/dist/ir/validation/yield-lowering-cases/destructuring-and-unsupported.test.d.ts.map +1 -0
- package/dist/ir/validation/yield-lowering-cases/destructuring-and-unsupported.test.js +334 -0
- package/dist/ir/validation/yield-lowering-cases/destructuring-and-unsupported.test.js.map +1 -0
- package/dist/ir/validation/yield-lowering-cases/for-loop-initializer.test.d.ts +16 -0
- package/dist/ir/validation/yield-lowering-cases/for-loop-initializer.test.d.ts.map +1 -0
- package/dist/ir/validation/yield-lowering-cases/for-loop-initializer.test.js +321 -0
- package/dist/ir/validation/yield-lowering-cases/for-loop-initializer.test.js.map +1 -0
- package/dist/ir/validation/yield-lowering-cases/helpers.d.ts +32 -0
- package/dist/ir/validation/yield-lowering-cases/helpers.d.ts.map +1 -0
- package/dist/ir/validation/yield-lowering-cases/helpers.js +76 -0
- package/dist/ir/validation/yield-lowering-cases/helpers.js.map +1 -0
- package/dist/ir/validation/yield-lowering-cases/nested-yield-in-statements.test.d.ts +13 -0
- package/dist/ir/validation/yield-lowering-cases/nested-yield-in-statements.test.d.ts.map +1 -0
- package/dist/ir/validation/yield-lowering-cases/nested-yield-in-statements.test.js +221 -0
- package/dist/ir/validation/yield-lowering-cases/nested-yield-in-statements.test.js.map +1 -0
- package/dist/ir/validation/yield-lowering-cases/non-generator-and-modules.test.d.ts +11 -0
- package/dist/ir/validation/yield-lowering-cases/non-generator-and-modules.test.d.ts.map +1 -0
- package/dist/ir/validation/yield-lowering-cases/non-generator-and-modules.test.js +136 -0
- package/dist/ir/validation/yield-lowering-cases/non-generator-and-modules.test.js.map +1 -0
- package/dist/ir/validation/yield-lowering-cases/pipeline-contract-and-return.test.d.ts +14 -0
- package/dist/ir/validation/yield-lowering-cases/pipeline-contract-and-return.test.d.ts.map +1 -0
- package/dist/ir/validation/yield-lowering-cases/pipeline-contract-and-return.test.js +219 -0
- package/dist/ir/validation/yield-lowering-cases/pipeline-contract-and-return.test.js.map +1 -0
- package/dist/ir/validation/yield-lowering-helpers.d.ts +63 -0
- package/dist/ir/validation/yield-lowering-helpers.d.ts.map +1 -0
- package/dist/ir/validation/yield-lowering-helpers.js +240 -0
- package/dist/ir/validation/yield-lowering-helpers.js.map +1 -0
- package/dist/ir/validation/yield-lowering-pass.d.ts +7 -1
- package/dist/ir/validation/yield-lowering-pass.d.ts.map +1 -1
- package/dist/ir/validation/yield-lowering-pass.js +8 -1418
- package/dist/ir/validation/yield-lowering-pass.js.map +1 -1
- package/dist/ir/validation/yield-lowering-pass.test.d.ts +8 -11
- package/dist/ir/validation/yield-lowering-pass.test.d.ts.map +1 -1
- package/dist/ir/validation/yield-lowering-pass.test.js +8 -1975
- package/dist/ir/validation/yield-lowering-pass.test.js.map +1 -1
- package/dist/ir/validation/yield-main-expression-lowering.d.ts +20 -0
- package/dist/ir/validation/yield-main-expression-lowering.d.ts.map +1 -0
- package/dist/ir/validation/yield-main-expression-lowering.js +381 -0
- package/dist/ir/validation/yield-main-expression-lowering.js.map +1 -0
- package/dist/ir/validation/yield-member-access-lowering.d.ts +21 -0
- package/dist/ir/validation/yield-member-access-lowering.d.ts.map +1 -0
- package/dist/ir/validation/yield-member-access-lowering.js +58 -0
- package/dist/ir/validation/yield-member-access-lowering.js.map +1 -0
- package/dist/ir/validation/yield-module-processing.d.ts +25 -0
- package/dist/ir/validation/yield-module-processing.d.ts.map +1 -0
- package/dist/ir/validation/yield-module-processing.js +180 -0
- package/dist/ir/validation/yield-module-processing.js.map +1 -0
- package/dist/ir/validation/yield-statement-loops.d.ts +51 -0
- package/dist/ir/validation/yield-statement-loops.d.ts.map +1 -0
- package/dist/ir/validation/yield-statement-loops.js +344 -0
- package/dist/ir/validation/yield-statement-loops.js.map +1 -0
- package/dist/ir/validation/yield-statement-lowering.d.ts +18 -0
- package/dist/ir/validation/yield-statement-lowering.d.ts.map +1 -0
- package/dist/ir/validation/yield-statement-lowering.js +48 -0
- package/dist/ir/validation/yield-statement-lowering.js.map +1 -0
- package/dist/ir/validation/yield-statement-simple.d.ts +33 -0
- package/dist/ir/validation/yield-statement-simple.d.ts.map +1 -0
- package/dist/ir/validation/yield-statement-simple.js +268 -0
- package/dist/ir/validation/yield-statement-simple.js.map +1 -0
- package/dist/program/binding-loader.d.ts.map +1 -1
- package/dist/program/binding-loader.js +1099 -6
- package/dist/program/binding-loader.js.map +1 -1
- package/dist/program/binding-payload-invariants.test.d.ts +2 -0
- package/dist/program/binding-payload-invariants.test.d.ts.map +1 -0
- package/dist/program/binding-payload-invariants.test.js +55 -0
- package/dist/program/binding-payload-invariants.test.js.map +1 -0
- package/dist/program/binding-registry-loading.d.ts +51 -0
- package/dist/program/binding-registry-loading.d.ts.map +1 -0
- package/dist/program/binding-registry-loading.js +816 -0
- package/dist/program/binding-registry-loading.js.map +1 -0
- package/dist/program/binding-registry-resolution-extension.d.ts +26 -0
- package/dist/program/binding-registry-resolution-extension.d.ts.map +1 -0
- package/dist/program/binding-registry-resolution-extension.js +161 -0
- package/dist/program/binding-registry-resolution-extension.js.map +1 -0
- package/dist/program/binding-registry-resolution-member.d.ts +46 -0
- package/dist/program/binding-registry-resolution-member.d.ts.map +1 -0
- package/dist/program/binding-registry-resolution-member.js +252 -0
- package/dist/program/binding-registry-resolution-member.js.map +1 -0
- package/dist/program/binding-registry-resolution.d.ts +13 -0
- package/dist/program/binding-registry-resolution.d.ts.map +1 -0
- package/dist/program/binding-registry-resolution.js +12 -0
- package/dist/program/binding-registry-resolution.js.map +1 -0
- package/dist/program/binding-registry.d.ts +34 -22
- package/dist/program/binding-registry.d.ts.map +1 -1
- package/dist/program/binding-registry.js +111 -562
- package/dist/program/binding-registry.js.map +1 -1
- package/dist/program/binding-types.d.ts +34 -3
- package/dist/program/binding-types.d.ts.map +1 -1
- package/dist/program/binding-types.js +72 -2
- package/dist/program/binding-types.js.map +1 -1
- package/dist/program/bindings-cases/dotnet-payload-boundaries.test.d.ts +2 -0
- package/dist/program/bindings-cases/dotnet-payload-boundaries.test.d.ts.map +1 -0
- package/dist/program/bindings-cases/dotnet-payload-boundaries.test.js +115 -0
- package/dist/program/bindings-cases/dotnet-payload-boundaries.test.js.map +1 -0
- package/dist/program/bindings-cases/hierarchical-and-type-semantics.test.d.ts +6 -0
- package/dist/program/bindings-cases/hierarchical-and-type-semantics.test.d.ts.map +1 -0
- package/dist/program/bindings-cases/hierarchical-and-type-semantics.test.js +573 -0
- package/dist/program/bindings-cases/hierarchical-and-type-semantics.test.js.map +1 -0
- package/dist/program/bindings-cases/load-bindings.test.d.ts +7 -0
- package/dist/program/bindings-cases/load-bindings.test.d.ts.map +1 -0
- package/dist/program/bindings-cases/load-bindings.test.js +545 -0
- package/dist/program/bindings-cases/load-bindings.test.js.map +1 -0
- package/dist/program/bindings-cases/registry-basics.test.d.ts +6 -0
- package/dist/program/bindings-cases/registry-basics.test.d.ts.map +1 -0
- package/dist/program/bindings-cases/registry-basics.test.js +201 -0
- package/dist/program/bindings-cases/registry-basics.test.js.map +1 -0
- package/dist/program/bindings-cases/registry-member-resolution.test.d.ts +8 -0
- package/dist/program/bindings-cases/registry-member-resolution.test.d.ts.map +1 -0
- package/dist/program/bindings-cases/registry-member-resolution.test.js +301 -0
- package/dist/program/bindings-cases/registry-member-resolution.test.js.map +1 -0
- package/dist/program/bindings.d.ts +2 -1
- package/dist/program/bindings.d.ts.map +1 -1
- package/dist/program/bindings.js +1 -0
- package/dist/program/bindings.js.map +1 -1
- package/dist/program/bindings.test.d.ts +12 -2
- package/dist/program/bindings.test.d.ts.map +1 -1
- package/dist/program/bindings.test.js +12 -988
- package/dist/program/bindings.test.js.map +1 -1
- package/dist/program/core-declarations.d.ts +16 -0
- package/dist/program/core-declarations.d.ts.map +1 -0
- package/dist/program/core-declarations.js +126 -0
- package/dist/program/core-declarations.js.map +1 -0
- package/dist/program/creation-cases/authoritative-type-roots.test.d.ts +6 -0
- package/dist/program/creation-cases/authoritative-type-roots.test.d.ts.map +1 -0
- package/dist/program/creation-cases/authoritative-type-roots.test.js +136 -0
- package/dist/program/creation-cases/authoritative-type-roots.test.js.map +1 -0
- package/dist/program/creation-cases/compiler-options.test.d.ts +5 -0
- package/dist/program/creation-cases/compiler-options.test.d.ts.map +1 -0
- package/dist/program/creation-cases/compiler-options.test.js +77 -0
- package/dist/program/creation-cases/compiler-options.test.js.map +1 -0
- package/dist/program/creation-cases/core-type-checking.test.d.ts +6 -0
- package/dist/program/creation-cases/core-type-checking.test.d.ts.map +1 -0
- package/dist/program/creation-cases/core-type-checking.test.js +66 -0
- package/dist/program/creation-cases/core-type-checking.test.js.map +1 -0
- package/dist/program/creation-cases/js-surface-globals.test.d.ts +6 -0
- package/dist/program/creation-cases/js-surface-globals.test.d.ts.map +1 -0
- package/dist/program/creation-cases/js-surface-globals.test.js +236 -0
- package/dist/program/creation-cases/js-surface-globals.test.js.map +1 -0
- package/dist/program/creation-cases/module-bindings.test.d.ts +2 -0
- package/dist/program/creation-cases/module-bindings.test.d.ts.map +1 -0
- package/dist/program/creation-cases/module-bindings.test.js +253 -0
- package/dist/program/creation-cases/module-bindings.test.js.map +1 -0
- package/dist/program/creation-cases/package-resolution.test.d.ts +6 -0
- package/dist/program/creation-cases/package-resolution.test.d.ts.map +1 -0
- package/dist/program/creation-cases/package-resolution.test.js +116 -0
- package/dist/program/creation-cases/package-resolution.test.js.map +1 -0
- package/dist/program/creation-cases/surface-isolation.test.d.ts +6 -0
- package/dist/program/creation-cases/surface-isolation.test.d.ts.map +1 -0
- package/dist/program/creation-cases/surface-isolation.test.js +196 -0
- package/dist/program/creation-cases/surface-isolation.test.js.map +1 -0
- package/dist/program/creation-cases/test-package-helpers.d.ts +6 -0
- package/dist/program/creation-cases/test-package-helpers.d.ts.map +1 -0
- package/dist/program/creation-cases/test-package-helpers.js +26 -0
- package/dist/program/creation-cases/test-package-helpers.js.map +1 -0
- package/dist/program/creation.d.ts +3 -14
- package/dist/program/creation.d.ts.map +1 -1
- package/dist/program/creation.js +3 -780
- package/dist/program/creation.js.map +1 -1
- package/dist/program/creation.test.d.ts +10 -2
- package/dist/program/creation.test.d.ts.map +1 -1
- package/dist/program/creation.test.js +10 -929
- package/dist/program/creation.test.js.map +1 -1
- package/dist/program/declaration-module-aliases.d.ts +13 -0
- package/dist/program/declaration-module-aliases.d.ts.map +1 -0
- package/dist/program/declaration-module-aliases.js +144 -0
- package/dist/program/declaration-module-aliases.js.map +1 -0
- package/dist/program/dependency-graph.d.ts +3 -1
- package/dist/program/dependency-graph.d.ts.map +1 -1
- package/dist/program/dependency-graph.js +211 -23
- package/dist/program/dependency-graph.js.map +1 -1
- package/dist/program/dependency-graph.test.js +307 -85
- package/dist/program/dependency-graph.test.js.map +1 -1
- package/dist/program/diagnostics.d.ts +1 -1
- package/dist/program/diagnostics.d.ts.map +1 -1
- package/dist/program/diagnostics.js +2 -48
- package/dist/program/diagnostics.js.map +1 -1
- package/dist/program/diagnostics.test.js +9 -24
- package/dist/program/diagnostics.test.js.map +1 -1
- package/dist/program/dotnet-binding-payload.d.ts +12 -0
- package/dist/program/dotnet-binding-payload.d.ts.map +1 -0
- package/dist/program/dotnet-binding-payload.js +71 -0
- package/dist/program/dotnet-binding-payload.js.map +1 -0
- package/dist/program/fixture-fast-coverage.test.d.ts +2 -0
- package/dist/program/fixture-fast-coverage.test.d.ts.map +1 -0
- package/dist/program/fixture-fast-coverage.test.js +225 -0
- package/dist/program/fixture-fast-coverage.test.js.map +1 -0
- package/dist/program/index.d.ts +1 -1
- package/dist/program/index.d.ts.map +1 -1
- package/dist/program/index.js +1 -1
- package/dist/program/index.js.map +1 -1
- package/dist/program/json-deserialize-overload-resolution.test.d.ts +2 -0
- package/dist/program/json-deserialize-overload-resolution.test.d.ts.map +1 -0
- package/dist/program/json-deserialize-overload-resolution.test.js +57 -0
- package/dist/program/json-deserialize-overload-resolution.test.js.map +1 -0
- package/dist/program/metadata.d.ts.map +1 -1
- package/dist/program/metadata.js +24 -8
- package/dist/program/metadata.js.map +1 -1
- package/dist/program/metadata.test.js +30 -82
- package/dist/program/metadata.test.js.map +1 -1
- package/dist/program/module-resolution.d.ts +29 -0
- package/dist/program/module-resolution.d.ts.map +1 -0
- package/dist/program/module-resolution.js +257 -0
- package/dist/program/module-resolution.js.map +1 -0
- package/dist/program/package-roots.d.ts +3 -1
- package/dist/program/package-roots.d.ts.map +1 -1
- package/dist/program/package-roots.js +159 -21
- package/dist/program/package-roots.js.map +1 -1
- package/dist/program/package-roots.test.js +81 -25
- package/dist/program/package-roots.test.js.map +1 -1
- package/dist/program/program-assembly.d.ts +12 -0
- package/dist/program/program-assembly.d.ts.map +1 -0
- package/dist/program/program-assembly.js +409 -0
- package/dist/program/program-assembly.js.map +1 -0
- package/dist/program/program-factory.d.ts +9 -0
- package/dist/program/program-factory.d.ts.map +1 -0
- package/dist/program/program-factory.js +9 -0
- package/dist/program/program-factory.js.map +1 -0
- package/dist/program/program-input-discovery.d.ts +19 -0
- package/dist/program/program-input-discovery.d.ts.map +1 -0
- package/dist/program/program-input-discovery.js +379 -0
- package/dist/program/program-input-discovery.js.map +1 -0
- package/dist/program/program-input-discovery.test.d.ts +2 -0
- package/dist/program/program-input-discovery.test.d.ts.map +1 -0
- package/dist/program/program-input-discovery.test.js +342 -0
- package/dist/program/program-input-discovery.test.js.map +1 -0
- package/dist/program/source-binding-imports.d.ts +7 -0
- package/dist/program/source-binding-imports.d.ts.map +1 -0
- package/dist/program/source-binding-imports.js +80 -0
- package/dist/program/source-binding-imports.js.map +1 -0
- package/dist/program/source-binding-imports.test.d.ts +2 -0
- package/dist/program/source-binding-imports.test.d.ts.map +1 -0
- package/dist/program/source-binding-imports.test.js +58 -0
- package/dist/program/source-binding-imports.test.js.map +1 -0
- package/dist/program/source-file-identity.d.ts +13 -0
- package/dist/program/source-file-identity.d.ts.map +1 -0
- package/dist/program/source-file-identity.js +127 -0
- package/dist/program/source-file-identity.js.map +1 -0
- package/dist/program/source-package-metadata.d.ts +14 -0
- package/dist/program/source-package-metadata.d.ts.map +1 -0
- package/dist/program/source-package-metadata.js +227 -0
- package/dist/program/source-package-metadata.js.map +1 -0
- package/dist/program/tsbindgen-instance-receiver-substitution.test.d.ts +2 -0
- package/dist/program/tsbindgen-instance-receiver-substitution.test.d.ts.map +1 -0
- package/dist/program/tsbindgen-instance-receiver-substitution.test.js +194 -0
- package/dist/program/tsbindgen-instance-receiver-substitution.test.js.map +1 -0
- package/dist/program/types.d.ts +3 -2
- package/dist/program/types.d.ts.map +1 -1
- package/dist/program/xunit-equal-overload-resolution.test.d.ts +2 -0
- package/dist/program/xunit-equal-overload-resolution.test.d.ts.map +1 -0
- package/dist/program/xunit-equal-overload-resolution.test.js +205 -0
- package/dist/program/xunit-equal-overload-resolution.test.js.map +1 -0
- package/dist/program.d.ts +1 -1
- package/dist/program.d.ts.map +1 -1
- package/dist/resolver/clr-bindings-package-resolution.d.ts +28 -0
- package/dist/resolver/clr-bindings-package-resolution.d.ts.map +1 -0
- package/dist/resolver/clr-bindings-package-resolution.js +120 -0
- package/dist/resolver/clr-bindings-package-resolution.js.map +1 -0
- package/dist/resolver/clr-bindings-resolve-logic.d.ts +40 -0
- package/dist/resolver/clr-bindings-resolve-logic.d.ts.map +1 -0
- package/dist/resolver/clr-bindings-resolve-logic.js +192 -0
- package/dist/resolver/clr-bindings-resolve-logic.js.map +1 -0
- package/dist/resolver/clr-bindings-resolver.d.ts +9 -69
- package/dist/resolver/clr-bindings-resolver.d.ts.map +1 -1
- package/dist/resolver/clr-bindings-resolver.js +4 -436
- package/dist/resolver/clr-bindings-resolver.js.map +1 -1
- package/dist/resolver/import-resolution.d.ts +3 -0
- package/dist/resolver/import-resolution.d.ts.map +1 -1
- package/dist/resolver/import-resolution.js +120 -33
- package/dist/resolver/import-resolution.js.map +1 -1
- package/dist/resolver/source-package-resolution.d.ts +18 -0
- package/dist/resolver/source-package-resolution.d.ts.map +1 -1
- package/dist/resolver/source-package-resolution.js +141 -14
- package/dist/resolver/source-package-resolution.js.map +1 -1
- package/dist/resolver/source-package-resolution.test.js +27 -52
- package/dist/resolver/source-package-resolution.test.js.map +1 -1
- package/dist/resolver-cases/namespace-and-classname.test.d.ts +5 -0
- package/dist/resolver-cases/namespace-and-classname.test.d.ts.map +1 -0
- package/dist/resolver-cases/namespace-and-classname.test.js +32 -0
- package/dist/resolver-cases/namespace-and-classname.test.js.map +1 -0
- package/dist/resolver-cases/resolve-import.test.d.ts +5 -0
- package/dist/resolver-cases/resolve-import.test.d.ts.map +1 -0
- package/dist/resolver-cases/resolve-import.test.js +460 -0
- package/dist/resolver-cases/resolve-import.test.js.map +1 -0
- package/dist/resolver.test.d.ts +2 -4
- package/dist/resolver.test.d.ts.map +1 -1
- package/dist/resolver.test.js +2 -289
- package/dist/resolver.test.js.map +1 -1
- package/dist/surface/profiles.d.ts +1 -1
- package/dist/surface/profiles.d.ts.map +1 -1
- package/dist/surface/profiles.js +146 -53
- package/dist/surface/profiles.js.map +1 -1
- package/dist/surface/profiles.test.js +97 -108
- package/dist/surface/profiles.test.js.map +1 -1
- package/dist/testing/filesystem-fixtures.d.ts +7 -0
- package/dist/testing/filesystem-fixtures.d.ts.map +1 -0
- package/dist/testing/filesystem-fixtures.js +80 -0
- package/dist/testing/filesystem-fixtures.js.map +1 -0
- package/dist/types/diagnostic.d.ts +1 -1
- package/dist/types/diagnostic.d.ts.map +1 -1
- package/dist/types/diagnostic.js.map +1 -1
- package/dist/validation/contextual-type-analysis.d.ts +12 -0
- package/dist/validation/contextual-type-analysis.d.ts.map +1 -0
- package/dist/validation/contextual-type-analysis.js +11 -0
- package/dist/validation/contextual-type-analysis.js.map +1 -0
- package/dist/validation/contextual-type-checks.d.ts +35 -0
- package/dist/validation/contextual-type-checks.d.ts.map +1 -0
- package/dist/validation/contextual-type-checks.js +214 -0
- package/dist/validation/contextual-type-checks.js.map +1 -0
- package/dist/validation/exports.d.ts.map +1 -1
- package/dist/validation/exports.js +14 -15
- package/dist/validation/exports.js.map +1 -1
- package/dist/validation/features-cases/promise-chaining.test.d.ts +2 -0
- package/dist/validation/features-cases/promise-chaining.test.d.ts.map +1 -0
- package/dist/validation/features-cases/promise-chaining.test.js +113 -0
- package/dist/validation/features-cases/promise-chaining.test.js.map +1 -0
- package/dist/validation/features-cases/test-helpers.d.ts +11 -0
- package/dist/validation/features-cases/test-helpers.d.ts.map +1 -0
- package/dist/validation/features-cases/test-helpers.js +125 -0
- package/dist/validation/features-cases/test-helpers.js.map +1 -0
- package/dist/validation/features-cases/tsn2001-unsupported-syntax.test.d.ts +2 -0
- package/dist/validation/features-cases/tsn2001-unsupported-syntax.test.d.ts.map +1 -0
- package/dist/validation/features-cases/tsn2001-unsupported-syntax.test.js +158 -0
- package/dist/validation/features-cases/tsn2001-unsupported-syntax.test.js.map +1 -0
- package/dist/validation/features-cases/tsn5001-function-length.test.d.ts +2 -0
- package/dist/validation/features-cases/tsn5001-function-length.test.d.ts.map +1 -0
- package/dist/validation/features-cases/tsn5001-function-length.test.js +104 -0
- package/dist/validation/features-cases/tsn5001-function-length.test.js.map +1 -0
- package/dist/validation/features.d.ts.map +1 -1
- package/dist/validation/features.js +223 -0
- package/dist/validation/features.js.map +1 -1
- package/dist/validation/features.test.d.ts +3 -1
- package/dist/validation/features.test.d.ts.map +1 -1
- package/dist/validation/features.test.js +3 -386
- package/dist/validation/features.test.js.map +1 -1
- package/dist/validation/imports.d.ts.map +1 -1
- package/dist/validation/imports.js +37 -3
- package/dist/validation/imports.js.map +1 -1
- package/dist/validation/imports.test.js +45 -9
- package/dist/validation/imports.test.js.map +1 -1
- package/dist/validation/static-safety-arrow-rules.d.ts +11 -0
- package/dist/validation/static-safety-arrow-rules.d.ts.map +1 -0
- package/dist/validation/static-safety-arrow-rules.js +54 -0
- package/dist/validation/static-safety-arrow-rules.js.map +1 -0
- package/dist/validation/static-safety-dictionary-keys.d.ts +10 -0
- package/dist/validation/static-safety-dictionary-keys.d.ts.map +1 -0
- package/dist/validation/static-safety-dictionary-keys.js +32 -0
- package/dist/validation/static-safety-dictionary-keys.js.map +1 -0
- package/dist/validation/static-safety-rules.d.ts +27 -0
- package/dist/validation/static-safety-rules.d.ts.map +1 -0
- package/dist/validation/static-safety-rules.js +231 -0
- package/dist/validation/static-safety-rules.js.map +1 -0
- package/dist/validation/static-safety.d.ts +4 -7
- package/dist/validation/static-safety.d.ts.map +1 -1
- package/dist/validation/static-safety.js +3 -673
- package/dist/validation/static-safety.js.map +1 -1
- package/dist/validation/synthesis-eligibility.d.ts +31 -0
- package/dist/validation/synthesis-eligibility.d.ts.map +1 -0
- package/dist/validation/synthesis-eligibility.js +161 -0
- package/dist/validation/synthesis-eligibility.js.map +1 -0
- package/dist/validator-cases/any-and-object-literals.test.d.ts +10 -0
- package/dist/validator-cases/any-and-object-literals.test.d.ts.map +1 -0
- package/dist/validator-cases/any-and-object-literals.test.js +271 -0
- package/dist/validator-cases/any-and-object-literals.test.js.map +1 -0
- package/dist/validator-cases/generic-validation.test.d.ts +11 -0
- package/dist/validator-cases/generic-validation.test.d.ts.map +1 -0
- package/dist/validator-cases/generic-validation.test.js +282 -0
- package/dist/validator-cases/generic-validation.test.js.map +1 -0
- package/dist/validator-cases/helpers.d.ts +9 -0
- package/dist/validator-cases/helpers.d.ts.map +1 -0
- package/dist/validator-cases/helpers.js +46 -0
- package/dist/validator-cases/helpers.js.map +1 -0
- package/dist/validator-cases/parameters-and-dict-keys.test.d.ts +10 -0
- package/dist/validator-cases/parameters-and-dict-keys.test.d.ts.map +1 -0
- package/dist/validator-cases/parameters-and-dict-keys.test.js +280 -0
- package/dist/validator-cases/parameters-and-dict-keys.test.js.map +1 -0
- package/dist/validator-cases/utility-types.test.d.ts +12 -0
- package/dist/validator-cases/utility-types.test.d.ts.map +1 -0
- package/dist/validator-cases/utility-types.test.js +323 -0
- package/dist/validator-cases/utility-types.test.js.map +1 -0
- package/dist/validator-maximus-cases/array-and-literal-inference.test.d.ts +2 -0
- package/dist/validator-maximus-cases/array-and-literal-inference.test.d.ts.map +1 -0
- package/dist/validator-maximus-cases/array-and-literal-inference.test.js +221 -0
- package/dist/validator-maximus-cases/array-and-literal-inference.test.js.map +1 -0
- package/dist/validator-maximus-cases/deterministic-typing.test.d.ts +2 -0
- package/dist/validator-maximus-cases/deterministic-typing.test.d.ts.map +1 -0
- package/dist/validator-maximus-cases/deterministic-typing.test.js +432 -0
- package/dist/validator-maximus-cases/deterministic-typing.test.js.map +1 -0
- package/dist/validator-maximus-cases/dictionary-and-object-literal.test.d.ts +2 -0
- package/dist/validator-maximus-cases/dictionary-and-object-literal.test.d.ts.map +1 -0
- package/dist/validator-maximus-cases/dictionary-and-object-literal.test.js +273 -0
- package/dist/validator-maximus-cases/dictionary-and-object-literal.test.js.map +1 -0
- package/dist/validator-maximus-cases/feature-gating.test.d.ts +2 -0
- package/dist/validator-maximus-cases/feature-gating.test.d.ts.map +1 -0
- package/dist/validator-maximus-cases/feature-gating.test.js +181 -0
- package/dist/validator-maximus-cases/feature-gating.test.js.map +1 -0
- package/dist/validator-maximus-cases/generic-function-values.test.d.ts +2 -0
- package/dist/validator-maximus-cases/generic-function-values.test.d.ts.map +1 -0
- package/dist/validator-maximus-cases/generic-function-values.test.js +346 -0
- package/dist/validator-maximus-cases/generic-function-values.test.js.map +1 -0
- package/dist/validator-maximus-cases/helpers.d.ts +9 -0
- package/dist/validator-maximus-cases/helpers.d.ts.map +1 -0
- package/dist/validator-maximus-cases/helpers.js +113 -0
- package/dist/validator-maximus-cases/helpers.js.map +1 -0
- package/dist/validator-maximus-cases/type-syntax.test.d.ts +2 -0
- package/dist/validator-maximus-cases/type-syntax.test.d.ts.map +1 -0
- package/dist/validator-maximus-cases/type-syntax.test.js +157 -0
- package/dist/validator-maximus-cases/type-syntax.test.js.map +1 -0
- package/dist/validator.maximus.test.d.ts +6 -1
- package/dist/validator.maximus.test.d.ts.map +1 -1
- package/dist/validator.maximus.test.js +6 -1417
- package/dist/validator.maximus.test.js.map +1 -1
- package/dist/validator.test.d.ts +4 -10
- package/dist/validator.test.d.ts.map +1 -1
- package/dist/validator.test.js +4 -1086
- package/dist/validator.test.js.map +1 -1
- package/package.json +3 -3
|
@@ -1,9 +1,15 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* Yield Lowering Pass
|
|
2
|
+
* Yield Lowering Pass (facade)
|
|
3
3
|
*
|
|
4
4
|
* Transforms yield expressions in generator functions into IrYieldStatement nodes.
|
|
5
5
|
* This pass runs after IR building and before numeric proof pass.
|
|
6
6
|
*
|
|
7
|
+
* Implementation is split across:
|
|
8
|
+
* - yield-lowering-helpers.ts — shared types, utilities, yield detection/analysis
|
|
9
|
+
* - yield-expression-lowering.ts — expression-tree yield lowering
|
|
10
|
+
* - yield-statement-lowering.ts — generator-context statement lowering
|
|
11
|
+
* - yield-module-processing.ts — non-generator recursion, class & module processing
|
|
12
|
+
*
|
|
7
13
|
* Supported patterns:
|
|
8
14
|
* - `yield expr;` → IrYieldStatement with no receiveTarget
|
|
9
15
|
* - `const x = yield expr;` → IrYieldStatement with receiveTarget = identifierPattern
|
|
@@ -24,1423 +30,7 @@
|
|
|
24
30
|
* Unsupported patterns (emit TSN6101 diagnostic):
|
|
25
31
|
* - assignment target forms that cannot be lowered as a deterministic l-value
|
|
26
32
|
*/
|
|
27
|
-
import {
|
|
28
|
-
/**
|
|
29
|
-
* Create a source location for a module
|
|
30
|
-
*/
|
|
31
|
-
const moduleLocation = (ctx) => ({
|
|
32
|
-
file: ctx.filePath,
|
|
33
|
-
line: 1,
|
|
34
|
-
column: 1,
|
|
35
|
-
length: 1,
|
|
36
|
-
});
|
|
37
|
-
/**
|
|
38
|
-
* Check if an expression contains a yield expression anywhere in its tree.
|
|
39
|
-
*/
|
|
40
|
-
const containsYield = (expr) => {
|
|
41
|
-
switch (expr.kind) {
|
|
42
|
-
case "yield":
|
|
43
|
-
return true;
|
|
44
|
-
case "binary":
|
|
45
|
-
case "logical":
|
|
46
|
-
return containsYield(expr.left) || containsYield(expr.right);
|
|
47
|
-
case "unary":
|
|
48
|
-
case "update":
|
|
49
|
-
case "await":
|
|
50
|
-
case "spread":
|
|
51
|
-
return containsYield(expr.expression);
|
|
52
|
-
case "conditional":
|
|
53
|
-
return (containsYield(expr.condition) ||
|
|
54
|
-
containsYield(expr.whenTrue) ||
|
|
55
|
-
containsYield(expr.whenFalse));
|
|
56
|
-
case "assignment":
|
|
57
|
-
return ((expr.left.kind !== "identifierPattern" &&
|
|
58
|
-
expr.left.kind !== "arrayPattern" &&
|
|
59
|
-
expr.left.kind !== "objectPattern" &&
|
|
60
|
-
containsYield(expr.left)) ||
|
|
61
|
-
containsYield(expr.right));
|
|
62
|
-
case "memberAccess":
|
|
63
|
-
return (containsYield(expr.object) ||
|
|
64
|
-
(typeof expr.property !== "string" && containsYield(expr.property)));
|
|
65
|
-
case "call":
|
|
66
|
-
case "new":
|
|
67
|
-
return (containsYield(expr.callee) ||
|
|
68
|
-
expr.arguments.some((a) => containsYield(a)) ||
|
|
69
|
-
(expr.kind === "call" &&
|
|
70
|
-
expr.dynamicImportNamespace !== undefined &&
|
|
71
|
-
containsYield(expr.dynamicImportNamespace)));
|
|
72
|
-
case "array":
|
|
73
|
-
return expr.elements.some((e) => e !== undefined && containsYield(e));
|
|
74
|
-
case "object":
|
|
75
|
-
return expr.properties.some((p) => {
|
|
76
|
-
if (p.kind === "property") {
|
|
77
|
-
return ((typeof p.key !== "string" && containsYield(p.key)) ||
|
|
78
|
-
containsYield(p.value));
|
|
79
|
-
}
|
|
80
|
-
return containsYield(p.expression);
|
|
81
|
-
});
|
|
82
|
-
case "templateLiteral":
|
|
83
|
-
return expr.expressions.some((e) => containsYield(e));
|
|
84
|
-
case "arrowFunction":
|
|
85
|
-
case "functionExpression":
|
|
86
|
-
// Don't recurse into nested functions - they have their own generator context
|
|
87
|
-
return false;
|
|
88
|
-
default:
|
|
89
|
-
return false;
|
|
90
|
-
}
|
|
91
|
-
};
|
|
92
|
-
/**
|
|
93
|
-
* Count the number of yield expressions in an expression tree.
|
|
94
|
-
*/
|
|
95
|
-
const countYields = (expr) => {
|
|
96
|
-
switch (expr.kind) {
|
|
97
|
-
case "yield":
|
|
98
|
-
return 1 + (expr.expression ? countYields(expr.expression) : 0);
|
|
99
|
-
case "binary":
|
|
100
|
-
case "logical":
|
|
101
|
-
return countYields(expr.left) + countYields(expr.right);
|
|
102
|
-
case "unary":
|
|
103
|
-
case "update":
|
|
104
|
-
case "await":
|
|
105
|
-
case "spread":
|
|
106
|
-
return countYields(expr.expression);
|
|
107
|
-
case "conditional":
|
|
108
|
-
return (countYields(expr.condition) +
|
|
109
|
-
countYields(expr.whenTrue) +
|
|
110
|
-
countYields(expr.whenFalse));
|
|
111
|
-
case "assignment":
|
|
112
|
-
return ((expr.left.kind !== "identifierPattern" &&
|
|
113
|
-
expr.left.kind !== "arrayPattern" &&
|
|
114
|
-
expr.left.kind !== "objectPattern"
|
|
115
|
-
? countYields(expr.left)
|
|
116
|
-
: 0) + countYields(expr.right));
|
|
117
|
-
case "memberAccess":
|
|
118
|
-
return (countYields(expr.object) +
|
|
119
|
-
(typeof expr.property !== "string" ? countYields(expr.property) : 0));
|
|
120
|
-
case "call":
|
|
121
|
-
case "new":
|
|
122
|
-
return (countYields(expr.callee) +
|
|
123
|
-
expr.arguments.reduce((sum, a) => sum + countYields(a), 0) +
|
|
124
|
-
(expr.kind === "call" && expr.dynamicImportNamespace
|
|
125
|
-
? countYields(expr.dynamicImportNamespace)
|
|
126
|
-
: 0));
|
|
127
|
-
case "array":
|
|
128
|
-
return expr.elements.reduce((sum, e) => sum + (e !== undefined ? countYields(e) : 0), 0);
|
|
129
|
-
case "object":
|
|
130
|
-
return expr.properties.reduce((sum, p) => {
|
|
131
|
-
if (p.kind === "property") {
|
|
132
|
-
return (sum +
|
|
133
|
-
(typeof p.key !== "string" ? countYields(p.key) : 0) +
|
|
134
|
-
countYields(p.value));
|
|
135
|
-
}
|
|
136
|
-
return sum + countYields(p.expression);
|
|
137
|
-
}, 0);
|
|
138
|
-
case "templateLiteral":
|
|
139
|
-
return expr.expressions.reduce((sum, e) => sum + countYields(e), 0);
|
|
140
|
-
case "arrowFunction":
|
|
141
|
-
case "functionExpression":
|
|
142
|
-
return 0;
|
|
143
|
-
default:
|
|
144
|
-
return 0;
|
|
145
|
-
}
|
|
146
|
-
};
|
|
147
|
-
/**
|
|
148
|
-
* Create an IrYieldStatement from a yield expression.
|
|
149
|
-
*/
|
|
150
|
-
const createYieldStatement = (yieldExpr, receiveTarget, receivedType) => ({
|
|
151
|
-
kind: "yieldStatement",
|
|
152
|
-
output: yieldExpr.expression,
|
|
153
|
-
delegate: yieldExpr.delegate,
|
|
154
|
-
receiveTarget,
|
|
155
|
-
receivedType,
|
|
156
|
-
});
|
|
157
|
-
const toReceivePattern = (target) => {
|
|
158
|
-
if (target.kind === "identifierPattern" ||
|
|
159
|
-
target.kind === "arrayPattern" ||
|
|
160
|
-
target.kind === "objectPattern") {
|
|
161
|
-
return target;
|
|
162
|
-
}
|
|
163
|
-
if (target.kind === "identifier") {
|
|
164
|
-
return { kind: "identifierPattern", name: target.name };
|
|
165
|
-
}
|
|
166
|
-
return undefined;
|
|
167
|
-
};
|
|
168
|
-
/**
|
|
169
|
-
* Create an IrGeneratorReturnStatement from a return statement's expression.
|
|
170
|
-
* This captures the return value for generators with TReturn.
|
|
171
|
-
*/
|
|
172
|
-
const createGeneratorReturnStatement = (expression) => ({
|
|
173
|
-
kind: "generatorReturnStatement",
|
|
174
|
-
expression,
|
|
175
|
-
});
|
|
176
|
-
/**
|
|
177
|
-
* Emit diagnostic for unsupported yield position.
|
|
178
|
-
*/
|
|
179
|
-
const emitUnsupportedYieldDiagnostic = (ctx, position, location) => {
|
|
180
|
-
ctx.diagnostics.push(createDiagnostic("TSN6101", "error", `Yield expression in ${position} is not supported`, location ?? moduleLocation(ctx), "Extract yield to a separate statement: `const result = yield expr; use(result);`"));
|
|
181
|
-
};
|
|
182
|
-
const allocateYieldTempName = (ctx) => {
|
|
183
|
-
ctx.yieldTempCounter += 1;
|
|
184
|
-
return `__tsonic_yield_${ctx.yieldTempCounter}`;
|
|
185
|
-
};
|
|
186
|
-
const createTempVariableDeclaration = (name, initializer, inferredType) => ({
|
|
187
|
-
kind: "variableDeclaration",
|
|
188
|
-
declarationKind: "const",
|
|
189
|
-
isExported: false,
|
|
190
|
-
declarations: [
|
|
191
|
-
{
|
|
192
|
-
kind: "variableDeclarator",
|
|
193
|
-
name: { kind: "identifierPattern", name },
|
|
194
|
-
type: inferredType,
|
|
195
|
-
initializer,
|
|
196
|
-
},
|
|
197
|
-
],
|
|
198
|
-
});
|
|
199
|
-
const lowerMemberAccessAssignmentWithYields = (assignment, ctx, positionLabels) => {
|
|
200
|
-
if (assignment.left.kind !== "memberAccess") {
|
|
201
|
-
return undefined;
|
|
202
|
-
}
|
|
203
|
-
const loweredObject = lowerExpressionWithYields(assignment.left.object, ctx, positionLabels.object, assignment.left.object.inferredType);
|
|
204
|
-
if (!loweredObject) {
|
|
205
|
-
return undefined;
|
|
206
|
-
}
|
|
207
|
-
const leadingStatements = [...loweredObject.prelude];
|
|
208
|
-
const objectTempName = allocateYieldTempName(ctx);
|
|
209
|
-
leadingStatements.push(createTempVariableDeclaration(objectTempName, loweredObject.expression, loweredObject.expression.inferredType));
|
|
210
|
-
let loweredProperty = assignment.left.property;
|
|
211
|
-
if (typeof assignment.left.property !== "string") {
|
|
212
|
-
const loweredPropertyExpr = lowerExpressionWithYields(assignment.left.property, ctx, positionLabels.property, assignment.left.property.inferredType);
|
|
213
|
-
if (!loweredPropertyExpr) {
|
|
214
|
-
return undefined;
|
|
215
|
-
}
|
|
216
|
-
leadingStatements.push(...loweredPropertyExpr.prelude);
|
|
217
|
-
const propertyTempName = allocateYieldTempName(ctx);
|
|
218
|
-
leadingStatements.push(createTempVariableDeclaration(propertyTempName, loweredPropertyExpr.expression, loweredPropertyExpr.expression.inferredType));
|
|
219
|
-
loweredProperty = { kind: "identifier", name: propertyTempName };
|
|
220
|
-
}
|
|
221
|
-
let loweredRight = assignment.right;
|
|
222
|
-
if (assignment.right.kind === "yield" && !assignment.right.delegate) {
|
|
223
|
-
const receiveTempName = allocateYieldTempName(ctx);
|
|
224
|
-
leadingStatements.push(createYieldStatement(assignment.right, { kind: "identifierPattern", name: receiveTempName }, assignment.right.inferredType));
|
|
225
|
-
loweredRight = { kind: "identifier", name: receiveTempName };
|
|
226
|
-
}
|
|
227
|
-
else if (containsYield(assignment.right)) {
|
|
228
|
-
const loweredRightExpr = lowerExpressionWithYields(assignment.right, ctx, positionLabels.right, assignment.right.inferredType);
|
|
229
|
-
if (!loweredRightExpr) {
|
|
230
|
-
return undefined;
|
|
231
|
-
}
|
|
232
|
-
leadingStatements.push(...loweredRightExpr.prelude);
|
|
233
|
-
loweredRight = loweredRightExpr.expression;
|
|
234
|
-
}
|
|
235
|
-
return {
|
|
236
|
-
leadingStatements,
|
|
237
|
-
loweredAssignment: {
|
|
238
|
-
...assignment,
|
|
239
|
-
left: {
|
|
240
|
-
...assignment.left,
|
|
241
|
-
object: { kind: "identifier", name: objectTempName },
|
|
242
|
-
property: loweredProperty,
|
|
243
|
-
},
|
|
244
|
-
right: loweredRight,
|
|
245
|
-
},
|
|
246
|
-
};
|
|
247
|
-
};
|
|
248
|
-
/**
|
|
249
|
-
* Lower yield expressions that appear inside larger expression trees into
|
|
250
|
-
* leading IrYieldStatement nodes plus a rewritten expression that references
|
|
251
|
-
* temp identifiers.
|
|
252
|
-
*
|
|
253
|
-
* This preserves left-to-right evaluation order for supported expression forms.
|
|
254
|
-
* Unsupported forms emit TSN6101 and return undefined.
|
|
255
|
-
*/
|
|
256
|
-
const lowerExpressionWithYields = (expression, ctx, position, expectedType) => {
|
|
257
|
-
const lower = (expr) => {
|
|
258
|
-
if (!containsYield(expr)) {
|
|
259
|
-
return { prelude: [], expression: expr };
|
|
260
|
-
}
|
|
261
|
-
switch (expr.kind) {
|
|
262
|
-
case "yield": {
|
|
263
|
-
const tempName = allocateYieldTempName(ctx);
|
|
264
|
-
return {
|
|
265
|
-
prelude: [
|
|
266
|
-
createYieldStatement(expr, { kind: "identifierPattern", name: tempName }, expr.inferredType),
|
|
267
|
-
],
|
|
268
|
-
expression: { kind: "identifier", name: tempName },
|
|
269
|
-
};
|
|
270
|
-
}
|
|
271
|
-
case "unary":
|
|
272
|
-
case "update":
|
|
273
|
-
case "await":
|
|
274
|
-
case "spread":
|
|
275
|
-
case "numericNarrowing":
|
|
276
|
-
case "typeAssertion":
|
|
277
|
-
case "asinterface":
|
|
278
|
-
case "trycast": {
|
|
279
|
-
const lowered = lower(expr.expression);
|
|
280
|
-
if (!lowered)
|
|
281
|
-
return undefined;
|
|
282
|
-
return {
|
|
283
|
-
prelude: lowered.prelude,
|
|
284
|
-
expression: {
|
|
285
|
-
...expr,
|
|
286
|
-
expression: lowered.expression,
|
|
287
|
-
},
|
|
288
|
-
};
|
|
289
|
-
}
|
|
290
|
-
case "stackalloc": {
|
|
291
|
-
const loweredSize = lower(expr.size);
|
|
292
|
-
if (!loweredSize)
|
|
293
|
-
return undefined;
|
|
294
|
-
return {
|
|
295
|
-
prelude: loweredSize.prelude,
|
|
296
|
-
expression: {
|
|
297
|
-
...expr,
|
|
298
|
-
size: loweredSize.expression,
|
|
299
|
-
},
|
|
300
|
-
};
|
|
301
|
-
}
|
|
302
|
-
case "binary":
|
|
303
|
-
case "logical": {
|
|
304
|
-
const loweredLeft = lower(expr.left);
|
|
305
|
-
if (!loweredLeft)
|
|
306
|
-
return undefined;
|
|
307
|
-
const loweredRight = lower(expr.right);
|
|
308
|
-
if (!loweredRight)
|
|
309
|
-
return undefined;
|
|
310
|
-
return {
|
|
311
|
-
prelude: [...loweredLeft.prelude, ...loweredRight.prelude],
|
|
312
|
-
expression: {
|
|
313
|
-
...expr,
|
|
314
|
-
left: loweredLeft.expression,
|
|
315
|
-
right: loweredRight.expression,
|
|
316
|
-
},
|
|
317
|
-
};
|
|
318
|
-
}
|
|
319
|
-
case "assignment": {
|
|
320
|
-
if (expr.left.kind !== "identifierPattern" &&
|
|
321
|
-
expr.left.kind !== "arrayPattern" &&
|
|
322
|
-
expr.left.kind !== "objectPattern" &&
|
|
323
|
-
containsYield(expr.left)) {
|
|
324
|
-
if (expr.left.kind !== "memberAccess") {
|
|
325
|
-
emitUnsupportedYieldDiagnostic(ctx, `${position} assignment target`);
|
|
326
|
-
return undefined;
|
|
327
|
-
}
|
|
328
|
-
const loweredObject = lower(expr.left.object);
|
|
329
|
-
if (!loweredObject)
|
|
330
|
-
return undefined;
|
|
331
|
-
let loweredProperty = expr.left.property;
|
|
332
|
-
let propertyPrelude = [];
|
|
333
|
-
if (typeof expr.left.property !== "string") {
|
|
334
|
-
const loweredPropertyExpr = lower(expr.left.property);
|
|
335
|
-
if (!loweredPropertyExpr)
|
|
336
|
-
return undefined;
|
|
337
|
-
loweredProperty = loweredPropertyExpr.expression;
|
|
338
|
-
propertyPrelude = loweredPropertyExpr.prelude;
|
|
339
|
-
}
|
|
340
|
-
const loweredRight = lower(expr.right);
|
|
341
|
-
if (!loweredRight)
|
|
342
|
-
return undefined;
|
|
343
|
-
return {
|
|
344
|
-
prelude: [
|
|
345
|
-
...loweredObject.prelude,
|
|
346
|
-
...propertyPrelude,
|
|
347
|
-
...loweredRight.prelude,
|
|
348
|
-
],
|
|
349
|
-
expression: {
|
|
350
|
-
...expr,
|
|
351
|
-
left: {
|
|
352
|
-
...expr.left,
|
|
353
|
-
object: loweredObject.expression,
|
|
354
|
-
property: loweredProperty,
|
|
355
|
-
},
|
|
356
|
-
right: loweredRight.expression,
|
|
357
|
-
},
|
|
358
|
-
};
|
|
359
|
-
}
|
|
360
|
-
const loweredRight = lower(expr.right);
|
|
361
|
-
if (!loweredRight)
|
|
362
|
-
return undefined;
|
|
363
|
-
return {
|
|
364
|
-
prelude: loweredRight.prelude,
|
|
365
|
-
expression: {
|
|
366
|
-
...expr,
|
|
367
|
-
right: loweredRight.expression,
|
|
368
|
-
},
|
|
369
|
-
};
|
|
370
|
-
}
|
|
371
|
-
case "memberAccess": {
|
|
372
|
-
const loweredObject = lower(expr.object);
|
|
373
|
-
if (!loweredObject)
|
|
374
|
-
return undefined;
|
|
375
|
-
let loweredProperty = expr.property;
|
|
376
|
-
let propertyPrelude = [];
|
|
377
|
-
if (typeof expr.property !== "string") {
|
|
378
|
-
const loweredPropExpr = lower(expr.property);
|
|
379
|
-
if (!loweredPropExpr)
|
|
380
|
-
return undefined;
|
|
381
|
-
loweredProperty = loweredPropExpr.expression;
|
|
382
|
-
propertyPrelude = loweredPropExpr.prelude;
|
|
383
|
-
}
|
|
384
|
-
return {
|
|
385
|
-
prelude: [...loweredObject.prelude, ...propertyPrelude],
|
|
386
|
-
expression: {
|
|
387
|
-
...expr,
|
|
388
|
-
object: loweredObject.expression,
|
|
389
|
-
property: loweredProperty,
|
|
390
|
-
},
|
|
391
|
-
};
|
|
392
|
-
}
|
|
393
|
-
case "call":
|
|
394
|
-
case "new": {
|
|
395
|
-
const loweredCallee = lower(expr.callee);
|
|
396
|
-
if (!loweredCallee)
|
|
397
|
-
return undefined;
|
|
398
|
-
const preludes = [...loweredCallee.prelude];
|
|
399
|
-
const loweredArgs = [];
|
|
400
|
-
for (const argument of expr.arguments) {
|
|
401
|
-
if (argument.kind === "spread") {
|
|
402
|
-
const loweredSpreadExpr = lower(argument.expression);
|
|
403
|
-
if (!loweredSpreadExpr)
|
|
404
|
-
return undefined;
|
|
405
|
-
preludes.push(...loweredSpreadExpr.prelude);
|
|
406
|
-
loweredArgs.push({
|
|
407
|
-
kind: "spread",
|
|
408
|
-
expression: loweredSpreadExpr.expression,
|
|
409
|
-
});
|
|
410
|
-
}
|
|
411
|
-
else {
|
|
412
|
-
const loweredArg = lower(argument);
|
|
413
|
-
if (!loweredArg)
|
|
414
|
-
return undefined;
|
|
415
|
-
preludes.push(...loweredArg.prelude);
|
|
416
|
-
loweredArgs.push(loweredArg.expression);
|
|
417
|
-
}
|
|
418
|
-
}
|
|
419
|
-
const loweredDynamicImportNamespace = expr.kind === "call" && expr.dynamicImportNamespace
|
|
420
|
-
? lower(expr.dynamicImportNamespace)
|
|
421
|
-
: undefined;
|
|
422
|
-
if (expr.kind === "call" &&
|
|
423
|
-
expr.dynamicImportNamespace &&
|
|
424
|
-
!loweredDynamicImportNamespace) {
|
|
425
|
-
return undefined;
|
|
426
|
-
}
|
|
427
|
-
if (loweredDynamicImportNamespace) {
|
|
428
|
-
preludes.push(...loweredDynamicImportNamespace.prelude);
|
|
429
|
-
}
|
|
430
|
-
return {
|
|
431
|
-
prelude: preludes,
|
|
432
|
-
expression: {
|
|
433
|
-
...expr,
|
|
434
|
-
callee: loweredCallee.expression,
|
|
435
|
-
arguments: loweredArgs,
|
|
436
|
-
...(expr.kind === "call"
|
|
437
|
-
? {
|
|
438
|
-
dynamicImportNamespace: loweredDynamicImportNamespace
|
|
439
|
-
? loweredDynamicImportNamespace.expression
|
|
440
|
-
: expr.dynamicImportNamespace,
|
|
441
|
-
}
|
|
442
|
-
: {}),
|
|
443
|
-
},
|
|
444
|
-
};
|
|
445
|
-
}
|
|
446
|
-
case "array": {
|
|
447
|
-
const preludes = [];
|
|
448
|
-
const loweredElements = [];
|
|
449
|
-
for (const element of expr.elements) {
|
|
450
|
-
if (!element) {
|
|
451
|
-
loweredElements.push(undefined);
|
|
452
|
-
continue;
|
|
453
|
-
}
|
|
454
|
-
if (element.kind === "spread") {
|
|
455
|
-
const loweredSpreadExpr = lower(element.expression);
|
|
456
|
-
if (!loweredSpreadExpr)
|
|
457
|
-
return undefined;
|
|
458
|
-
preludes.push(...loweredSpreadExpr.prelude);
|
|
459
|
-
loweredElements.push({
|
|
460
|
-
kind: "spread",
|
|
461
|
-
expression: loweredSpreadExpr.expression,
|
|
462
|
-
});
|
|
463
|
-
continue;
|
|
464
|
-
}
|
|
465
|
-
const loweredElement = lower(element);
|
|
466
|
-
if (!loweredElement)
|
|
467
|
-
return undefined;
|
|
468
|
-
preludes.push(...loweredElement.prelude);
|
|
469
|
-
loweredElements.push(loweredElement.expression);
|
|
470
|
-
}
|
|
471
|
-
return {
|
|
472
|
-
prelude: preludes,
|
|
473
|
-
expression: {
|
|
474
|
-
...expr,
|
|
475
|
-
elements: loweredElements,
|
|
476
|
-
},
|
|
477
|
-
};
|
|
478
|
-
}
|
|
479
|
-
case "object": {
|
|
480
|
-
const preludes = [];
|
|
481
|
-
const loweredProperties = [];
|
|
482
|
-
for (const property of expr.properties) {
|
|
483
|
-
if (property.kind === "spread") {
|
|
484
|
-
const loweredSpreadExpr = lower(property.expression);
|
|
485
|
-
if (!loweredSpreadExpr)
|
|
486
|
-
return undefined;
|
|
487
|
-
preludes.push(...loweredSpreadExpr.prelude);
|
|
488
|
-
loweredProperties.push({
|
|
489
|
-
kind: "spread",
|
|
490
|
-
expression: loweredSpreadExpr.expression,
|
|
491
|
-
});
|
|
492
|
-
continue;
|
|
493
|
-
}
|
|
494
|
-
let loweredKey = property.key;
|
|
495
|
-
if (typeof property.key !== "string") {
|
|
496
|
-
const loweredKeyExpr = lower(property.key);
|
|
497
|
-
if (!loweredKeyExpr)
|
|
498
|
-
return undefined;
|
|
499
|
-
preludes.push(...loweredKeyExpr.prelude);
|
|
500
|
-
loweredKey = loweredKeyExpr.expression;
|
|
501
|
-
}
|
|
502
|
-
const loweredValue = lower(property.value);
|
|
503
|
-
if (!loweredValue)
|
|
504
|
-
return undefined;
|
|
505
|
-
preludes.push(...loweredValue.prelude);
|
|
506
|
-
loweredProperties.push({
|
|
507
|
-
kind: "property",
|
|
508
|
-
key: loweredKey,
|
|
509
|
-
value: loweredValue.expression,
|
|
510
|
-
shorthand: property.shorthand,
|
|
511
|
-
});
|
|
512
|
-
}
|
|
513
|
-
return {
|
|
514
|
-
prelude: preludes,
|
|
515
|
-
expression: {
|
|
516
|
-
...expr,
|
|
517
|
-
properties: loweredProperties,
|
|
518
|
-
},
|
|
519
|
-
};
|
|
520
|
-
}
|
|
521
|
-
case "templateLiteral": {
|
|
522
|
-
const preludes = [];
|
|
523
|
-
const loweredExpressions = [];
|
|
524
|
-
for (const templateExpr of expr.expressions) {
|
|
525
|
-
const loweredTemplateExpr = lower(templateExpr);
|
|
526
|
-
if (!loweredTemplateExpr)
|
|
527
|
-
return undefined;
|
|
528
|
-
preludes.push(...loweredTemplateExpr.prelude);
|
|
529
|
-
loweredExpressions.push(loweredTemplateExpr.expression);
|
|
530
|
-
}
|
|
531
|
-
return {
|
|
532
|
-
prelude: preludes,
|
|
533
|
-
expression: {
|
|
534
|
-
...expr,
|
|
535
|
-
expressions: loweredExpressions,
|
|
536
|
-
},
|
|
537
|
-
};
|
|
538
|
-
}
|
|
539
|
-
case "conditional": {
|
|
540
|
-
const loweredCondition = lower(expr.condition);
|
|
541
|
-
if (!loweredCondition)
|
|
542
|
-
return undefined;
|
|
543
|
-
const loweredWhenTrue = lower(expr.whenTrue);
|
|
544
|
-
if (!loweredWhenTrue)
|
|
545
|
-
return undefined;
|
|
546
|
-
const loweredWhenFalse = lower(expr.whenFalse);
|
|
547
|
-
if (!loweredWhenFalse)
|
|
548
|
-
return undefined;
|
|
549
|
-
const tempType = expr.inferredType ??
|
|
550
|
-
expectedType ??
|
|
551
|
-
loweredWhenTrue.expression.inferredType ??
|
|
552
|
-
loweredWhenFalse.expression.inferredType;
|
|
553
|
-
if (!tempType) {
|
|
554
|
-
emitUnsupportedYieldDiagnostic(ctx, `${position} conditional expression`, expr.sourceSpan);
|
|
555
|
-
return undefined;
|
|
556
|
-
}
|
|
557
|
-
const tempName = allocateYieldTempName(ctx);
|
|
558
|
-
const tempPattern = {
|
|
559
|
-
kind: "identifierPattern",
|
|
560
|
-
name: tempName,
|
|
561
|
-
};
|
|
562
|
-
const assignTrueStatement = {
|
|
563
|
-
kind: "expressionStatement",
|
|
564
|
-
expression: {
|
|
565
|
-
kind: "assignment",
|
|
566
|
-
operator: "=",
|
|
567
|
-
left: tempPattern,
|
|
568
|
-
right: loweredWhenTrue.expression,
|
|
569
|
-
},
|
|
570
|
-
};
|
|
571
|
-
const assignFalseStatement = {
|
|
572
|
-
kind: "expressionStatement",
|
|
573
|
-
expression: {
|
|
574
|
-
kind: "assignment",
|
|
575
|
-
operator: "=",
|
|
576
|
-
left: tempPattern,
|
|
577
|
-
right: loweredWhenFalse.expression,
|
|
578
|
-
},
|
|
579
|
-
};
|
|
580
|
-
return {
|
|
581
|
-
prelude: [
|
|
582
|
-
...loweredCondition.prelude,
|
|
583
|
-
{
|
|
584
|
-
kind: "variableDeclaration",
|
|
585
|
-
declarationKind: "let",
|
|
586
|
-
isExported: false,
|
|
587
|
-
declarations: [
|
|
588
|
-
{
|
|
589
|
-
kind: "variableDeclarator",
|
|
590
|
-
name: tempPattern,
|
|
591
|
-
type: tempType,
|
|
592
|
-
initializer: { kind: "literal", value: undefined },
|
|
593
|
-
},
|
|
594
|
-
],
|
|
595
|
-
},
|
|
596
|
-
{
|
|
597
|
-
kind: "ifStatement",
|
|
598
|
-
condition: loweredCondition.expression,
|
|
599
|
-
thenStatement: {
|
|
600
|
-
kind: "blockStatement",
|
|
601
|
-
statements: [...loweredWhenTrue.prelude, assignTrueStatement],
|
|
602
|
-
},
|
|
603
|
-
elseStatement: {
|
|
604
|
-
kind: "blockStatement",
|
|
605
|
-
statements: [...loweredWhenFalse.prelude, assignFalseStatement],
|
|
606
|
-
},
|
|
607
|
-
},
|
|
608
|
-
],
|
|
609
|
-
expression: { kind: "identifier", name: tempName },
|
|
610
|
-
};
|
|
611
|
-
}
|
|
612
|
-
default:
|
|
613
|
-
emitUnsupportedYieldDiagnostic(ctx, position, expr.sourceSpan);
|
|
614
|
-
return undefined;
|
|
615
|
-
}
|
|
616
|
-
};
|
|
617
|
-
return lower(expression);
|
|
618
|
-
};
|
|
619
|
-
/**
|
|
620
|
-
* Process a statement in a generator function body.
|
|
621
|
-
* Returns the transformed statement(s) - may return multiple statements
|
|
622
|
-
* when a single statement is split.
|
|
623
|
-
*/
|
|
624
|
-
const processStatement = (stmt, ctx) => {
|
|
625
|
-
if (!ctx.inGenerator) {
|
|
626
|
-
// Not in generator - just recurse into nested functions
|
|
627
|
-
return processNonGeneratorStatement(stmt, ctx);
|
|
628
|
-
}
|
|
629
|
-
switch (stmt.kind) {
|
|
630
|
-
case "expressionStatement": {
|
|
631
|
-
const expr = stmt.expression;
|
|
632
|
-
// Pattern 1: yield expr; (yield in statement position)
|
|
633
|
-
if (expr.kind === "yield") {
|
|
634
|
-
return createYieldStatement(expr, undefined, undefined);
|
|
635
|
-
}
|
|
636
|
-
// Pattern 3: x = yield expr; (assignment with yield on right)
|
|
637
|
-
if (expr.kind === "assignment") {
|
|
638
|
-
if (expr.operator === "=" &&
|
|
639
|
-
expr.left.kind === "memberAccess" &&
|
|
640
|
-
((expr.right.kind === "yield" && !expr.right.delegate) ||
|
|
641
|
-
containsYield(expr.left))) {
|
|
642
|
-
const loweredMemberAssignment = lowerMemberAccessAssignmentWithYields(expr, ctx, {
|
|
643
|
-
object: "assignment target object",
|
|
644
|
-
property: "assignment target property",
|
|
645
|
-
right: "assignment value",
|
|
646
|
-
});
|
|
647
|
-
if (!loweredMemberAssignment) {
|
|
648
|
-
return stmt;
|
|
649
|
-
}
|
|
650
|
-
return [
|
|
651
|
-
...loweredMemberAssignment.leadingStatements,
|
|
652
|
-
{
|
|
653
|
-
kind: "expressionStatement",
|
|
654
|
-
expression: loweredMemberAssignment.loweredAssignment,
|
|
655
|
-
},
|
|
656
|
-
];
|
|
657
|
-
}
|
|
658
|
-
if (expr.right.kind === "yield" && !expr.right.delegate) {
|
|
659
|
-
// Compound assignment (x += yield y) needs a temporary receive target,
|
|
660
|
-
// then an explicit compound update statement.
|
|
661
|
-
if (expr.operator !== "=") {
|
|
662
|
-
if (expr.left.kind !== "identifierPattern" &&
|
|
663
|
-
expr.left.kind !== "identifier" &&
|
|
664
|
-
expr.left.kind !== "memberAccess") {
|
|
665
|
-
emitUnsupportedYieldDiagnostic(ctx, "compound assignment to complex target", expr.right.sourceSpan);
|
|
666
|
-
return stmt;
|
|
667
|
-
}
|
|
668
|
-
if (expr.left.kind === "identifierPattern" ||
|
|
669
|
-
expr.left.kind === "identifier") {
|
|
670
|
-
const tempName = allocateYieldTempName(ctx);
|
|
671
|
-
const leftExpr = expr.left.kind === "identifierPattern"
|
|
672
|
-
? { kind: "identifier", name: expr.left.name }
|
|
673
|
-
: expr.left;
|
|
674
|
-
return [
|
|
675
|
-
createYieldStatement(expr.right, { kind: "identifierPattern", name: tempName }, expr.right.inferredType),
|
|
676
|
-
{
|
|
677
|
-
kind: "expressionStatement",
|
|
678
|
-
expression: {
|
|
679
|
-
...expr,
|
|
680
|
-
left: leftExpr,
|
|
681
|
-
right: { kind: "identifier", name: tempName },
|
|
682
|
-
},
|
|
683
|
-
},
|
|
684
|
-
];
|
|
685
|
-
}
|
|
686
|
-
const loweredObject = lowerExpressionWithYields(expr.left.object, ctx, "compound assignment target object", expr.left.object.inferredType);
|
|
687
|
-
if (!loweredObject) {
|
|
688
|
-
return stmt;
|
|
689
|
-
}
|
|
690
|
-
const objectTempName = allocateYieldTempName(ctx);
|
|
691
|
-
const leadingStatements = [
|
|
692
|
-
...loweredObject.prelude,
|
|
693
|
-
createTempVariableDeclaration(objectTempName, loweredObject.expression, loweredObject.expression.inferredType),
|
|
694
|
-
];
|
|
695
|
-
let propertyExpr = expr.left.property;
|
|
696
|
-
if (typeof expr.left.property !== "string") {
|
|
697
|
-
const loweredProperty = lowerExpressionWithYields(expr.left.property, ctx, "compound assignment target property", expr.left.property.inferredType);
|
|
698
|
-
if (!loweredProperty) {
|
|
699
|
-
return stmt;
|
|
700
|
-
}
|
|
701
|
-
leadingStatements.push(...loweredProperty.prelude);
|
|
702
|
-
const propertyTempName = allocateYieldTempName(ctx);
|
|
703
|
-
leadingStatements.push(createTempVariableDeclaration(propertyTempName, loweredProperty.expression, loweredProperty.expression.inferredType));
|
|
704
|
-
propertyExpr = { kind: "identifier", name: propertyTempName };
|
|
705
|
-
}
|
|
706
|
-
const receiveTempName = allocateYieldTempName(ctx);
|
|
707
|
-
return [
|
|
708
|
-
...leadingStatements,
|
|
709
|
-
createYieldStatement(expr.right, { kind: "identifierPattern", name: receiveTempName }, expr.right.inferredType),
|
|
710
|
-
{
|
|
711
|
-
kind: "expressionStatement",
|
|
712
|
-
expression: {
|
|
713
|
-
...expr,
|
|
714
|
-
left: {
|
|
715
|
-
...expr.left,
|
|
716
|
-
object: { kind: "identifier", name: objectTempName },
|
|
717
|
-
property: propertyExpr,
|
|
718
|
-
},
|
|
719
|
-
right: { kind: "identifier", name: receiveTempName },
|
|
720
|
-
},
|
|
721
|
-
},
|
|
722
|
-
];
|
|
723
|
-
}
|
|
724
|
-
// Extract the target pattern
|
|
725
|
-
const receiveTarget = toReceivePattern(expr.left);
|
|
726
|
-
if (receiveTarget) {
|
|
727
|
-
return createYieldStatement(expr.right, receiveTarget, expr.right.inferredType);
|
|
728
|
-
}
|
|
729
|
-
// Assignment to member expression or other LHS - not supported
|
|
730
|
-
emitUnsupportedYieldDiagnostic(ctx, "assignment to complex target", expr.right.sourceSpan);
|
|
731
|
-
return stmt;
|
|
732
|
-
}
|
|
733
|
-
}
|
|
734
|
-
// Check for yield in unsupported positions
|
|
735
|
-
if (containsYield(expr)) {
|
|
736
|
-
const lowered = lowerExpressionWithYields(expr, ctx, "expression statement");
|
|
737
|
-
if (!lowered) {
|
|
738
|
-
return stmt;
|
|
739
|
-
}
|
|
740
|
-
return [
|
|
741
|
-
...lowered.prelude,
|
|
742
|
-
{
|
|
743
|
-
...stmt,
|
|
744
|
-
expression: lowered.expression,
|
|
745
|
-
},
|
|
746
|
-
];
|
|
747
|
-
}
|
|
748
|
-
return stmt;
|
|
749
|
-
}
|
|
750
|
-
case "variableDeclaration": {
|
|
751
|
-
// Pattern 2: const x = yield expr; (variable declaration with yield initializer)
|
|
752
|
-
const transformedDeclarations = [];
|
|
753
|
-
for (const decl of stmt.declarations) {
|
|
754
|
-
if (decl.initializer?.kind === "yield" && !decl.initializer.delegate) {
|
|
755
|
-
// Check for multiple yields in initializer
|
|
756
|
-
if (countYields(decl.initializer) > 1) {
|
|
757
|
-
emitUnsupportedYieldDiagnostic(ctx, "multiple yields in initializer", decl.initializer.sourceSpan);
|
|
758
|
-
transformedDeclarations.push({
|
|
759
|
-
kind: "variableDeclaration",
|
|
760
|
-
declarationKind: stmt.declarationKind,
|
|
761
|
-
declarations: [decl],
|
|
762
|
-
isExported: false,
|
|
763
|
-
});
|
|
764
|
-
continue;
|
|
765
|
-
}
|
|
766
|
-
// Transform to yield statement with receiveTarget
|
|
767
|
-
transformedDeclarations.push(createYieldStatement(decl.initializer, decl.name, decl.type ?? decl.initializer.inferredType));
|
|
768
|
-
}
|
|
769
|
-
else if (decl.initializer && containsYield(decl.initializer)) {
|
|
770
|
-
const lowered = lowerExpressionWithYields(decl.initializer, ctx, "variable initializer", decl.type ?? decl.initializer.inferredType);
|
|
771
|
-
if (!lowered) {
|
|
772
|
-
transformedDeclarations.push({
|
|
773
|
-
kind: "variableDeclaration",
|
|
774
|
-
declarationKind: stmt.declarationKind,
|
|
775
|
-
declarations: [decl],
|
|
776
|
-
isExported: false,
|
|
777
|
-
});
|
|
778
|
-
continue;
|
|
779
|
-
}
|
|
780
|
-
transformedDeclarations.push(...lowered.prelude);
|
|
781
|
-
transformedDeclarations.push({
|
|
782
|
-
kind: "variableDeclaration",
|
|
783
|
-
declarationKind: stmt.declarationKind,
|
|
784
|
-
declarations: [
|
|
785
|
-
{
|
|
786
|
-
...decl,
|
|
787
|
-
initializer: lowered.expression,
|
|
788
|
-
},
|
|
789
|
-
],
|
|
790
|
-
isExported: false,
|
|
791
|
-
});
|
|
792
|
-
}
|
|
793
|
-
else {
|
|
794
|
-
// No yield - keep original declaration
|
|
795
|
-
transformedDeclarations.push({
|
|
796
|
-
kind: "variableDeclaration",
|
|
797
|
-
declarationKind: stmt.declarationKind,
|
|
798
|
-
declarations: [decl],
|
|
799
|
-
isExported: false,
|
|
800
|
-
});
|
|
801
|
-
}
|
|
802
|
-
}
|
|
803
|
-
// Return single statement or array of statements
|
|
804
|
-
if (transformedDeclarations.length === 1 &&
|
|
805
|
-
transformedDeclarations[0] !== undefined) {
|
|
806
|
-
return transformedDeclarations[0];
|
|
807
|
-
}
|
|
808
|
-
return transformedDeclarations;
|
|
809
|
-
}
|
|
810
|
-
case "blockStatement":
|
|
811
|
-
return {
|
|
812
|
-
...stmt,
|
|
813
|
-
statements: stmt.statements.flatMap((s) => {
|
|
814
|
-
const result = processStatement(s, ctx);
|
|
815
|
-
return Array.isArray(result) ? result : [result];
|
|
816
|
-
}),
|
|
817
|
-
};
|
|
818
|
-
case "ifStatement":
|
|
819
|
-
if (containsYield(stmt.condition)) {
|
|
820
|
-
const loweredCondition = lowerExpressionWithYields(stmt.condition, ctx, "if condition");
|
|
821
|
-
if (!loweredCondition) {
|
|
822
|
-
return {
|
|
823
|
-
...stmt,
|
|
824
|
-
thenStatement: flattenStatement(processStatement(stmt.thenStatement, ctx)),
|
|
825
|
-
elseStatement: stmt.elseStatement
|
|
826
|
-
? flattenStatement(processStatement(stmt.elseStatement, ctx))
|
|
827
|
-
: undefined,
|
|
828
|
-
};
|
|
829
|
-
}
|
|
830
|
-
return [
|
|
831
|
-
...loweredCondition.prelude,
|
|
832
|
-
{
|
|
833
|
-
...stmt,
|
|
834
|
-
condition: loweredCondition.expression,
|
|
835
|
-
thenStatement: flattenStatement(processStatement(stmt.thenStatement, ctx)),
|
|
836
|
-
elseStatement: stmt.elseStatement
|
|
837
|
-
? flattenStatement(processStatement(stmt.elseStatement, ctx))
|
|
838
|
-
: undefined,
|
|
839
|
-
},
|
|
840
|
-
];
|
|
841
|
-
}
|
|
842
|
-
return {
|
|
843
|
-
...stmt,
|
|
844
|
-
thenStatement: flattenStatement(processStatement(stmt.thenStatement, ctx)),
|
|
845
|
-
elseStatement: stmt.elseStatement
|
|
846
|
-
? flattenStatement(processStatement(stmt.elseStatement, ctx))
|
|
847
|
-
: undefined,
|
|
848
|
-
};
|
|
849
|
-
case "whileStatement":
|
|
850
|
-
if (containsYield(stmt.condition)) {
|
|
851
|
-
const loweredCondition = lowerExpressionWithYields(stmt.condition, ctx, "while condition");
|
|
852
|
-
if (!loweredCondition) {
|
|
853
|
-
return {
|
|
854
|
-
...stmt,
|
|
855
|
-
body: flattenStatement(processStatement(stmt.body, ctx)),
|
|
856
|
-
};
|
|
857
|
-
}
|
|
858
|
-
const transformedBody = flattenStatement(processStatement(stmt.body, ctx));
|
|
859
|
-
const bodyStatements = [
|
|
860
|
-
...loweredCondition.prelude,
|
|
861
|
-
{
|
|
862
|
-
kind: "ifStatement",
|
|
863
|
-
condition: {
|
|
864
|
-
kind: "unary",
|
|
865
|
-
operator: "!",
|
|
866
|
-
expression: loweredCondition.expression,
|
|
867
|
-
},
|
|
868
|
-
thenStatement: { kind: "breakStatement" },
|
|
869
|
-
},
|
|
870
|
-
];
|
|
871
|
-
if (transformedBody.kind === "blockStatement") {
|
|
872
|
-
bodyStatements.push(...transformedBody.statements);
|
|
873
|
-
}
|
|
874
|
-
else {
|
|
875
|
-
bodyStatements.push(transformedBody);
|
|
876
|
-
}
|
|
877
|
-
return {
|
|
878
|
-
kind: "whileStatement",
|
|
879
|
-
condition: { kind: "literal", value: true },
|
|
880
|
-
body: {
|
|
881
|
-
kind: "blockStatement",
|
|
882
|
-
statements: bodyStatements,
|
|
883
|
-
},
|
|
884
|
-
};
|
|
885
|
-
}
|
|
886
|
-
return {
|
|
887
|
-
...stmt,
|
|
888
|
-
body: flattenStatement(processStatement(stmt.body, ctx)),
|
|
889
|
-
};
|
|
890
|
-
case "forStatement": {
|
|
891
|
-
const leadingStatements = [];
|
|
892
|
-
let initializer = stmt.initializer;
|
|
893
|
-
if (initializer) {
|
|
894
|
-
if (initializer.kind === "assignment" &&
|
|
895
|
-
initializer.operator === "=" &&
|
|
896
|
-
((initializer.right.kind === "yield" &&
|
|
897
|
-
!initializer.right.delegate) ||
|
|
898
|
-
(initializer.left.kind === "memberAccess" &&
|
|
899
|
-
containsYield(initializer.left)))) {
|
|
900
|
-
const receiveTarget = toReceivePattern(initializer.left);
|
|
901
|
-
if (receiveTarget &&
|
|
902
|
-
initializer.right.kind === "yield" &&
|
|
903
|
-
!initializer.right.delegate) {
|
|
904
|
-
leadingStatements.push(createYieldStatement(initializer.right, receiveTarget, initializer.right.inferredType));
|
|
905
|
-
initializer = undefined;
|
|
906
|
-
}
|
|
907
|
-
else if (receiveTarget) {
|
|
908
|
-
emitUnsupportedYieldDiagnostic(ctx, "for loop initializer", initializer.right.sourceSpan);
|
|
909
|
-
}
|
|
910
|
-
else if (initializer.left.kind === "memberAccess") {
|
|
911
|
-
const loweredMemberAssignment = lowerMemberAccessAssignmentWithYields(initializer, ctx, {
|
|
912
|
-
object: "for loop initializer target object",
|
|
913
|
-
property: "for loop initializer target property",
|
|
914
|
-
right: "for loop initializer value",
|
|
915
|
-
});
|
|
916
|
-
if (!loweredMemberAssignment) {
|
|
917
|
-
emitUnsupportedYieldDiagnostic(ctx, "for loop initializer", initializer.right.sourceSpan);
|
|
918
|
-
}
|
|
919
|
-
else {
|
|
920
|
-
leadingStatements.push(...loweredMemberAssignment.leadingStatements);
|
|
921
|
-
leadingStatements.push({
|
|
922
|
-
kind: "expressionStatement",
|
|
923
|
-
expression: loweredMemberAssignment.loweredAssignment,
|
|
924
|
-
});
|
|
925
|
-
initializer = undefined;
|
|
926
|
-
}
|
|
927
|
-
}
|
|
928
|
-
else {
|
|
929
|
-
emitUnsupportedYieldDiagnostic(ctx, "for loop initializer", initializer.right.sourceSpan);
|
|
930
|
-
}
|
|
931
|
-
}
|
|
932
|
-
else if (initializer.kind === "variableDeclaration") {
|
|
933
|
-
const transformedDecls = initializer.declarations.map((decl) => {
|
|
934
|
-
if (!decl.initializer || !containsYield(decl.initializer)) {
|
|
935
|
-
return decl;
|
|
936
|
-
}
|
|
937
|
-
if (decl.initializer.kind === "yield" &&
|
|
938
|
-
!decl.initializer.delegate) {
|
|
939
|
-
const tempName = allocateYieldTempName(ctx);
|
|
940
|
-
leadingStatements.push(createYieldStatement(decl.initializer, { kind: "identifierPattern", name: tempName }, decl.type ?? decl.initializer.inferredType));
|
|
941
|
-
return {
|
|
942
|
-
...decl,
|
|
943
|
-
initializer: {
|
|
944
|
-
kind: "identifier",
|
|
945
|
-
name: tempName,
|
|
946
|
-
},
|
|
947
|
-
};
|
|
948
|
-
}
|
|
949
|
-
const loweredInitializer = lowerExpressionWithYields(decl.initializer, ctx, "for loop initializer", decl.type ?? decl.initializer.inferredType);
|
|
950
|
-
if (!loweredInitializer) {
|
|
951
|
-
return decl;
|
|
952
|
-
}
|
|
953
|
-
leadingStatements.push(...loweredInitializer.prelude);
|
|
954
|
-
return {
|
|
955
|
-
...decl,
|
|
956
|
-
initializer: loweredInitializer.expression,
|
|
957
|
-
};
|
|
958
|
-
});
|
|
959
|
-
initializer = {
|
|
960
|
-
...initializer,
|
|
961
|
-
declarations: transformedDecls,
|
|
962
|
-
};
|
|
963
|
-
}
|
|
964
|
-
else if (containsYield(initializer)) {
|
|
965
|
-
const loweredInitializer = lowerExpressionWithYields(initializer, ctx, "for loop initializer");
|
|
966
|
-
if (loweredInitializer) {
|
|
967
|
-
leadingStatements.push(...loweredInitializer.prelude);
|
|
968
|
-
initializer = loweredInitializer.expression;
|
|
969
|
-
}
|
|
970
|
-
}
|
|
971
|
-
}
|
|
972
|
-
const loweredCondition = stmt.condition && containsYield(stmt.condition)
|
|
973
|
-
? lowerExpressionWithYields(stmt.condition, ctx, "for loop condition")
|
|
974
|
-
: undefined;
|
|
975
|
-
const loweredUpdate = stmt.update && containsYield(stmt.update)
|
|
976
|
-
? lowerExpressionWithYields(stmt.update, ctx, "for loop update")
|
|
977
|
-
: undefined;
|
|
978
|
-
const transformedBody = flattenStatement(processStatement(stmt.body, ctx));
|
|
979
|
-
if (!loweredCondition && !loweredUpdate) {
|
|
980
|
-
const transformedFor = {
|
|
981
|
-
...stmt,
|
|
982
|
-
initializer,
|
|
983
|
-
body: transformedBody,
|
|
984
|
-
};
|
|
985
|
-
if (leadingStatements.length === 0) {
|
|
986
|
-
return transformedFor;
|
|
987
|
-
}
|
|
988
|
-
return [...leadingStatements, transformedFor];
|
|
989
|
-
}
|
|
990
|
-
const bodyStatements = [];
|
|
991
|
-
let updateFirstFlagName;
|
|
992
|
-
if (loweredUpdate) {
|
|
993
|
-
updateFirstFlagName = allocateYieldTempName(ctx);
|
|
994
|
-
leadingStatements.push({
|
|
995
|
-
kind: "variableDeclaration",
|
|
996
|
-
declarationKind: "let",
|
|
997
|
-
isExported: false,
|
|
998
|
-
declarations: [
|
|
999
|
-
{
|
|
1000
|
-
kind: "variableDeclarator",
|
|
1001
|
-
name: { kind: "identifierPattern", name: updateFirstFlagName },
|
|
1002
|
-
type: { kind: "primitiveType", name: "boolean" },
|
|
1003
|
-
initializer: { kind: "literal", value: true },
|
|
1004
|
-
},
|
|
1005
|
-
],
|
|
1006
|
-
});
|
|
1007
|
-
const updateBodyStatements = [...loweredUpdate.prelude];
|
|
1008
|
-
if (!stmt.update || stmt.update.kind !== "yield") {
|
|
1009
|
-
updateBodyStatements.push({
|
|
1010
|
-
kind: "expressionStatement",
|
|
1011
|
-
expression: loweredUpdate.expression,
|
|
1012
|
-
});
|
|
1013
|
-
}
|
|
1014
|
-
bodyStatements.push({
|
|
1015
|
-
kind: "ifStatement",
|
|
1016
|
-
condition: {
|
|
1017
|
-
kind: "unary",
|
|
1018
|
-
operator: "!",
|
|
1019
|
-
expression: { kind: "identifier", name: updateFirstFlagName },
|
|
1020
|
-
},
|
|
1021
|
-
thenStatement: {
|
|
1022
|
-
kind: "blockStatement",
|
|
1023
|
-
statements: updateBodyStatements,
|
|
1024
|
-
},
|
|
1025
|
-
});
|
|
1026
|
-
bodyStatements.push({
|
|
1027
|
-
kind: "expressionStatement",
|
|
1028
|
-
expression: {
|
|
1029
|
-
kind: "assignment",
|
|
1030
|
-
operator: "=",
|
|
1031
|
-
left: { kind: "identifierPattern", name: updateFirstFlagName },
|
|
1032
|
-
right: { kind: "literal", value: false },
|
|
1033
|
-
},
|
|
1034
|
-
});
|
|
1035
|
-
}
|
|
1036
|
-
if (loweredCondition) {
|
|
1037
|
-
bodyStatements.push(...loweredCondition.prelude);
|
|
1038
|
-
bodyStatements.push({
|
|
1039
|
-
kind: "ifStatement",
|
|
1040
|
-
condition: {
|
|
1041
|
-
kind: "unary",
|
|
1042
|
-
operator: "!",
|
|
1043
|
-
expression: loweredCondition.expression,
|
|
1044
|
-
},
|
|
1045
|
-
thenStatement: { kind: "breakStatement" },
|
|
1046
|
-
});
|
|
1047
|
-
}
|
|
1048
|
-
else if (loweredUpdate && stmt.condition) {
|
|
1049
|
-
bodyStatements.push({
|
|
1050
|
-
kind: "ifStatement",
|
|
1051
|
-
condition: {
|
|
1052
|
-
kind: "unary",
|
|
1053
|
-
operator: "!",
|
|
1054
|
-
expression: stmt.condition,
|
|
1055
|
-
},
|
|
1056
|
-
thenStatement: { kind: "breakStatement" },
|
|
1057
|
-
});
|
|
1058
|
-
}
|
|
1059
|
-
if (transformedBody.kind === "blockStatement") {
|
|
1060
|
-
bodyStatements.push(...transformedBody.statements);
|
|
1061
|
-
}
|
|
1062
|
-
else {
|
|
1063
|
-
bodyStatements.push(transformedBody);
|
|
1064
|
-
}
|
|
1065
|
-
const transformedFor = {
|
|
1066
|
-
...stmt,
|
|
1067
|
-
initializer,
|
|
1068
|
-
condition: { kind: "literal", value: true },
|
|
1069
|
-
update: loweredUpdate ? undefined : stmt.update,
|
|
1070
|
-
body: {
|
|
1071
|
-
kind: "blockStatement",
|
|
1072
|
-
statements: bodyStatements,
|
|
1073
|
-
},
|
|
1074
|
-
};
|
|
1075
|
-
if (leadingStatements.length === 0) {
|
|
1076
|
-
return transformedFor;
|
|
1077
|
-
}
|
|
1078
|
-
return [...leadingStatements, transformedFor];
|
|
1079
|
-
}
|
|
1080
|
-
case "forOfStatement":
|
|
1081
|
-
if (containsYield(stmt.expression)) {
|
|
1082
|
-
const loweredExpression = lowerExpressionWithYields(stmt.expression, ctx, "for-of expression");
|
|
1083
|
-
if (!loweredExpression) {
|
|
1084
|
-
return {
|
|
1085
|
-
...stmt,
|
|
1086
|
-
body: flattenStatement(processStatement(stmt.body, ctx)),
|
|
1087
|
-
};
|
|
1088
|
-
}
|
|
1089
|
-
return [
|
|
1090
|
-
...loweredExpression.prelude,
|
|
1091
|
-
{
|
|
1092
|
-
...stmt,
|
|
1093
|
-
expression: loweredExpression.expression,
|
|
1094
|
-
body: flattenStatement(processStatement(stmt.body, ctx)),
|
|
1095
|
-
},
|
|
1096
|
-
];
|
|
1097
|
-
}
|
|
1098
|
-
return {
|
|
1099
|
-
...stmt,
|
|
1100
|
-
body: flattenStatement(processStatement(stmt.body, ctx)),
|
|
1101
|
-
};
|
|
1102
|
-
case "forInStatement":
|
|
1103
|
-
if (containsYield(stmt.expression)) {
|
|
1104
|
-
const loweredExpression = lowerExpressionWithYields(stmt.expression, ctx, "for-in expression");
|
|
1105
|
-
if (!loweredExpression) {
|
|
1106
|
-
return {
|
|
1107
|
-
...stmt,
|
|
1108
|
-
body: flattenStatement(processStatement(stmt.body, ctx)),
|
|
1109
|
-
};
|
|
1110
|
-
}
|
|
1111
|
-
return [
|
|
1112
|
-
...loweredExpression.prelude,
|
|
1113
|
-
{
|
|
1114
|
-
...stmt,
|
|
1115
|
-
expression: loweredExpression.expression,
|
|
1116
|
-
body: flattenStatement(processStatement(stmt.body, ctx)),
|
|
1117
|
-
},
|
|
1118
|
-
];
|
|
1119
|
-
}
|
|
1120
|
-
return {
|
|
1121
|
-
...stmt,
|
|
1122
|
-
body: flattenStatement(processStatement(stmt.body, ctx)),
|
|
1123
|
-
};
|
|
1124
|
-
case "switchStatement":
|
|
1125
|
-
if (containsYield(stmt.expression)) {
|
|
1126
|
-
const loweredExpression = lowerExpressionWithYields(stmt.expression, ctx, "switch expression");
|
|
1127
|
-
if (!loweredExpression) {
|
|
1128
|
-
return {
|
|
1129
|
-
...stmt,
|
|
1130
|
-
cases: stmt.cases.map((c) => ({
|
|
1131
|
-
...c,
|
|
1132
|
-
statements: c.statements.flatMap((s) => {
|
|
1133
|
-
const result = processStatement(s, ctx);
|
|
1134
|
-
return Array.isArray(result) ? result : [result];
|
|
1135
|
-
}),
|
|
1136
|
-
})),
|
|
1137
|
-
};
|
|
1138
|
-
}
|
|
1139
|
-
return [
|
|
1140
|
-
...loweredExpression.prelude,
|
|
1141
|
-
{
|
|
1142
|
-
...stmt,
|
|
1143
|
-
expression: loweredExpression.expression,
|
|
1144
|
-
cases: stmt.cases.map((c) => ({
|
|
1145
|
-
...c,
|
|
1146
|
-
statements: c.statements.flatMap((s) => {
|
|
1147
|
-
const result = processStatement(s, ctx);
|
|
1148
|
-
return Array.isArray(result) ? result : [result];
|
|
1149
|
-
}),
|
|
1150
|
-
})),
|
|
1151
|
-
},
|
|
1152
|
-
];
|
|
1153
|
-
}
|
|
1154
|
-
return {
|
|
1155
|
-
...stmt,
|
|
1156
|
-
cases: stmt.cases.map((c) => ({
|
|
1157
|
-
...c,
|
|
1158
|
-
statements: c.statements.flatMap((s) => {
|
|
1159
|
-
const result = processStatement(s, ctx);
|
|
1160
|
-
return Array.isArray(result) ? result : [result];
|
|
1161
|
-
}),
|
|
1162
|
-
})),
|
|
1163
|
-
};
|
|
1164
|
-
case "tryStatement":
|
|
1165
|
-
return {
|
|
1166
|
-
...stmt,
|
|
1167
|
-
tryBlock: flattenStatement(processStatement(stmt.tryBlock, ctx)),
|
|
1168
|
-
catchClause: stmt.catchClause
|
|
1169
|
-
? {
|
|
1170
|
-
...stmt.catchClause,
|
|
1171
|
-
body: flattenStatement(processStatement(stmt.catchClause.body, ctx)),
|
|
1172
|
-
}
|
|
1173
|
-
: undefined,
|
|
1174
|
-
finallyBlock: stmt.finallyBlock
|
|
1175
|
-
? flattenStatement(processStatement(stmt.finallyBlock, ctx))
|
|
1176
|
-
: undefined,
|
|
1177
|
-
};
|
|
1178
|
-
case "returnStatement":
|
|
1179
|
-
if (stmt.expression && containsYield(stmt.expression)) {
|
|
1180
|
-
const lowered = lowerExpressionWithYields(stmt.expression, ctx, "return expression");
|
|
1181
|
-
if (!lowered) {
|
|
1182
|
-
return createGeneratorReturnStatement(stmt.expression);
|
|
1183
|
-
}
|
|
1184
|
-
return [
|
|
1185
|
-
...lowered.prelude,
|
|
1186
|
-
createGeneratorReturnStatement(lowered.expression),
|
|
1187
|
-
];
|
|
1188
|
-
}
|
|
1189
|
-
// Transform return statements in generators to IrGeneratorReturnStatement
|
|
1190
|
-
// This captures the return value for generators with TReturn
|
|
1191
|
-
// The emitter will emit: __returnValue = expr; yield break;
|
|
1192
|
-
return createGeneratorReturnStatement(stmt.expression);
|
|
1193
|
-
case "throwStatement":
|
|
1194
|
-
if (containsYield(stmt.expression)) {
|
|
1195
|
-
const lowered = lowerExpressionWithYields(stmt.expression, ctx, "throw expression");
|
|
1196
|
-
if (!lowered) {
|
|
1197
|
-
return stmt;
|
|
1198
|
-
}
|
|
1199
|
-
return [
|
|
1200
|
-
...lowered.prelude,
|
|
1201
|
-
{
|
|
1202
|
-
kind: "throwStatement",
|
|
1203
|
-
expression: lowered.expression,
|
|
1204
|
-
},
|
|
1205
|
-
];
|
|
1206
|
-
}
|
|
1207
|
-
return stmt;
|
|
1208
|
-
default:
|
|
1209
|
-
return stmt;
|
|
1210
|
-
}
|
|
1211
|
-
};
|
|
1212
|
-
/**
|
|
1213
|
-
* Type guard to check if a result is a single statement (has 'kind' property).
|
|
1214
|
-
*/
|
|
1215
|
-
const isSingleStatement = (result) => {
|
|
1216
|
-
return "kind" in result && typeof result.kind === "string";
|
|
1217
|
-
};
|
|
1218
|
-
/**
|
|
1219
|
-
* Flatten a statement result to a single statement (wrap in block if needed).
|
|
1220
|
-
*/
|
|
1221
|
-
const flattenStatement = (result) => {
|
|
1222
|
-
if (isSingleStatement(result)) {
|
|
1223
|
-
return result;
|
|
1224
|
-
}
|
|
1225
|
-
// result is now readonly IrStatement[]
|
|
1226
|
-
if (result.length === 1 && result[0] !== undefined) {
|
|
1227
|
-
return result[0];
|
|
1228
|
-
}
|
|
1229
|
-
return {
|
|
1230
|
-
kind: "blockStatement",
|
|
1231
|
-
statements: [...result],
|
|
1232
|
-
};
|
|
1233
|
-
};
|
|
1234
|
-
const isRecord = (value) => typeof value === "object" && value !== null;
|
|
1235
|
-
const collectResidualYieldExpressions = (value, collected) => {
|
|
1236
|
-
if (Array.isArray(value)) {
|
|
1237
|
-
for (const element of value) {
|
|
1238
|
-
collectResidualYieldExpressions(element, collected);
|
|
1239
|
-
}
|
|
1240
|
-
return;
|
|
1241
|
-
}
|
|
1242
|
-
if (!isRecord(value)) {
|
|
1243
|
-
return;
|
|
1244
|
-
}
|
|
1245
|
-
if (value.kind === "yield") {
|
|
1246
|
-
collected.push(value);
|
|
1247
|
-
return;
|
|
1248
|
-
}
|
|
1249
|
-
for (const nested of Object.values(value)) {
|
|
1250
|
-
collectResidualYieldExpressions(nested, collected);
|
|
1251
|
-
}
|
|
1252
|
-
};
|
|
1253
|
-
const locationKey = (location) => `${location.file}:${location.line}:${location.column}:${location.length}`;
|
|
1254
|
-
const addResidualYieldDiagnostics = (ctx, value) => {
|
|
1255
|
-
const residualYields = [];
|
|
1256
|
-
collectResidualYieldExpressions(value, residualYields);
|
|
1257
|
-
if (residualYields.length === 0) {
|
|
1258
|
-
return;
|
|
1259
|
-
}
|
|
1260
|
-
const existingTsn6101Locations = new Set(ctx.diagnostics
|
|
1261
|
-
.filter((d) => d.code === "TSN6101")
|
|
1262
|
-
.map((d) => locationKey(d.location ?? moduleLocation(ctx))));
|
|
1263
|
-
for (const residualYield of residualYields) {
|
|
1264
|
-
const location = residualYield.sourceSpan ?? moduleLocation(ctx);
|
|
1265
|
-
const key = locationKey(location);
|
|
1266
|
-
if (existingTsn6101Locations.has(key)) {
|
|
1267
|
-
continue;
|
|
1268
|
-
}
|
|
1269
|
-
emitUnsupportedYieldDiagnostic(ctx, "an unsupported expression form after yield lowering", location);
|
|
1270
|
-
existingTsn6101Locations.add(key);
|
|
1271
|
-
}
|
|
1272
|
-
};
|
|
1273
|
-
/**
|
|
1274
|
-
* Process statements in non-generator functions (just recurse into nested generators).
|
|
1275
|
-
*/
|
|
1276
|
-
const processNonGeneratorStatement = (stmt, ctx) => {
|
|
1277
|
-
switch (stmt.kind) {
|
|
1278
|
-
case "functionDeclaration":
|
|
1279
|
-
if (stmt.isGenerator) {
|
|
1280
|
-
const generatorCtx = {
|
|
1281
|
-
...ctx,
|
|
1282
|
-
inGenerator: true,
|
|
1283
|
-
};
|
|
1284
|
-
const loweredBody = flattenStatement(processStatement(stmt.body, generatorCtx));
|
|
1285
|
-
addResidualYieldDiagnostics(generatorCtx, loweredBody);
|
|
1286
|
-
return {
|
|
1287
|
-
...stmt,
|
|
1288
|
-
body: loweredBody,
|
|
1289
|
-
};
|
|
1290
|
-
}
|
|
1291
|
-
return {
|
|
1292
|
-
...stmt,
|
|
1293
|
-
body: flattenStatement(processStatement(stmt.body, ctx)),
|
|
1294
|
-
};
|
|
1295
|
-
case "classDeclaration":
|
|
1296
|
-
return {
|
|
1297
|
-
...stmt,
|
|
1298
|
-
members: stmt.members.map((m) => processClassMember(m, ctx)),
|
|
1299
|
-
};
|
|
1300
|
-
case "blockStatement":
|
|
1301
|
-
return {
|
|
1302
|
-
...stmt,
|
|
1303
|
-
statements: stmt.statements.map((s) => processNonGeneratorStatement(s, ctx)),
|
|
1304
|
-
};
|
|
1305
|
-
case "ifStatement":
|
|
1306
|
-
return {
|
|
1307
|
-
...stmt,
|
|
1308
|
-
thenStatement: processNonGeneratorStatement(stmt.thenStatement, ctx),
|
|
1309
|
-
elseStatement: stmt.elseStatement
|
|
1310
|
-
? processNonGeneratorStatement(stmt.elseStatement, ctx)
|
|
1311
|
-
: undefined,
|
|
1312
|
-
};
|
|
1313
|
-
case "whileStatement":
|
|
1314
|
-
return {
|
|
1315
|
-
...stmt,
|
|
1316
|
-
body: processNonGeneratorStatement(stmt.body, ctx),
|
|
1317
|
-
};
|
|
1318
|
-
case "forStatement":
|
|
1319
|
-
// Only process the body - initializer can't contain nested generator functions
|
|
1320
|
-
return {
|
|
1321
|
-
...stmt,
|
|
1322
|
-
body: processNonGeneratorStatement(stmt.body, ctx),
|
|
1323
|
-
};
|
|
1324
|
-
case "forOfStatement":
|
|
1325
|
-
return {
|
|
1326
|
-
...stmt,
|
|
1327
|
-
body: processNonGeneratorStatement(stmt.body, ctx),
|
|
1328
|
-
};
|
|
1329
|
-
case "switchStatement":
|
|
1330
|
-
return {
|
|
1331
|
-
...stmt,
|
|
1332
|
-
cases: stmt.cases.map((c) => ({
|
|
1333
|
-
...c,
|
|
1334
|
-
statements: c.statements.map((s) => processNonGeneratorStatement(s, ctx)),
|
|
1335
|
-
})),
|
|
1336
|
-
};
|
|
1337
|
-
case "tryStatement":
|
|
1338
|
-
return {
|
|
1339
|
-
...stmt,
|
|
1340
|
-
tryBlock: processNonGeneratorStatement(stmt.tryBlock, ctx),
|
|
1341
|
-
catchClause: stmt.catchClause
|
|
1342
|
-
? {
|
|
1343
|
-
...stmt.catchClause,
|
|
1344
|
-
body: processNonGeneratorStatement(stmt.catchClause.body, ctx),
|
|
1345
|
-
}
|
|
1346
|
-
: undefined,
|
|
1347
|
-
finallyBlock: stmt.finallyBlock
|
|
1348
|
-
? processNonGeneratorStatement(stmt.finallyBlock, ctx)
|
|
1349
|
-
: undefined,
|
|
1350
|
-
};
|
|
1351
|
-
default:
|
|
1352
|
-
return stmt;
|
|
1353
|
-
}
|
|
1354
|
-
};
|
|
1355
|
-
/**
|
|
1356
|
-
* Process class members, looking for generator methods.
|
|
1357
|
-
*/
|
|
1358
|
-
const processClassMember = (member, ctx) => {
|
|
1359
|
-
if (member.kind === "methodDeclaration" && member.body) {
|
|
1360
|
-
if (member.isGenerator) {
|
|
1361
|
-
const generatorCtx = {
|
|
1362
|
-
...ctx,
|
|
1363
|
-
inGenerator: true,
|
|
1364
|
-
};
|
|
1365
|
-
const loweredBody = flattenStatement(processStatement(member.body, generatorCtx));
|
|
1366
|
-
addResidualYieldDiagnostics(generatorCtx, loweredBody);
|
|
1367
|
-
return {
|
|
1368
|
-
...member,
|
|
1369
|
-
body: loweredBody,
|
|
1370
|
-
};
|
|
1371
|
-
}
|
|
1372
|
-
return {
|
|
1373
|
-
...member,
|
|
1374
|
-
body: flattenStatement(processStatement(member.body, ctx)),
|
|
1375
|
-
};
|
|
1376
|
-
}
|
|
1377
|
-
if (member.kind === "constructorDeclaration" && member.body) {
|
|
1378
|
-
return {
|
|
1379
|
-
...member,
|
|
1380
|
-
body: flattenStatement(processStatement(member.body, ctx)),
|
|
1381
|
-
};
|
|
1382
|
-
}
|
|
1383
|
-
return member;
|
|
1384
|
-
};
|
|
1385
|
-
/**
|
|
1386
|
-
* Process a module, transforming yield expressions in generators.
|
|
1387
|
-
*/
|
|
1388
|
-
const processModule = (module) => {
|
|
1389
|
-
const ctx = {
|
|
1390
|
-
filePath: module.filePath,
|
|
1391
|
-
diagnostics: [],
|
|
1392
|
-
inGenerator: false,
|
|
1393
|
-
yieldTempCounter: 0,
|
|
1394
|
-
};
|
|
1395
|
-
const processedBody = module.body.map((stmt) => {
|
|
1396
|
-
if (stmt.kind === "functionDeclaration" && stmt.isGenerator) {
|
|
1397
|
-
const generatorCtx = {
|
|
1398
|
-
...ctx,
|
|
1399
|
-
inGenerator: true,
|
|
1400
|
-
};
|
|
1401
|
-
const loweredBody = flattenStatement(processStatement(stmt.body, generatorCtx));
|
|
1402
|
-
addResidualYieldDiagnostics(generatorCtx, loweredBody);
|
|
1403
|
-
return {
|
|
1404
|
-
...stmt,
|
|
1405
|
-
body: loweredBody,
|
|
1406
|
-
};
|
|
1407
|
-
}
|
|
1408
|
-
return processNonGeneratorStatement(stmt, ctx);
|
|
1409
|
-
});
|
|
1410
|
-
const processedExports = module.exports.map((exp) => {
|
|
1411
|
-
if (exp.kind === "declaration") {
|
|
1412
|
-
if (exp.declaration.kind === "functionDeclaration" &&
|
|
1413
|
-
exp.declaration.isGenerator) {
|
|
1414
|
-
const generatorCtx = {
|
|
1415
|
-
...ctx,
|
|
1416
|
-
inGenerator: true,
|
|
1417
|
-
};
|
|
1418
|
-
const loweredBody = flattenStatement(processStatement(exp.declaration.body, generatorCtx));
|
|
1419
|
-
addResidualYieldDiagnostics(generatorCtx, loweredBody);
|
|
1420
|
-
return {
|
|
1421
|
-
...exp,
|
|
1422
|
-
declaration: {
|
|
1423
|
-
...exp.declaration,
|
|
1424
|
-
body: loweredBody,
|
|
1425
|
-
},
|
|
1426
|
-
};
|
|
1427
|
-
}
|
|
1428
|
-
return {
|
|
1429
|
-
...exp,
|
|
1430
|
-
declaration: processNonGeneratorStatement(exp.declaration, ctx),
|
|
1431
|
-
};
|
|
1432
|
-
}
|
|
1433
|
-
return exp;
|
|
1434
|
-
});
|
|
1435
|
-
return {
|
|
1436
|
-
module: {
|
|
1437
|
-
...module,
|
|
1438
|
-
body: processedBody,
|
|
1439
|
-
exports: processedExports,
|
|
1440
|
-
},
|
|
1441
|
-
diagnostics: ctx.diagnostics,
|
|
1442
|
-
};
|
|
1443
|
-
};
|
|
33
|
+
import { processModule } from "./yield-module-processing.js";
|
|
1444
34
|
/**
|
|
1445
35
|
* Run yield lowering pass on all modules.
|
|
1446
36
|
*
|