@flighthq/tool-compiler 0.5.1-edge.1687.b63c819
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/LICENSE.md +9 -0
- package/README.md +74 -0
- package/dist/packages/compiler-ambient/src/compilerAmbientSurface.d.ts +3 -0
- package/dist/packages/compiler-ambient/src/compilerAmbientSurface.d.ts.map +1 -0
- package/dist/packages/compiler-ambient/src/compilerAmbientSurface.js +564 -0
- package/dist/packages/compiler-ambient/src/compilerAmbientSurface.js.map +1 -0
- package/dist/packages/compiler-ambient/src/index.d.ts +2 -0
- package/dist/packages/compiler-ambient/src/index.d.ts.map +1 -0
- package/dist/packages/compiler-ambient/src/index.js +2 -0
- package/dist/packages/compiler-ambient/src/index.js.map +1 -0
- package/dist/packages/compiler-backend-cpp/src/cppAmbientMemberBinding.d.ts +3 -0
- package/dist/packages/compiler-backend-cpp/src/cppAmbientMemberBinding.d.ts.map +1 -0
- package/dist/packages/compiler-backend-cpp/src/cppAmbientMemberBinding.js +146 -0
- package/dist/packages/compiler-backend-cpp/src/cppAmbientMemberBinding.js.map +1 -0
- package/dist/packages/compiler-backend-cpp/src/cppBindingTypeInference.d.ts +3 -0
- package/dist/packages/compiler-backend-cpp/src/cppBindingTypeInference.d.ts.map +1 -0
- package/dist/packages/compiler-backend-cpp/src/cppBindingTypeInference.js +197 -0
- package/dist/packages/compiler-backend-cpp/src/cppBindingTypeInference.js.map +1 -0
- package/dist/packages/compiler-backend-cpp/src/cppCallableSignatureAbi.d.ts +8 -0
- package/dist/packages/compiler-backend-cpp/src/cppCallableSignatureAbi.d.ts.map +1 -0
- package/dist/packages/compiler-backend-cpp/src/cppCallableSignatureAbi.js +9 -0
- package/dist/packages/compiler-backend-cpp/src/cppCallableSignatureAbi.js.map +1 -0
- package/dist/packages/compiler-backend-cpp/src/cppClosureCapturePlan.d.ts +3 -0
- package/dist/packages/compiler-backend-cpp/src/cppClosureCapturePlan.d.ts.map +1 -0
- package/dist/packages/compiler-backend-cpp/src/cppClosureCapturePlan.js +109 -0
- package/dist/packages/compiler-backend-cpp/src/cppClosureCapturePlan.js.map +1 -0
- package/dist/packages/compiler-backend-cpp/src/cppCompilerBackend.d.ts +4 -0
- package/dist/packages/compiler-backend-cpp/src/cppCompilerBackend.d.ts.map +1 -0
- package/dist/packages/compiler-backend-cpp/src/cppCompilerBackend.js +16568 -0
- package/dist/packages/compiler-backend-cpp/src/cppCompilerBackend.js.map +1 -0
- package/dist/packages/compiler-backend-cpp/src/cppCompilerIdentity.d.ts +7 -0
- package/dist/packages/compiler-backend-cpp/src/cppCompilerIdentity.d.ts.map +1 -0
- package/dist/packages/compiler-backend-cpp/src/cppCompilerIdentity.js +176 -0
- package/dist/packages/compiler-backend-cpp/src/cppCompilerIdentity.js.map +1 -0
- package/dist/packages/compiler-backend-cpp/src/cppReferenceRepresentationPlan.d.ts +7 -0
- package/dist/packages/compiler-backend-cpp/src/cppReferenceRepresentationPlan.d.ts.map +1 -0
- package/dist/packages/compiler-backend-cpp/src/cppReferenceRepresentationPlan.js +1514 -0
- package/dist/packages/compiler-backend-cpp/src/cppReferenceRepresentationPlan.js.map +1 -0
- package/dist/packages/compiler-backend-cpp/src/cppRuntimeExternalSymbolBinding.d.ts +44 -0
- package/dist/packages/compiler-backend-cpp/src/cppRuntimeExternalSymbolBinding.d.ts.map +1 -0
- package/dist/packages/compiler-backend-cpp/src/cppRuntimeExternalSymbolBinding.js +1060 -0
- package/dist/packages/compiler-backend-cpp/src/cppRuntimeExternalSymbolBinding.js.map +1 -0
- package/dist/packages/compiler-backend-cpp/src/cppTupleRepresentation.d.ts +3 -0
- package/dist/packages/compiler-backend-cpp/src/cppTupleRepresentation.d.ts.map +1 -0
- package/dist/packages/compiler-backend-cpp/src/cppTupleRepresentation.js +13 -0
- package/dist/packages/compiler-backend-cpp/src/cppTupleRepresentation.js.map +1 -0
- package/dist/packages/compiler-backend-cpp/src/cppUnionRepresentationPlan.d.ts +66 -0
- package/dist/packages/compiler-backend-cpp/src/cppUnionRepresentationPlan.d.ts.map +1 -0
- package/dist/packages/compiler-backend-cpp/src/cppUnionRepresentationPlan.js +196 -0
- package/dist/packages/compiler-backend-cpp/src/cppUnionRepresentationPlan.js.map +1 -0
- package/dist/packages/compiler-backend-cpp/src/index.d.ts +6 -0
- package/dist/packages/compiler-backend-cpp/src/index.d.ts.map +1 -0
- package/dist/packages/compiler-backend-cpp/src/index.js +6 -0
- package/dist/packages/compiler-backend-cpp/src/index.js.map +1 -0
- package/dist/packages/compiler-backend-hx/src/haxeAmbientMemberBinding.d.ts +4 -0
- package/dist/packages/compiler-backend-hx/src/haxeAmbientMemberBinding.d.ts.map +1 -0
- package/dist/packages/compiler-backend-hx/src/haxeAmbientMemberBinding.js +160 -0
- package/dist/packages/compiler-backend-hx/src/haxeAmbientMemberBinding.js.map +1 -0
- package/dist/packages/compiler-backend-hx/src/haxeAsyncIterationLowering.d.ts +3 -0
- package/dist/packages/compiler-backend-hx/src/haxeAsyncIterationLowering.d.ts.map +1 -0
- package/dist/packages/compiler-backend-hx/src/haxeAsyncIterationLowering.js +129 -0
- package/dist/packages/compiler-backend-hx/src/haxeAsyncIterationLowering.js.map +1 -0
- package/dist/packages/compiler-backend-hx/src/haxeCompilerBackend.d.ts +5 -0
- package/dist/packages/compiler-backend-hx/src/haxeCompilerBackend.d.ts.map +1 -0
- package/dist/packages/compiler-backend-hx/src/haxeCompilerBackend.js +5172 -0
- package/dist/packages/compiler-backend-hx/src/haxeCompilerBackend.js.map +1 -0
- package/dist/packages/compiler-backend-hx/src/haxeCompilerEmittedSourceSyntax.d.ts +3 -0
- package/dist/packages/compiler-backend-hx/src/haxeCompilerEmittedSourceSyntax.d.ts.map +1 -0
- package/dist/packages/compiler-backend-hx/src/haxeCompilerEmittedSourceSyntax.js +8 -0
- package/dist/packages/compiler-backend-hx/src/haxeCompilerEmittedSourceSyntax.js.map +1 -0
- package/dist/packages/compiler-backend-hx/src/haxeCompilerIdentity.d.ts +3 -0
- package/dist/packages/compiler-backend-hx/src/haxeCompilerIdentity.d.ts.map +1 -0
- package/dist/packages/compiler-backend-hx/src/haxeCompilerIdentity.js +51 -0
- package/dist/packages/compiler-backend-hx/src/haxeCompilerIdentity.js.map +1 -0
- package/dist/packages/compiler-backend-hx/src/haxeCompilerTargetCompilationSmoke.d.ts +3 -0
- package/dist/packages/compiler-backend-hx/src/haxeCompilerTargetCompilationSmoke.d.ts.map +1 -0
- package/dist/packages/compiler-backend-hx/src/haxeCompilerTargetCompilationSmoke.js +8 -0
- package/dist/packages/compiler-backend-hx/src/haxeCompilerTargetCompilationSmoke.js.map +1 -0
- package/dist/packages/compiler-backend-hx/src/haxeExternEmission.d.ts +40 -0
- package/dist/packages/compiler-backend-hx/src/haxeExternEmission.d.ts.map +1 -0
- package/dist/packages/compiler-backend-hx/src/haxeExternEmission.js +968 -0
- package/dist/packages/compiler-backend-hx/src/haxeExternEmission.js.map +1 -0
- package/dist/packages/compiler-backend-hx/src/haxeRuntimeAbiManifest.d.ts +3 -0
- package/dist/packages/compiler-backend-hx/src/haxeRuntimeAbiManifest.d.ts.map +1 -0
- package/dist/packages/compiler-backend-hx/src/haxeRuntimeAbiManifest.js +53 -0
- package/dist/packages/compiler-backend-hx/src/haxeRuntimeAbiManifest.js.map +1 -0
- package/dist/packages/compiler-backend-hx/src/haxeRuntimeExternalConstructorAbi.d.ts +3 -0
- package/dist/packages/compiler-backend-hx/src/haxeRuntimeExternalConstructorAbi.d.ts.map +1 -0
- package/dist/packages/compiler-backend-hx/src/haxeRuntimeExternalConstructorAbi.js +64 -0
- package/dist/packages/compiler-backend-hx/src/haxeRuntimeExternalConstructorAbi.js.map +1 -0
- package/dist/packages/compiler-backend-hx/src/haxeRuntimeExternalSymbolBinding.d.ts +8 -0
- package/dist/packages/compiler-backend-hx/src/haxeRuntimeExternalSymbolBinding.d.ts.map +1 -0
- package/dist/packages/compiler-backend-hx/src/haxeRuntimeExternalSymbolBinding.js +803 -0
- package/dist/packages/compiler-backend-hx/src/haxeRuntimeExternalSymbolBinding.js.map +1 -0
- package/dist/packages/compiler-backend-hx/src/haxeRuntimeTaskCapability.d.ts +3 -0
- package/dist/packages/compiler-backend-hx/src/haxeRuntimeTaskCapability.d.ts.map +1 -0
- package/dist/packages/compiler-backend-hx/src/haxeRuntimeTaskCapability.js +66 -0
- package/dist/packages/compiler-backend-hx/src/haxeRuntimeTaskCapability.js.map +1 -0
- package/dist/packages/compiler-backend-hx/src/haxeTaskEmission.d.ts +3 -0
- package/dist/packages/compiler-backend-hx/src/haxeTaskEmission.d.ts.map +1 -0
- package/dist/packages/compiler-backend-hx/src/haxeTaskEmission.js +361 -0
- package/dist/packages/compiler-backend-hx/src/haxeTaskEmission.js.map +1 -0
- package/dist/packages/compiler-backend-hx/src/haxeTaskLowering.d.ts +4 -0
- package/dist/packages/compiler-backend-hx/src/haxeTaskLowering.d.ts.map +1 -0
- package/dist/packages/compiler-backend-hx/src/haxeTaskLowering.js +265 -0
- package/dist/packages/compiler-backend-hx/src/haxeTaskLowering.js.map +1 -0
- package/dist/packages/compiler-backend-hx/src/haxeTypeEmission.d.ts +16 -0
- package/dist/packages/compiler-backend-hx/src/haxeTypeEmission.d.ts.map +1 -0
- package/dist/packages/compiler-backend-hx/src/haxeTypeEmission.js +134 -0
- package/dist/packages/compiler-backend-hx/src/haxeTypeEmission.js.map +1 -0
- package/dist/packages/compiler-backend-hx/src/index.d.ts +13 -0
- package/dist/packages/compiler-backend-hx/src/index.d.ts.map +1 -0
- package/dist/packages/compiler-backend-hx/src/index.js +13 -0
- package/dist/packages/compiler-backend-hx/src/index.js.map +1 -0
- package/dist/packages/compiler-backend-rs/src/index.d.ts +8 -0
- package/dist/packages/compiler-backend-rs/src/index.d.ts.map +1 -0
- package/dist/packages/compiler-backend-rs/src/index.js +8 -0
- package/dist/packages/compiler-backend-rs/src/index.js.map +1 -0
- package/dist/packages/compiler-backend-rs/src/rustAmbientMemberBinding.d.ts +3 -0
- package/dist/packages/compiler-backend-rs/src/rustAmbientMemberBinding.d.ts.map +1 -0
- package/dist/packages/compiler-backend-rs/src/rustAmbientMemberBinding.js +99 -0
- package/dist/packages/compiler-backend-rs/src/rustAmbientMemberBinding.js.map +1 -0
- package/dist/packages/compiler-backend-rs/src/rustCompilerBackend.d.ts +5 -0
- package/dist/packages/compiler-backend-rs/src/rustCompilerBackend.d.ts.map +1 -0
- package/dist/packages/compiler-backend-rs/src/rustCompilerBackend.js +4555 -0
- package/dist/packages/compiler-backend-rs/src/rustCompilerBackend.js.map +1 -0
- package/dist/packages/compiler-backend-rs/src/rustCompilerEmittedSourceSyntax.d.ts +3 -0
- package/dist/packages/compiler-backend-rs/src/rustCompilerEmittedSourceSyntax.d.ts.map +1 -0
- package/dist/packages/compiler-backend-rs/src/rustCompilerEmittedSourceSyntax.js +8 -0
- package/dist/packages/compiler-backend-rs/src/rustCompilerEmittedSourceSyntax.js.map +1 -0
- package/dist/packages/compiler-backend-rs/src/rustCompilerIdentity.d.ts +4 -0
- package/dist/packages/compiler-backend-rs/src/rustCompilerIdentity.d.ts.map +1 -0
- package/dist/packages/compiler-backend-rs/src/rustCompilerIdentity.js +113 -0
- package/dist/packages/compiler-backend-rs/src/rustCompilerIdentity.js.map +1 -0
- package/dist/packages/compiler-backend-rs/src/rustCompilerTargetCompilationSmoke.d.ts +3 -0
- package/dist/packages/compiler-backend-rs/src/rustCompilerTargetCompilationSmoke.d.ts.map +1 -0
- package/dist/packages/compiler-backend-rs/src/rustCompilerTargetCompilationSmoke.js +8 -0
- package/dist/packages/compiler-backend-rs/src/rustCompilerTargetCompilationSmoke.js.map +1 -0
- package/dist/packages/compiler-backend-rs/src/rustOwnershipEvidence.d.ts +5 -0
- package/dist/packages/compiler-backend-rs/src/rustOwnershipEvidence.d.ts.map +1 -0
- package/dist/packages/compiler-backend-rs/src/rustOwnershipEvidence.js +345 -0
- package/dist/packages/compiler-backend-rs/src/rustOwnershipEvidence.js.map +1 -0
- package/dist/packages/compiler-backend-rs/src/rustRuntimeExternalConstructorAbi.d.ts +3 -0
- package/dist/packages/compiler-backend-rs/src/rustRuntimeExternalConstructorAbi.d.ts.map +1 -0
- package/dist/packages/compiler-backend-rs/src/rustRuntimeExternalConstructorAbi.js +38 -0
- package/dist/packages/compiler-backend-rs/src/rustRuntimeExternalConstructorAbi.js.map +1 -0
- package/dist/packages/compiler-backend-rs/src/rustRuntimeExternalSymbolBinding.d.ts +6 -0
- package/dist/packages/compiler-backend-rs/src/rustRuntimeExternalSymbolBinding.d.ts.map +1 -0
- package/dist/packages/compiler-backend-rs/src/rustRuntimeExternalSymbolBinding.js +301 -0
- package/dist/packages/compiler-backend-rs/src/rustRuntimeExternalSymbolBinding.js.map +1 -0
- package/dist/packages/compiler-canonical-form/src/compilerPortablePath.d.ts +2 -0
- package/dist/packages/compiler-canonical-form/src/compilerPortablePath.d.ts.map +1 -0
- package/dist/packages/compiler-canonical-form/src/compilerPortablePath.js +4 -0
- package/dist/packages/compiler-canonical-form/src/compilerPortablePath.js.map +1 -0
- package/dist/packages/compiler-canonical-form/src/compilerStructuralValue.d.ts +2 -0
- package/dist/packages/compiler-canonical-form/src/compilerStructuralValue.d.ts.map +1 -0
- package/dist/packages/compiler-canonical-form/src/compilerStructuralValue.js +63 -0
- package/dist/packages/compiler-canonical-form/src/compilerStructuralValue.js.map +1 -0
- package/dist/packages/compiler-canonical-form/src/compilerTextOrder.d.ts +2 -0
- package/dist/packages/compiler-canonical-form/src/compilerTextOrder.d.ts.map +1 -0
- package/dist/packages/compiler-canonical-form/src/compilerTextOrder.js +4 -0
- package/dist/packages/compiler-canonical-form/src/compilerTextOrder.js.map +1 -0
- package/dist/packages/compiler-canonical-form/src/index.d.ts +4 -0
- package/dist/packages/compiler-canonical-form/src/index.d.ts.map +1 -0
- package/dist/packages/compiler-canonical-form/src/index.js +4 -0
- package/dist/packages/compiler-canonical-form/src/index.js.map +1 -0
- package/dist/packages/compiler-check/src/compilerPackageCheck.d.ts +9 -0
- package/dist/packages/compiler-check/src/compilerPackageCheck.d.ts.map +1 -0
- package/dist/packages/compiler-check/src/compilerPackageCheck.js +417 -0
- package/dist/packages/compiler-check/src/compilerPackageCheck.js.map +1 -0
- package/dist/packages/compiler-check/src/index.d.ts +2 -0
- package/dist/packages/compiler-check/src/index.d.ts.map +1 -0
- package/dist/packages/compiler-check/src/index.js +2 -0
- package/dist/packages/compiler-check/src/index.js.map +1 -0
- package/dist/packages/compiler-closure/src/compilerClosureEvidence.d.ts +3 -0
- package/dist/packages/compiler-closure/src/compilerClosureEvidence.d.ts.map +1 -0
- package/dist/packages/compiler-closure/src/compilerClosureEvidence.js +469 -0
- package/dist/packages/compiler-closure/src/compilerClosureEvidence.js.map +1 -0
- package/dist/packages/compiler-closure/src/index.d.ts +2 -0
- package/dist/packages/compiler-closure/src/index.d.ts.map +1 -0
- package/dist/packages/compiler-closure/src/index.js +2 -0
- package/dist/packages/compiler-closure/src/index.js.map +1 -0
- package/dist/packages/compiler-command-line/src/compilerCommandLine.d.ts +12 -0
- package/dist/packages/compiler-command-line/src/compilerCommandLine.d.ts.map +1 -0
- package/dist/packages/compiler-command-line/src/compilerCommandLine.js +549 -0
- package/dist/packages/compiler-command-line/src/compilerCommandLine.js.map +1 -0
- package/dist/packages/compiler-command-line/src/compilerCommandLineEntryPoint.d.ts +5 -0
- package/dist/packages/compiler-command-line/src/compilerCommandLineEntryPoint.d.ts.map +1 -0
- package/dist/packages/compiler-command-line/src/compilerCommandLineEntryPoint.js +134 -0
- package/dist/packages/compiler-command-line/src/compilerCommandLineEntryPoint.js.map +1 -0
- package/dist/packages/compiler-command-line/src/index.d.ts +3 -0
- package/dist/packages/compiler-command-line/src/index.d.ts.map +1 -0
- package/dist/packages/compiler-command-line/src/index.js +3 -0
- package/dist/packages/compiler-command-line/src/index.js.map +1 -0
- package/dist/packages/compiler-completion/src/compilerAsyncTaskCompletion.d.ts +6 -0
- package/dist/packages/compiler-completion/src/compilerAsyncTaskCompletion.d.ts.map +1 -0
- package/dist/packages/compiler-completion/src/compilerAsyncTaskCompletion.js +89 -0
- package/dist/packages/compiler-completion/src/compilerAsyncTaskCompletion.js.map +1 -0
- package/dist/packages/compiler-completion/src/compilerCatchCompletion.d.ts +6 -0
- package/dist/packages/compiler-completion/src/compilerCatchCompletion.d.ts.map +1 -0
- package/dist/packages/compiler-completion/src/compilerCatchCompletion.js +77 -0
- package/dist/packages/compiler-completion/src/compilerCatchCompletion.js.map +1 -0
- package/dist/packages/compiler-completion/src/compilerCompletionSet.d.ts +6 -0
- package/dist/packages/compiler-completion/src/compilerCompletionSet.d.ts.map +1 -0
- package/dist/packages/compiler-completion/src/compilerCompletionSet.js +110 -0
- package/dist/packages/compiler-completion/src/compilerCompletionSet.js.map +1 -0
- package/dist/packages/compiler-completion/src/compilerFinallyCompletion.d.ts +3 -0
- package/dist/packages/compiler-completion/src/compilerFinallyCompletion.d.ts.map +1 -0
- package/dist/packages/compiler-completion/src/compilerFinallyCompletion.js +13 -0
- package/dist/packages/compiler-completion/src/compilerFinallyCompletion.js.map +1 -0
- package/dist/packages/compiler-completion/src/compilerStatementCompletion.d.ts +4 -0
- package/dist/packages/compiler-completion/src/compilerStatementCompletion.d.ts.map +1 -0
- package/dist/packages/compiler-completion/src/compilerStatementCompletion.js +181 -0
- package/dist/packages/compiler-completion/src/compilerStatementCompletion.js.map +1 -0
- package/dist/packages/compiler-completion/src/compilerStatementValueCompletion.d.ts +5 -0
- package/dist/packages/compiler-completion/src/compilerStatementValueCompletion.d.ts.map +1 -0
- package/dist/packages/compiler-completion/src/compilerStatementValueCompletion.js +41 -0
- package/dist/packages/compiler-completion/src/compilerStatementValueCompletion.js.map +1 -0
- package/dist/packages/compiler-completion/src/compilerValueCompletion.d.ts +8 -0
- package/dist/packages/compiler-completion/src/compilerValueCompletion.d.ts.map +1 -0
- package/dist/packages/compiler-completion/src/compilerValueCompletion.js +208 -0
- package/dist/packages/compiler-completion/src/compilerValueCompletion.js.map +1 -0
- package/dist/packages/compiler-completion/src/index.d.ts +8 -0
- package/dist/packages/compiler-completion/src/index.d.ts.map +1 -0
- package/dist/packages/compiler-completion/src/index.js +8 -0
- package/dist/packages/compiler-completion/src/index.js.map +1 -0
- package/dist/packages/compiler-emission/src/compilerEmittedSourceSyntax.d.ts +4 -0
- package/dist/packages/compiler-emission/src/compilerEmittedSourceSyntax.d.ts.map +1 -0
- package/dist/packages/compiler-emission/src/compilerEmittedSourceSyntax.js +122 -0
- package/dist/packages/compiler-emission/src/compilerEmittedSourceSyntax.js.map +1 -0
- package/dist/packages/compiler-emission/src/compilerGeneratedFileProvenance.d.ts +3 -0
- package/dist/packages/compiler-emission/src/compilerGeneratedFileProvenance.d.ts.map +1 -0
- package/dist/packages/compiler-emission/src/compilerGeneratedFileProvenance.js +17 -0
- package/dist/packages/compiler-emission/src/compilerGeneratedFileProvenance.js.map +1 -0
- package/dist/packages/compiler-emission/src/compilerLiteralUnion.d.ts +3 -0
- package/dist/packages/compiler-emission/src/compilerLiteralUnion.d.ts.map +1 -0
- package/dist/packages/compiler-emission/src/compilerLiteralUnion.js +20 -0
- package/dist/packages/compiler-emission/src/compilerLiteralUnion.js.map +1 -0
- package/dist/packages/compiler-emission/src/compilerNullableFlowGuard.d.ts +4 -0
- package/dist/packages/compiler-emission/src/compilerNullableFlowGuard.d.ts.map +1 -0
- package/dist/packages/compiler-emission/src/compilerNullableFlowGuard.js +32 -0
- package/dist/packages/compiler-emission/src/compilerNullableFlowGuard.js.map +1 -0
- package/dist/packages/compiler-emission/src/compilerSourceEmission.d.ts +16 -0
- package/dist/packages/compiler-emission/src/compilerSourceEmission.d.ts.map +1 -0
- package/dist/packages/compiler-emission/src/compilerSourceEmission.js +176 -0
- package/dist/packages/compiler-emission/src/compilerSourceEmission.js.map +1 -0
- package/dist/packages/compiler-emission/src/compilerTargetCompilationSmoke.d.ts +4 -0
- package/dist/packages/compiler-emission/src/compilerTargetCompilationSmoke.d.ts.map +1 -0
- package/dist/packages/compiler-emission/src/compilerTargetCompilationSmoke.js +114 -0
- package/dist/packages/compiler-emission/src/compilerTargetCompilationSmoke.js.map +1 -0
- package/dist/packages/compiler-emission/src/compilerTargetNameAllocation.d.ts +5 -0
- package/dist/packages/compiler-emission/src/compilerTargetNameAllocation.d.ts.map +1 -0
- package/dist/packages/compiler-emission/src/compilerTargetNameAllocation.js +449 -0
- package/dist/packages/compiler-emission/src/compilerTargetNameAllocation.js.map +1 -0
- package/dist/packages/compiler-emission/src/index.d.ts +8 -0
- package/dist/packages/compiler-emission/src/index.d.ts.map +1 -0
- package/dist/packages/compiler-emission/src/index.js +8 -0
- package/dist/packages/compiler-emission/src/index.js.map +1 -0
- package/dist/packages/compiler-inventory/src/compilerInventoryFailure.d.ts +4 -0
- package/dist/packages/compiler-inventory/src/compilerInventoryFailure.d.ts.map +1 -0
- package/dist/packages/compiler-inventory/src/compilerInventoryFailure.js +42 -0
- package/dist/packages/compiler-inventory/src/compilerInventoryFailure.js.map +1 -0
- package/dist/packages/compiler-inventory/src/compilerModuleResolution.d.ts +4 -0
- package/dist/packages/compiler-inventory/src/compilerModuleResolution.d.ts.map +1 -0
- package/dist/packages/compiler-inventory/src/compilerModuleResolution.js +74 -0
- package/dist/packages/compiler-inventory/src/compilerModuleResolution.js.map +1 -0
- package/dist/packages/compiler-inventory/src/fileSystemWorkspaceSource.d.ts +3 -0
- package/dist/packages/compiler-inventory/src/fileSystemWorkspaceSource.d.ts.map +1 -0
- package/dist/packages/compiler-inventory/src/fileSystemWorkspaceSource.js +20 -0
- package/dist/packages/compiler-inventory/src/fileSystemWorkspaceSource.js.map +1 -0
- package/dist/packages/compiler-inventory/src/flightPackageEligibility.d.ts +5 -0
- package/dist/packages/compiler-inventory/src/flightPackageEligibility.d.ts.map +1 -0
- package/dist/packages/compiler-inventory/src/flightPackageEligibility.js +174 -0
- package/dist/packages/compiler-inventory/src/flightPackageEligibility.js.map +1 -0
- package/dist/packages/compiler-inventory/src/flightPackageExclusion.d.ts +3 -0
- package/dist/packages/compiler-inventory/src/flightPackageExclusion.d.ts.map +1 -0
- package/dist/packages/compiler-inventory/src/flightPackageExclusion.js +79 -0
- package/dist/packages/compiler-inventory/src/flightPackageExclusion.js.map +1 -0
- package/dist/packages/compiler-inventory/src/flightPackageExportLane.d.ts +4 -0
- package/dist/packages/compiler-inventory/src/flightPackageExportLane.d.ts.map +1 -0
- package/dist/packages/compiler-inventory/src/flightPackageExportLane.js +30 -0
- package/dist/packages/compiler-inventory/src/flightPackageExportLane.js.map +1 -0
- package/dist/packages/compiler-inventory/src/flightPackageExportManifest.d.ts +3 -0
- package/dist/packages/compiler-inventory/src/flightPackageExportManifest.d.ts.map +1 -0
- package/dist/packages/compiler-inventory/src/flightPackageExportManifest.js +90 -0
- package/dist/packages/compiler-inventory/src/flightPackageExportManifest.js.map +1 -0
- package/dist/packages/compiler-inventory/src/flightPackageHostFacts.d.ts +3 -0
- package/dist/packages/compiler-inventory/src/flightPackageHostFacts.d.ts.map +1 -0
- package/dist/packages/compiler-inventory/src/flightPackageHostFacts.js +33 -0
- package/dist/packages/compiler-inventory/src/flightPackageHostFacts.js.map +1 -0
- package/dist/packages/compiler-inventory/src/flightPackageImport.d.ts +3 -0
- package/dist/packages/compiler-inventory/src/flightPackageImport.d.ts.map +1 -0
- package/dist/packages/compiler-inventory/src/flightPackageImport.js +82 -0
- package/dist/packages/compiler-inventory/src/flightPackageImport.js.map +1 -0
- package/dist/packages/compiler-inventory/src/flightPackageManifest.d.ts +3 -0
- package/dist/packages/compiler-inventory/src/flightPackageManifest.d.ts.map +1 -0
- package/dist/packages/compiler-inventory/src/flightPackageManifest.js +116 -0
- package/dist/packages/compiler-inventory/src/flightPackageManifest.js.map +1 -0
- package/dist/packages/compiler-inventory/src/flightWorkspaceCompilationInput.d.ts +4 -0
- package/dist/packages/compiler-inventory/src/flightWorkspaceCompilationInput.d.ts.map +1 -0
- package/dist/packages/compiler-inventory/src/flightWorkspaceCompilationInput.js +315 -0
- package/dist/packages/compiler-inventory/src/flightWorkspaceCompilationInput.js.map +1 -0
- package/dist/packages/compiler-inventory/src/flightWorkspaceInventory.d.ts +3 -0
- package/dist/packages/compiler-inventory/src/flightWorkspaceInventory.d.ts.map +1 -0
- package/dist/packages/compiler-inventory/src/flightWorkspaceInventory.js +591 -0
- package/dist/packages/compiler-inventory/src/flightWorkspaceInventory.js.map +1 -0
- package/dist/packages/compiler-inventory/src/gitCheckoutRevision.d.ts +2 -0
- package/dist/packages/compiler-inventory/src/gitCheckoutRevision.d.ts.map +1 -0
- package/dist/packages/compiler-inventory/src/gitCheckoutRevision.js +20 -0
- package/dist/packages/compiler-inventory/src/gitCheckoutRevision.js.map +1 -0
- package/dist/packages/compiler-inventory/src/index.d.ts +17 -0
- package/dist/packages/compiler-inventory/src/index.d.ts.map +1 -0
- package/dist/packages/compiler-inventory/src/index.js +17 -0
- package/dist/packages/compiler-inventory/src/index.js.map +1 -0
- package/dist/packages/compiler-inventory/src/memoryWorkspaceSource.d.ts +3 -0
- package/dist/packages/compiler-inventory/src/memoryWorkspaceSource.d.ts.map +1 -0
- package/dist/packages/compiler-inventory/src/memoryWorkspaceSource.js +61 -0
- package/dist/packages/compiler-inventory/src/memoryWorkspaceSource.js.map +1 -0
- package/dist/packages/compiler-inventory/src/typeScriptHostEndpointInventory.d.ts +3 -0
- package/dist/packages/compiler-inventory/src/typeScriptHostEndpointInventory.d.ts.map +1 -0
- package/dist/packages/compiler-inventory/src/typeScriptHostEndpointInventory.js +138 -0
- package/dist/packages/compiler-inventory/src/typeScriptHostEndpointInventory.js.map +1 -0
- package/dist/packages/compiler-inventory/src/typeScriptProject.d.ts +3 -0
- package/dist/packages/compiler-inventory/src/typeScriptProject.d.ts.map +1 -0
- package/dist/packages/compiler-inventory/src/typeScriptProject.js +28 -0
- package/dist/packages/compiler-inventory/src/typeScriptProject.js.map +1 -0
- package/dist/packages/compiler-inventory/src/typeScriptRuntimeBinding.d.ts +7 -0
- package/dist/packages/compiler-inventory/src/typeScriptRuntimeBinding.d.ts.map +1 -0
- package/dist/packages/compiler-inventory/src/typeScriptRuntimeBinding.js +67 -0
- package/dist/packages/compiler-inventory/src/typeScriptRuntimeBinding.js.map +1 -0
- package/dist/packages/compiler-ir-traversal/src/compilerIntermediateRepresentationTraversal.d.ts +5 -0
- package/dist/packages/compiler-ir-traversal/src/compilerIntermediateRepresentationTraversal.d.ts.map +1 -0
- package/dist/packages/compiler-ir-traversal/src/compilerIntermediateRepresentationTraversal.js +469 -0
- package/dist/packages/compiler-ir-traversal/src/compilerIntermediateRepresentationTraversal.js.map +1 -0
- package/dist/packages/compiler-ir-traversal/src/compilerIntermediateRepresentationTraversalPath.d.ts +3 -0
- package/dist/packages/compiler-ir-traversal/src/compilerIntermediateRepresentationTraversalPath.d.ts.map +1 -0
- package/dist/packages/compiler-ir-traversal/src/compilerIntermediateRepresentationTraversalPath.js +14 -0
- package/dist/packages/compiler-ir-traversal/src/compilerIntermediateRepresentationTraversalPath.js.map +1 -0
- package/dist/packages/compiler-ir-traversal/src/index.d.ts +3 -0
- package/dist/packages/compiler-ir-traversal/src/index.d.ts.map +1 -0
- package/dist/packages/compiler-ir-traversal/src/index.js +3 -0
- package/dist/packages/compiler-ir-traversal/src/index.js.map +1 -0
- package/dist/packages/compiler-ir-validation/src/compilerIrModuleStructure.d.ts +3 -0
- package/dist/packages/compiler-ir-validation/src/compilerIrModuleStructure.d.ts.map +1 -0
- package/dist/packages/compiler-ir-validation/src/compilerIrModuleStructure.js +1258 -0
- package/dist/packages/compiler-ir-validation/src/compilerIrModuleStructure.js.map +1 -0
- package/dist/packages/compiler-ir-validation/src/index.d.ts +2 -0
- package/dist/packages/compiler-ir-validation/src/index.d.ts.map +1 -0
- package/dist/packages/compiler-ir-validation/src/index.js +2 -0
- package/dist/packages/compiler-ir-validation/src/index.js.map +1 -0
- package/dist/packages/compiler-lowering/src/compilerArrayBindingPatternLowering.d.ts +3 -0
- package/dist/packages/compiler-lowering/src/compilerArrayBindingPatternLowering.d.ts.map +1 -0
- package/dist/packages/compiler-lowering/src/compilerArrayBindingPatternLowering.js +717 -0
- package/dist/packages/compiler-lowering/src/compilerArrayBindingPatternLowering.js.map +1 -0
- package/dist/packages/compiler-lowering/src/compilerArrayBindingPatternPresence.d.ts +3 -0
- package/dist/packages/compiler-lowering/src/compilerArrayBindingPatternPresence.d.ts.map +1 -0
- package/dist/packages/compiler-lowering/src/compilerArrayBindingPatternPresence.js +162 -0
- package/dist/packages/compiler-lowering/src/compilerArrayBindingPatternPresence.js.map +1 -0
- package/dist/packages/compiler-lowering/src/compilerAwaitConditionHoistingLowering.d.ts +3 -0
- package/dist/packages/compiler-lowering/src/compilerAwaitConditionHoistingLowering.d.ts.map +1 -0
- package/dist/packages/compiler-lowering/src/compilerAwaitConditionHoistingLowering.js +721 -0
- package/dist/packages/compiler-lowering/src/compilerAwaitConditionHoistingLowering.js.map +1 -0
- package/dist/packages/compiler-lowering/src/compilerBindingPatternLowering.d.ts +4 -0
- package/dist/packages/compiler-lowering/src/compilerBindingPatternLowering.d.ts.map +1 -0
- package/dist/packages/compiler-lowering/src/compilerBindingPatternLowering.js +43 -0
- package/dist/packages/compiler-lowering/src/compilerBindingPatternLowering.js.map +1 -0
- package/dist/packages/compiler-lowering/src/compilerCStyleForLowering.d.ts +3 -0
- package/dist/packages/compiler-lowering/src/compilerCStyleForLowering.d.ts.map +1 -0
- package/dist/packages/compiler-lowering/src/compilerCStyleForLowering.js +591 -0
- package/dist/packages/compiler-lowering/src/compilerCStyleForLowering.js.map +1 -0
- package/dist/packages/compiler-lowering/src/compilerCatchAwaitHoistingLowering.d.ts +3 -0
- package/dist/packages/compiler-lowering/src/compilerCatchAwaitHoistingLowering.d.ts.map +1 -0
- package/dist/packages/compiler-lowering/src/compilerCatchAwaitHoistingLowering.js +244 -0
- package/dist/packages/compiler-lowering/src/compilerCatchAwaitHoistingLowering.js.map +1 -0
- package/dist/packages/compiler-lowering/src/compilerClassInitialization.d.ts +4 -0
- package/dist/packages/compiler-lowering/src/compilerClassInitialization.d.ts.map +1 -0
- package/dist/packages/compiler-lowering/src/compilerClassInitialization.js +102 -0
- package/dist/packages/compiler-lowering/src/compilerClassInitialization.js.map +1 -0
- package/dist/packages/compiler-lowering/src/compilerExtraArgumentErasureLowering.d.ts +3 -0
- package/dist/packages/compiler-lowering/src/compilerExtraArgumentErasureLowering.d.ts.map +1 -0
- package/dist/packages/compiler-lowering/src/compilerExtraArgumentErasureLowering.js +156 -0
- package/dist/packages/compiler-lowering/src/compilerExtraArgumentErasureLowering.js.map +1 -0
- package/dist/packages/compiler-lowering/src/compilerFinallyAwaitHoistingLowering.d.ts +3 -0
- package/dist/packages/compiler-lowering/src/compilerFinallyAwaitHoistingLowering.d.ts.map +1 -0
- package/dist/packages/compiler-lowering/src/compilerFinallyAwaitHoistingLowering.js +255 -0
- package/dist/packages/compiler-lowering/src/compilerFinallyAwaitHoistingLowering.js.map +1 -0
- package/dist/packages/compiler-lowering/src/compilerInterfaceInheritanceLowering.d.ts +3 -0
- package/dist/packages/compiler-lowering/src/compilerInterfaceInheritanceLowering.d.ts.map +1 -0
- package/dist/packages/compiler-lowering/src/compilerInterfaceInheritanceLowering.js +1062 -0
- package/dist/packages/compiler-lowering/src/compilerInterfaceInheritanceLowering.js.map +1 -0
- package/dist/packages/compiler-lowering/src/compilerLoweringPass.d.ts +5 -0
- package/dist/packages/compiler-lowering/src/compilerLoweringPass.d.ts.map +1 -0
- package/dist/packages/compiler-lowering/src/compilerLoweringPass.js +133 -0
- package/dist/packages/compiler-lowering/src/compilerLoweringPass.js.map +1 -0
- package/dist/packages/compiler-lowering/src/compilerObjectBindingPatternLowering.d.ts +3 -0
- package/dist/packages/compiler-lowering/src/compilerObjectBindingPatternLowering.d.ts.map +1 -0
- package/dist/packages/compiler-lowering/src/compilerObjectBindingPatternLowering.js +589 -0
- package/dist/packages/compiler-lowering/src/compilerObjectBindingPatternLowering.js.map +1 -0
- package/dist/packages/compiler-lowering/src/compilerSwitchClauseCompletion.d.ts +3 -0
- package/dist/packages/compiler-lowering/src/compilerSwitchClauseCompletion.d.ts.map +1 -0
- package/dist/packages/compiler-lowering/src/compilerSwitchClauseCompletion.js +71 -0
- package/dist/packages/compiler-lowering/src/compilerSwitchClauseCompletion.js.map +1 -0
- package/dist/packages/compiler-lowering/src/compilerSwitchFallthroughLowering.d.ts +3 -0
- package/dist/packages/compiler-lowering/src/compilerSwitchFallthroughLowering.d.ts.map +1 -0
- package/dist/packages/compiler-lowering/src/compilerSwitchFallthroughLowering.js +810 -0
- package/dist/packages/compiler-lowering/src/compilerSwitchFallthroughLowering.js.map +1 -0
- package/dist/packages/compiler-lowering/src/compilerSwitchSuspensionLowering.d.ts +3 -0
- package/dist/packages/compiler-lowering/src/compilerSwitchSuspensionLowering.d.ts.map +1 -0
- package/dist/packages/compiler-lowering/src/compilerSwitchSuspensionLowering.js +226 -0
- package/dist/packages/compiler-lowering/src/compilerSwitchSuspensionLowering.js.map +1 -0
- package/dist/packages/compiler-lowering/src/compilerVariableHoistingInitialization.d.ts +3 -0
- package/dist/packages/compiler-lowering/src/compilerVariableHoistingInitialization.d.ts.map +1 -0
- package/dist/packages/compiler-lowering/src/compilerVariableHoistingInitialization.js +724 -0
- package/dist/packages/compiler-lowering/src/compilerVariableHoistingInitialization.js.map +1 -0
- package/dist/packages/compiler-lowering/src/compilerVariableHoistingLowering.d.ts +3 -0
- package/dist/packages/compiler-lowering/src/compilerVariableHoistingLowering.d.ts.map +1 -0
- package/dist/packages/compiler-lowering/src/compilerVariableHoistingLowering.js +797 -0
- package/dist/packages/compiler-lowering/src/compilerVariableHoistingLowering.js.map +1 -0
- package/dist/packages/compiler-lowering/src/compilerVariableInitializationCompletion.d.ts +9 -0
- package/dist/packages/compiler-lowering/src/compilerVariableInitializationCompletion.d.ts.map +1 -0
- package/dist/packages/compiler-lowering/src/compilerVariableInitializationCompletion.js +42 -0
- package/dist/packages/compiler-lowering/src/compilerVariableInitializationCompletion.js.map +1 -0
- package/dist/packages/compiler-lowering/src/index.d.ts +17 -0
- package/dist/packages/compiler-lowering/src/index.d.ts.map +1 -0
- package/dist/packages/compiler-lowering/src/index.js +17 -0
- package/dist/packages/compiler-lowering/src/index.js.map +1 -0
- package/dist/packages/compiler-module/src/compilerModuleEvaluation.d.ts +4 -0
- package/dist/packages/compiler-module/src/compilerModuleEvaluation.d.ts.map +1 -0
- package/dist/packages/compiler-module/src/compilerModuleEvaluation.js +506 -0
- package/dist/packages/compiler-module/src/compilerModuleEvaluation.js.map +1 -0
- package/dist/packages/compiler-module/src/compilerModuleFacadeIdentity.d.ts +4 -0
- package/dist/packages/compiler-module/src/compilerModuleFacadeIdentity.d.ts.map +1 -0
- package/dist/packages/compiler-module/src/compilerModuleFacadeIdentity.js +182 -0
- package/dist/packages/compiler-module/src/compilerModuleFacadeIdentity.js.map +1 -0
- package/dist/packages/compiler-module/src/compilerModuleFacadeLowering.d.ts +4 -0
- package/dist/packages/compiler-module/src/compilerModuleFacadeLowering.d.ts.map +1 -0
- package/dist/packages/compiler-module/src/compilerModuleFacadeLowering.js +466 -0
- package/dist/packages/compiler-module/src/compilerModuleFacadeLowering.js.map +1 -0
- package/dist/packages/compiler-module/src/compilerModuleFacadeRequirement.d.ts +3 -0
- package/dist/packages/compiler-module/src/compilerModuleFacadeRequirement.d.ts.map +1 -0
- package/dist/packages/compiler-module/src/compilerModuleFacadeRequirement.js +28 -0
- package/dist/packages/compiler-module/src/compilerModuleFacadeRequirement.js.map +1 -0
- package/dist/packages/compiler-module/src/index.d.ts +5 -0
- package/dist/packages/compiler-module/src/index.d.ts.map +1 -0
- package/dist/packages/compiler-module/src/index.js +5 -0
- package/dist/packages/compiler-module/src/index.js.map +1 -0
- package/dist/packages/compiler-orchestration/src/compilerOrchestration.d.ts +8 -0
- package/dist/packages/compiler-orchestration/src/compilerOrchestration.d.ts.map +1 -0
- package/dist/packages/compiler-orchestration/src/compilerOrchestration.js +161 -0
- package/dist/packages/compiler-orchestration/src/compilerOrchestration.js.map +1 -0
- package/dist/packages/compiler-orchestration/src/compilerPackageCompilation.d.ts +4 -0
- package/dist/packages/compiler-orchestration/src/compilerPackageCompilation.d.ts.map +1 -0
- package/dist/packages/compiler-orchestration/src/compilerPackageCompilation.js +745 -0
- package/dist/packages/compiler-orchestration/src/compilerPackageCompilation.js.map +1 -0
- package/dist/packages/compiler-orchestration/src/flightWorkspaceCompilation.d.ts +3 -0
- package/dist/packages/compiler-orchestration/src/flightWorkspaceCompilation.d.ts.map +1 -0
- package/dist/packages/compiler-orchestration/src/flightWorkspaceCompilation.js +14 -0
- package/dist/packages/compiler-orchestration/src/flightWorkspaceCompilation.js.map +1 -0
- package/dist/packages/compiler-orchestration/src/index.d.ts +4 -0
- package/dist/packages/compiler-orchestration/src/index.d.ts.map +1 -0
- package/dist/packages/compiler-orchestration/src/index.js +4 -0
- package/dist/packages/compiler-orchestration/src/index.js.map +1 -0
- package/dist/packages/compiler-patch/src/compilerSemanticPatch.d.ts +6 -0
- package/dist/packages/compiler-patch/src/compilerSemanticPatch.d.ts.map +1 -0
- package/dist/packages/compiler-patch/src/compilerSemanticPatch.js +316 -0
- package/dist/packages/compiler-patch/src/compilerSemanticPatch.js.map +1 -0
- package/dist/packages/compiler-patch/src/index.d.ts +2 -0
- package/dist/packages/compiler-patch/src/index.d.ts.map +1 -0
- package/dist/packages/compiler-patch/src/index.js +2 -0
- package/dist/packages/compiler-patch/src/index.js.map +1 -0
- package/dist/packages/compiler-provenance/src/index.d.ts +2 -0
- package/dist/packages/compiler-provenance/src/index.d.ts.map +1 -0
- package/dist/packages/compiler-provenance/src/index.js +2 -0
- package/dist/packages/compiler-provenance/src/index.js.map +1 -0
- package/dist/packages/compiler-provenance/src/sourceFingerprint.d.ts +7 -0
- package/dist/packages/compiler-provenance/src/sourceFingerprint.d.ts.map +1 -0
- package/dist/packages/compiler-provenance/src/sourceFingerprint.js +58 -0
- package/dist/packages/compiler-provenance/src/sourceFingerprint.js.map +1 -0
- package/dist/packages/compiler-runtime-contract/src/compilerRuntimeExternalConstructorAbiCompleteness.d.ts +4 -0
- package/dist/packages/compiler-runtime-contract/src/compilerRuntimeExternalConstructorAbiCompleteness.d.ts.map +1 -0
- package/dist/packages/compiler-runtime-contract/src/compilerRuntimeExternalConstructorAbiCompleteness.js +110 -0
- package/dist/packages/compiler-runtime-contract/src/compilerRuntimeExternalConstructorAbiCompleteness.js.map +1 -0
- package/dist/packages/compiler-runtime-contract/src/compilerRuntimeExternalConstructorReachability.d.ts +3 -0
- package/dist/packages/compiler-runtime-contract/src/compilerRuntimeExternalConstructorReachability.d.ts.map +1 -0
- package/dist/packages/compiler-runtime-contract/src/compilerRuntimeExternalConstructorReachability.js +42 -0
- package/dist/packages/compiler-runtime-contract/src/compilerRuntimeExternalConstructorReachability.js.map +1 -0
- package/dist/packages/compiler-runtime-contract/src/compilerRuntimeExternalSymbolCompleteness.d.ts +4 -0
- package/dist/packages/compiler-runtime-contract/src/compilerRuntimeExternalSymbolCompleteness.d.ts.map +1 -0
- package/dist/packages/compiler-runtime-contract/src/compilerRuntimeExternalSymbolCompleteness.js +64 -0
- package/dist/packages/compiler-runtime-contract/src/compilerRuntimeExternalSymbolCompleteness.js.map +1 -0
- package/dist/packages/compiler-runtime-contract/src/compilerRuntimeExternalSymbolReachability.d.ts +3 -0
- package/dist/packages/compiler-runtime-contract/src/compilerRuntimeExternalSymbolReachability.d.ts.map +1 -0
- package/dist/packages/compiler-runtime-contract/src/compilerRuntimeExternalSymbolReachability.js +89 -0
- package/dist/packages/compiler-runtime-contract/src/compilerRuntimeExternalSymbolReachability.js.map +1 -0
- package/dist/packages/compiler-runtime-contract/src/compilerRuntimeTaskCapability.d.ts +6 -0
- package/dist/packages/compiler-runtime-contract/src/compilerRuntimeTaskCapability.d.ts.map +1 -0
- package/dist/packages/compiler-runtime-contract/src/compilerRuntimeTaskCapability.js +247 -0
- package/dist/packages/compiler-runtime-contract/src/compilerRuntimeTaskCapability.js.map +1 -0
- package/dist/packages/compiler-runtime-contract/src/index.d.ts +6 -0
- package/dist/packages/compiler-runtime-contract/src/index.d.ts.map +1 -0
- package/dist/packages/compiler-runtime-contract/src/index.js +6 -0
- package/dist/packages/compiler-runtime-contract/src/index.js.map +1 -0
- package/dist/packages/compiler-semantic/src/compilerIrStaticFacts.d.ts +4 -0
- package/dist/packages/compiler-semantic/src/compilerIrStaticFacts.d.ts.map +1 -0
- package/dist/packages/compiler-semantic/src/compilerIrStaticFacts.js +396 -0
- package/dist/packages/compiler-semantic/src/compilerIrStaticFacts.js.map +1 -0
- package/dist/packages/compiler-semantic/src/compilerIrTypeMemberEvidence.d.ts +4 -0
- package/dist/packages/compiler-semantic/src/compilerIrTypeMemberEvidence.d.ts.map +1 -0
- package/dist/packages/compiler-semantic/src/compilerIrTypeMemberEvidence.js +63 -0
- package/dist/packages/compiler-semantic/src/compilerIrTypeMemberEvidence.js.map +1 -0
- package/dist/packages/compiler-semantic/src/compilerOperatorDomainEvidence.d.ts +4 -0
- package/dist/packages/compiler-semantic/src/compilerOperatorDomainEvidence.d.ts.map +1 -0
- package/dist/packages/compiler-semantic/src/compilerOperatorDomainEvidence.js +76 -0
- package/dist/packages/compiler-semantic/src/compilerOperatorDomainEvidence.js.map +1 -0
- package/dist/packages/compiler-semantic/src/compilerStaticNumericArithmetic.d.ts +7 -0
- package/dist/packages/compiler-semantic/src/compilerStaticNumericArithmetic.d.ts.map +1 -0
- package/dist/packages/compiler-semantic/src/compilerStaticNumericArithmetic.js +107 -0
- package/dist/packages/compiler-semantic/src/compilerStaticNumericArithmetic.js.map +1 -0
- package/dist/packages/compiler-semantic/src/compilerTypeScriptForInKeyEvidence.d.ts +4 -0
- package/dist/packages/compiler-semantic/src/compilerTypeScriptForInKeyEvidence.d.ts.map +1 -0
- package/dist/packages/compiler-semantic/src/compilerTypeScriptForInKeyEvidence.js +159 -0
- package/dist/packages/compiler-semantic/src/compilerTypeScriptForInKeyEvidence.js.map +1 -0
- package/dist/packages/compiler-semantic/src/compilerTypeScriptInvocationSemantics.d.ts +4 -0
- package/dist/packages/compiler-semantic/src/compilerTypeScriptInvocationSemantics.d.ts.map +1 -0
- package/dist/packages/compiler-semantic/src/compilerTypeScriptInvocationSemantics.js +31 -0
- package/dist/packages/compiler-semantic/src/compilerTypeScriptInvocationSemantics.js.map +1 -0
- package/dist/packages/compiler-semantic/src/compilerTypeScriptSyntacticTypeEvidence.d.ts +8 -0
- package/dist/packages/compiler-semantic/src/compilerTypeScriptSyntacticTypeEvidence.d.ts.map +1 -0
- package/dist/packages/compiler-semantic/src/compilerTypeScriptSyntacticTypeEvidence.js +83 -0
- package/dist/packages/compiler-semantic/src/compilerTypeScriptSyntacticTypeEvidence.js.map +1 -0
- package/dist/packages/compiler-semantic/src/index.d.ts +4 -0
- package/dist/packages/compiler-semantic/src/index.d.ts.map +1 -0
- package/dist/packages/compiler-semantic/src/index.js +4 -0
- package/dist/packages/compiler-semantic/src/index.js.map +1 -0
- package/dist/packages/compiler-semantic/src/typeScriptSemanticLowering.d.ts +6 -0
- package/dist/packages/compiler-semantic/src/typeScriptSemanticLowering.d.ts.map +1 -0
- package/dist/packages/compiler-semantic/src/typeScriptSemanticLowering.js +8158 -0
- package/dist/packages/compiler-semantic/src/typeScriptSemanticLowering.js.map +1 -0
- package/dist/packages/compiler-structural/src/compilerStructuralObjectCompatibility.d.ts +5 -0
- package/dist/packages/compiler-structural/src/compilerStructuralObjectCompatibility.d.ts.map +1 -0
- package/dist/packages/compiler-structural/src/compilerStructuralObjectCompatibility.js +500 -0
- package/dist/packages/compiler-structural/src/compilerStructuralObjectCompatibility.js.map +1 -0
- package/dist/packages/compiler-structural/src/compilerStructuralObjectCopySemantics.d.ts +3 -0
- package/dist/packages/compiler-structural/src/compilerStructuralObjectCopySemantics.d.ts.map +1 -0
- package/dist/packages/compiler-structural/src/compilerStructuralObjectCopySemantics.js +11 -0
- package/dist/packages/compiler-structural/src/compilerStructuralObjectCopySemantics.js.map +1 -0
- package/dist/packages/compiler-structural/src/compilerStructuralTypeAssignability.d.ts +4 -0
- package/dist/packages/compiler-structural/src/compilerStructuralTypeAssignability.d.ts.map +1 -0
- package/dist/packages/compiler-structural/src/compilerStructuralTypeAssignability.js +261 -0
- package/dist/packages/compiler-structural/src/compilerStructuralTypeAssignability.js.map +1 -0
- package/dist/packages/compiler-structural/src/compilerStructuralTypeShapeIdentity.d.ts +4 -0
- package/dist/packages/compiler-structural/src/compilerStructuralTypeShapeIdentity.d.ts.map +1 -0
- package/dist/packages/compiler-structural/src/compilerStructuralTypeShapeIdentity.js +168 -0
- package/dist/packages/compiler-structural/src/compilerStructuralTypeShapeIdentity.js.map +1 -0
- package/dist/packages/compiler-structural/src/compilerStructuralTypeShapeInventory.d.ts +3 -0
- package/dist/packages/compiler-structural/src/compilerStructuralTypeShapeInventory.d.ts.map +1 -0
- package/dist/packages/compiler-structural/src/compilerStructuralTypeShapeInventory.js +50 -0
- package/dist/packages/compiler-structural/src/compilerStructuralTypeShapeInventory.js.map +1 -0
- package/dist/packages/compiler-structural/src/compilerStructuralTypeSubstitution.d.ts +5 -0
- package/dist/packages/compiler-structural/src/compilerStructuralTypeSubstitution.d.ts.map +1 -0
- package/dist/packages/compiler-structural/src/compilerStructuralTypeSubstitution.js +224 -0
- package/dist/packages/compiler-structural/src/compilerStructuralTypeSubstitution.js.map +1 -0
- package/dist/packages/compiler-structural/src/compilerTypeValueIdentityAnalysis.d.ts +4 -0
- package/dist/packages/compiler-structural/src/compilerTypeValueIdentityAnalysis.d.ts.map +1 -0
- package/dist/packages/compiler-structural/src/compilerTypeValueIdentityAnalysis.js +592 -0
- package/dist/packages/compiler-structural/src/compilerTypeValueIdentityAnalysis.js.map +1 -0
- package/dist/packages/compiler-structural/src/index.d.ts +8 -0
- package/dist/packages/compiler-structural/src/index.d.ts.map +1 -0
- package/dist/packages/compiler-structural/src/index.js +8 -0
- package/dist/packages/compiler-structural/src/index.js.map +1 -0
- package/dist/packages/compiler-task/src/compilerAsyncStateMachine.d.ts +3 -0
- package/dist/packages/compiler-task/src/compilerAsyncStateMachine.d.ts.map +1 -0
- package/dist/packages/compiler-task/src/compilerAsyncStateMachine.js +785 -0
- package/dist/packages/compiler-task/src/compilerAsyncStateMachine.js.map +1 -0
- package/dist/packages/compiler-task/src/compilerAsyncTaskInventory.d.ts +3 -0
- package/dist/packages/compiler-task/src/compilerAsyncTaskInventory.d.ts.map +1 -0
- package/dist/packages/compiler-task/src/compilerAsyncTaskInventory.js +182 -0
- package/dist/packages/compiler-task/src/compilerAsyncTaskInventory.js.map +1 -0
- package/dist/packages/compiler-task/src/compilerTaskOperationSemantics.d.ts +4 -0
- package/dist/packages/compiler-task/src/compilerTaskOperationSemantics.d.ts.map +1 -0
- package/dist/packages/compiler-task/src/compilerTaskOperationSemantics.js +101 -0
- package/dist/packages/compiler-task/src/compilerTaskOperationSemantics.js.map +1 -0
- package/dist/packages/compiler-task/src/index.d.ts +4 -0
- package/dist/packages/compiler-task/src/index.d.ts.map +1 -0
- package/dist/packages/compiler-task/src/index.js +4 -0
- package/dist/packages/compiler-task/src/index.js.map +1 -0
- package/dist/packages/compiler-types/src/compilerAccessSemanticIntermediateRepresentation.d.ts +79 -0
- package/dist/packages/compiler-types/src/compilerAccessSemanticIntermediateRepresentation.d.ts.map +1 -0
- package/dist/packages/compiler-types/src/compilerAccessSemanticIntermediateRepresentation.js +2 -0
- package/dist/packages/compiler-types/src/compilerAccessSemanticIntermediateRepresentation.js.map +1 -0
- package/dist/packages/compiler-types/src/compilerAmbientMemberBindingContract.d.ts +87 -0
- package/dist/packages/compiler-types/src/compilerAmbientMemberBindingContract.d.ts.map +1 -0
- package/dist/packages/compiler-types/src/compilerAmbientMemberBindingContract.js +2 -0
- package/dist/packages/compiler-types/src/compilerAmbientMemberBindingContract.js.map +1 -0
- package/dist/packages/compiler-types/src/compilerAsyncStateMachineContract.d.ts +126 -0
- package/dist/packages/compiler-types/src/compilerAsyncStateMachineContract.d.ts.map +1 -0
- package/dist/packages/compiler-types/src/compilerAsyncStateMachineContract.js +2 -0
- package/dist/packages/compiler-types/src/compilerAsyncStateMachineContract.js.map +1 -0
- package/dist/packages/compiler-types/src/compilerAsyncTaskCompletionContract.d.ts +32 -0
- package/dist/packages/compiler-types/src/compilerAsyncTaskCompletionContract.d.ts.map +1 -0
- package/dist/packages/compiler-types/src/compilerAsyncTaskCompletionContract.js +2 -0
- package/dist/packages/compiler-types/src/compilerAsyncTaskCompletionContract.js.map +1 -0
- package/dist/packages/compiler-types/src/compilerAsyncTaskInventoryContract.d.ts +63 -0
- package/dist/packages/compiler-types/src/compilerAsyncTaskInventoryContract.d.ts.map +1 -0
- package/dist/packages/compiler-types/src/compilerAsyncTaskInventoryContract.js +2 -0
- package/dist/packages/compiler-types/src/compilerAsyncTaskInventoryContract.js.map +1 -0
- package/dist/packages/compiler-types/src/compilerBackendContract.d.ts +183 -0
- package/dist/packages/compiler-types/src/compilerBackendContract.d.ts.map +1 -0
- package/dist/packages/compiler-types/src/compilerBackendContract.js +2 -0
- package/dist/packages/compiler-types/src/compilerBackendContract.js.map +1 -0
- package/dist/packages/compiler-types/src/compilerBindingIntermediateRepresentation.d.ts +46 -0
- package/dist/packages/compiler-types/src/compilerBindingIntermediateRepresentation.d.ts.map +1 -0
- package/dist/packages/compiler-types/src/compilerBindingIntermediateRepresentation.js +2 -0
- package/dist/packages/compiler-types/src/compilerBindingIntermediateRepresentation.js.map +1 -0
- package/dist/packages/compiler-types/src/compilerBindingPatternIntermediateRepresentation.d.ts +43 -0
- package/dist/packages/compiler-types/src/compilerBindingPatternIntermediateRepresentation.d.ts.map +1 -0
- package/dist/packages/compiler-types/src/compilerBindingPatternIntermediateRepresentation.js +2 -0
- package/dist/packages/compiler-types/src/compilerBindingPatternIntermediateRepresentation.js.map +1 -0
- package/dist/packages/compiler-types/src/compilerCatchCompletionContract.d.ts +23 -0
- package/dist/packages/compiler-types/src/compilerCatchCompletionContract.d.ts.map +1 -0
- package/dist/packages/compiler-types/src/compilerCatchCompletionContract.js +2 -0
- package/dist/packages/compiler-types/src/compilerCatchCompletionContract.js.map +1 -0
- package/dist/packages/compiler-types/src/compilerClassInitializationContract.d.ts +30 -0
- package/dist/packages/compiler-types/src/compilerClassInitializationContract.d.ts.map +1 -0
- package/dist/packages/compiler-types/src/compilerClassInitializationContract.js +2 -0
- package/dist/packages/compiler-types/src/compilerClassInitializationContract.js.map +1 -0
- package/dist/packages/compiler-types/src/compilerClosureEvidenceContract.d.ts +60 -0
- package/dist/packages/compiler-types/src/compilerClosureEvidenceContract.d.ts.map +1 -0
- package/dist/packages/compiler-types/src/compilerClosureEvidenceContract.js +2 -0
- package/dist/packages/compiler-types/src/compilerClosureEvidenceContract.js.map +1 -0
- package/dist/packages/compiler-types/src/compilerCommandLineContract.d.ts +79 -0
- package/dist/packages/compiler-types/src/compilerCommandLineContract.d.ts.map +1 -0
- package/dist/packages/compiler-types/src/compilerCommandLineContract.js +2 -0
- package/dist/packages/compiler-types/src/compilerCommandLineContract.js.map +1 -0
- package/dist/packages/compiler-types/src/compilerCompletionContract.d.ts +25 -0
- package/dist/packages/compiler-types/src/compilerCompletionContract.d.ts.map +1 -0
- package/dist/packages/compiler-types/src/compilerCompletionContract.js +2 -0
- package/dist/packages/compiler-types/src/compilerCompletionContract.js.map +1 -0
- package/dist/packages/compiler-types/src/compilerCppClosureCaptureContract.d.ts +21 -0
- package/dist/packages/compiler-types/src/compilerCppClosureCaptureContract.d.ts.map +1 -0
- package/dist/packages/compiler-types/src/compilerCppClosureCaptureContract.js +2 -0
- package/dist/packages/compiler-types/src/compilerCppClosureCaptureContract.js.map +1 -0
- package/dist/packages/compiler-types/src/compilerCppReferenceRepresentationContract.d.ts +74 -0
- package/dist/packages/compiler-types/src/compilerCppReferenceRepresentationContract.d.ts.map +1 -0
- package/dist/packages/compiler-types/src/compilerCppReferenceRepresentationContract.js +2 -0
- package/dist/packages/compiler-types/src/compilerCppReferenceRepresentationContract.js.map +1 -0
- package/dist/packages/compiler-types/src/compilerDeclarationIntermediateRepresentation.d.ts +113 -0
- package/dist/packages/compiler-types/src/compilerDeclarationIntermediateRepresentation.d.ts.map +1 -0
- package/dist/packages/compiler-types/src/compilerDeclarationIntermediateRepresentation.js +2 -0
- package/dist/packages/compiler-types/src/compilerDeclarationIntermediateRepresentation.js.map +1 -0
- package/dist/packages/compiler-types/src/compilerDependentCallablePackContract.d.ts +11 -0
- package/dist/packages/compiler-types/src/compilerDependentCallablePackContract.d.ts.map +1 -0
- package/dist/packages/compiler-types/src/compilerDependentCallablePackContract.js +2 -0
- package/dist/packages/compiler-types/src/compilerDependentCallablePackContract.js.map +1 -0
- package/dist/packages/compiler-types/src/compilerDiagnosticContract.d.ts +11 -0
- package/dist/packages/compiler-types/src/compilerDiagnosticContract.d.ts.map +1 -0
- package/dist/packages/compiler-types/src/compilerDiagnosticContract.js +2 -0
- package/dist/packages/compiler-types/src/compilerDiagnosticContract.js.map +1 -0
- package/dist/packages/compiler-types/src/compilerEmittedSourceSyntaxContract.d.ts +28 -0
- package/dist/packages/compiler-types/src/compilerEmittedSourceSyntaxContract.d.ts.map +1 -0
- package/dist/packages/compiler-types/src/compilerEmittedSourceSyntaxContract.js +2 -0
- package/dist/packages/compiler-types/src/compilerEmittedSourceSyntaxContract.js.map +1 -0
- package/dist/packages/compiler-types/src/compilerExecutableIntermediateRepresentation.d.ts +343 -0
- package/dist/packages/compiler-types/src/compilerExecutableIntermediateRepresentation.d.ts.map +1 -0
- package/dist/packages/compiler-types/src/compilerExecutableIntermediateRepresentation.js +2 -0
- package/dist/packages/compiler-types/src/compilerExecutableIntermediateRepresentation.js.map +1 -0
- package/dist/packages/compiler-types/src/compilerFlightWorkspaceContract.d.ts +26 -0
- package/dist/packages/compiler-types/src/compilerFlightWorkspaceContract.d.ts.map +1 -0
- package/dist/packages/compiler-types/src/compilerFlightWorkspaceContract.js +2 -0
- package/dist/packages/compiler-types/src/compilerFlightWorkspaceContract.js.map +1 -0
- package/dist/packages/compiler-types/src/compilerHaxeTaskEmissionContract.d.ts +12 -0
- package/dist/packages/compiler-types/src/compilerHaxeTaskEmissionContract.d.ts.map +1 -0
- package/dist/packages/compiler-types/src/compilerHaxeTaskEmissionContract.js +2 -0
- package/dist/packages/compiler-types/src/compilerHaxeTaskEmissionContract.js.map +1 -0
- package/dist/packages/compiler-types/src/compilerHaxeTaskLoweringContract.d.ts +119 -0
- package/dist/packages/compiler-types/src/compilerHaxeTaskLoweringContract.d.ts.map +1 -0
- package/dist/packages/compiler-types/src/compilerHaxeTaskLoweringContract.js +2 -0
- package/dist/packages/compiler-types/src/compilerHaxeTaskLoweringContract.js.map +1 -0
- package/dist/packages/compiler-types/src/compilerHostEndpointContract.d.ts +27 -0
- package/dist/packages/compiler-types/src/compilerHostEndpointContract.d.ts.map +1 -0
- package/dist/packages/compiler-types/src/compilerHostEndpointContract.js +2 -0
- package/dist/packages/compiler-types/src/compilerHostEndpointContract.js.map +1 -0
- package/dist/packages/compiler-types/src/compilerInvariantContract.d.ts +7 -0
- package/dist/packages/compiler-types/src/compilerInvariantContract.d.ts.map +1 -0
- package/dist/packages/compiler-types/src/compilerInvariantContract.js +2 -0
- package/dist/packages/compiler-types/src/compilerInvariantContract.js.map +1 -0
- package/dist/packages/compiler-types/src/compilerInventoryContract.d.ts +186 -0
- package/dist/packages/compiler-types/src/compilerInventoryContract.d.ts.map +1 -0
- package/dist/packages/compiler-types/src/compilerInventoryContract.js +2 -0
- package/dist/packages/compiler-types/src/compilerInventoryContract.js.map +1 -0
- package/dist/packages/compiler-types/src/compilerIrValidationContract.d.ts +13 -0
- package/dist/packages/compiler-types/src/compilerIrValidationContract.d.ts.map +1 -0
- package/dist/packages/compiler-types/src/compilerIrValidationContract.js +2 -0
- package/dist/packages/compiler-types/src/compilerIrValidationContract.js.map +1 -0
- package/dist/packages/compiler-types/src/compilerLoweringContract.d.ts +32 -0
- package/dist/packages/compiler-types/src/compilerLoweringContract.d.ts.map +1 -0
- package/dist/packages/compiler-types/src/compilerLoweringContract.js +2 -0
- package/dist/packages/compiler-types/src/compilerLoweringContract.js.map +1 -0
- package/dist/packages/compiler-types/src/compilerModuleEvaluationContract.d.ts +84 -0
- package/dist/packages/compiler-types/src/compilerModuleEvaluationContract.d.ts.map +1 -0
- package/dist/packages/compiler-types/src/compilerModuleEvaluationContract.js +2 -0
- package/dist/packages/compiler-types/src/compilerModuleEvaluationContract.js.map +1 -0
- package/dist/packages/compiler-types/src/compilerModuleFacadeContract.d.ts +78 -0
- package/dist/packages/compiler-types/src/compilerModuleFacadeContract.d.ts.map +1 -0
- package/dist/packages/compiler-types/src/compilerModuleFacadeContract.js +2 -0
- package/dist/packages/compiler-types/src/compilerModuleFacadeContract.js.map +1 -0
- package/dist/packages/compiler-types/src/compilerModuleIntermediateRepresentation.d.ts +53 -0
- package/dist/packages/compiler-types/src/compilerModuleIntermediateRepresentation.d.ts.map +1 -0
- package/dist/packages/compiler-types/src/compilerModuleIntermediateRepresentation.js +2 -0
- package/dist/packages/compiler-types/src/compilerModuleIntermediateRepresentation.js.map +1 -0
- package/dist/packages/compiler-types/src/compilerModuleResolutionContract.d.ts +20 -0
- package/dist/packages/compiler-types/src/compilerModuleResolutionContract.d.ts.map +1 -0
- package/dist/packages/compiler-types/src/compilerModuleResolutionContract.js +2 -0
- package/dist/packages/compiler-types/src/compilerModuleResolutionContract.js.map +1 -0
- package/dist/packages/compiler-types/src/compilerOperatorIntermediateRepresentation.d.ts +5 -0
- package/dist/packages/compiler-types/src/compilerOperatorIntermediateRepresentation.d.ts.map +1 -0
- package/dist/packages/compiler-types/src/compilerOperatorIntermediateRepresentation.js +2 -0
- package/dist/packages/compiler-types/src/compilerOperatorIntermediateRepresentation.js.map +1 -0
- package/dist/packages/compiler-types/src/compilerOperatorSemanticIntermediateRepresentation.d.ts +34 -0
- package/dist/packages/compiler-types/src/compilerOperatorSemanticIntermediateRepresentation.d.ts.map +1 -0
- package/dist/packages/compiler-types/src/compilerOperatorSemanticIntermediateRepresentation.js +2 -0
- package/dist/packages/compiler-types/src/compilerOperatorSemanticIntermediateRepresentation.js.map +1 -0
- package/dist/packages/compiler-types/src/compilerOrchestrationContract.d.ts +43 -0
- package/dist/packages/compiler-types/src/compilerOrchestrationContract.d.ts.map +1 -0
- package/dist/packages/compiler-types/src/compilerOrchestrationContract.js +2 -0
- package/dist/packages/compiler-types/src/compilerOrchestrationContract.js.map +1 -0
- package/dist/packages/compiler-types/src/compilerPackageCheckContract.d.ts +96 -0
- package/dist/packages/compiler-types/src/compilerPackageCheckContract.d.ts.map +1 -0
- package/dist/packages/compiler-types/src/compilerPackageCheckContract.js +2 -0
- package/dist/packages/compiler-types/src/compilerPackageCheckContract.js.map +1 -0
- package/dist/packages/compiler-types/src/compilerPackageCompilationContract.d.ts +108 -0
- package/dist/packages/compiler-types/src/compilerPackageCompilationContract.d.ts.map +1 -0
- package/dist/packages/compiler-types/src/compilerPackageCompilationContract.js +2 -0
- package/dist/packages/compiler-types/src/compilerPackageCompilationContract.js.map +1 -0
- package/dist/packages/compiler-types/src/compilerRefusalClassificationContract.d.ts +3 -0
- package/dist/packages/compiler-types/src/compilerRefusalClassificationContract.d.ts.map +1 -0
- package/dist/packages/compiler-types/src/compilerRefusalClassificationContract.js +2 -0
- package/dist/packages/compiler-types/src/compilerRefusalClassificationContract.js.map +1 -0
- package/dist/packages/compiler-types/src/compilerRuntimeContract.d.ts +122 -0
- package/dist/packages/compiler-types/src/compilerRuntimeContract.d.ts.map +1 -0
- package/dist/packages/compiler-types/src/compilerRuntimeContract.js +2 -0
- package/dist/packages/compiler-types/src/compilerRuntimeContract.js.map +1 -0
- package/dist/packages/compiler-types/src/compilerRuntimeTaskCapabilityContract.d.ts +96 -0
- package/dist/packages/compiler-types/src/compilerRuntimeTaskCapabilityContract.d.ts.map +1 -0
- package/dist/packages/compiler-types/src/compilerRuntimeTaskCapabilityContract.js +2 -0
- package/dist/packages/compiler-types/src/compilerRuntimeTaskCapabilityContract.js.map +1 -0
- package/dist/packages/compiler-types/src/compilerRustOwnershipContract.d.ts +25 -0
- package/dist/packages/compiler-types/src/compilerRustOwnershipContract.d.ts.map +1 -0
- package/dist/packages/compiler-types/src/compilerRustOwnershipContract.js +2 -0
- package/dist/packages/compiler-types/src/compilerRustOwnershipContract.js.map +1 -0
- package/dist/packages/compiler-types/src/compilerSemanticPatchContract.d.ts +80 -0
- package/dist/packages/compiler-types/src/compilerSemanticPatchContract.d.ts.map +1 -0
- package/dist/packages/compiler-types/src/compilerSemanticPatchContract.js +2 -0
- package/dist/packages/compiler-types/src/compilerSemanticPatchContract.js.map +1 -0
- package/dist/packages/compiler-types/src/compilerSourceFingerprint.d.ts +2 -0
- package/dist/packages/compiler-types/src/compilerSourceFingerprint.d.ts.map +1 -0
- package/dist/packages/compiler-types/src/compilerSourceFingerprint.js +2 -0
- package/dist/packages/compiler-types/src/compilerSourceFingerprint.js.map +1 -0
- package/dist/packages/compiler-types/src/compilerSourceIdentity.d.ts +21 -0
- package/dist/packages/compiler-types/src/compilerSourceIdentity.d.ts.map +1 -0
- package/dist/packages/compiler-types/src/compilerSourceIdentity.js +2 -0
- package/dist/packages/compiler-types/src/compilerSourceIdentity.js.map +1 -0
- package/dist/packages/compiler-types/src/compilerStatementCompletionContract.d.ts +7 -0
- package/dist/packages/compiler-types/src/compilerStatementCompletionContract.d.ts.map +1 -0
- package/dist/packages/compiler-types/src/compilerStatementCompletionContract.js +2 -0
- package/dist/packages/compiler-types/src/compilerStatementCompletionContract.js.map +1 -0
- package/dist/packages/compiler-types/src/compilerStaticFactContract.d.ts +71 -0
- package/dist/packages/compiler-types/src/compilerStaticFactContract.d.ts.map +1 -0
- package/dist/packages/compiler-types/src/compilerStaticFactContract.js +2 -0
- package/dist/packages/compiler-types/src/compilerStaticFactContract.js.map +1 -0
- package/dist/packages/compiler-types/src/compilerStructuralObjectCompatibilityContract.d.ts +18 -0
- package/dist/packages/compiler-types/src/compilerStructuralObjectCompatibilityContract.d.ts.map +1 -0
- package/dist/packages/compiler-types/src/compilerStructuralObjectCompatibilityContract.js +2 -0
- package/dist/packages/compiler-types/src/compilerStructuralObjectCompatibilityContract.js.map +1 -0
- package/dist/packages/compiler-types/src/compilerStructuralTypeAssignabilityContract.d.ts +20 -0
- package/dist/packages/compiler-types/src/compilerStructuralTypeAssignabilityContract.d.ts.map +1 -0
- package/dist/packages/compiler-types/src/compilerStructuralTypeAssignabilityContract.js +2 -0
- package/dist/packages/compiler-types/src/compilerStructuralTypeAssignabilityContract.js.map +1 -0
- package/dist/packages/compiler-types/src/compilerStructuralTypeShapeContract.d.ts +22 -0
- package/dist/packages/compiler-types/src/compilerStructuralTypeShapeContract.d.ts.map +1 -0
- package/dist/packages/compiler-types/src/compilerStructuralTypeShapeContract.js +2 -0
- package/dist/packages/compiler-types/src/compilerStructuralTypeShapeContract.js.map +1 -0
- package/dist/packages/compiler-types/src/compilerStructuralTypeSubstitutionContract.d.ts +17 -0
- package/dist/packages/compiler-types/src/compilerStructuralTypeSubstitutionContract.d.ts.map +1 -0
- package/dist/packages/compiler-types/src/compilerStructuralTypeSubstitutionContract.js +2 -0
- package/dist/packages/compiler-types/src/compilerStructuralTypeSubstitutionContract.js.map +1 -0
- package/dist/packages/compiler-types/src/compilerTargetCompilationSmokeContract.d.ts +26 -0
- package/dist/packages/compiler-types/src/compilerTargetCompilationSmokeContract.d.ts.map +1 -0
- package/dist/packages/compiler-types/src/compilerTargetCompilationSmokeContract.js +2 -0
- package/dist/packages/compiler-types/src/compilerTargetCompilationSmokeContract.js.map +1 -0
- package/dist/packages/compiler-types/src/compilerTargetNamingContract.d.ts +27 -0
- package/dist/packages/compiler-types/src/compilerTargetNamingContract.d.ts.map +1 -0
- package/dist/packages/compiler-types/src/compilerTargetNamingContract.js +2 -0
- package/dist/packages/compiler-types/src/compilerTargetNamingContract.js.map +1 -0
- package/dist/packages/compiler-types/src/compilerTaskOperationSemanticsContract.d.ts +65 -0
- package/dist/packages/compiler-types/src/compilerTaskOperationSemanticsContract.d.ts.map +1 -0
- package/dist/packages/compiler-types/src/compilerTaskOperationSemanticsContract.js +2 -0
- package/dist/packages/compiler-types/src/compilerTaskOperationSemanticsContract.js.map +1 -0
- package/dist/packages/compiler-types/src/compilerTraversalObserverContract.d.ts +29 -0
- package/dist/packages/compiler-types/src/compilerTraversalObserverContract.d.ts.map +1 -0
- package/dist/packages/compiler-types/src/compilerTraversalObserverContract.js +2 -0
- package/dist/packages/compiler-types/src/compilerTraversalObserverContract.js.map +1 -0
- package/dist/packages/compiler-types/src/compilerTypeIntermediateRepresentation.d.ts +99 -0
- package/dist/packages/compiler-types/src/compilerTypeIntermediateRepresentation.d.ts.map +1 -0
- package/dist/packages/compiler-types/src/compilerTypeIntermediateRepresentation.js +2 -0
- package/dist/packages/compiler-types/src/compilerTypeIntermediateRepresentation.js.map +1 -0
- package/dist/packages/compiler-types/src/compilerTypeScriptContract.d.ts +39 -0
- package/dist/packages/compiler-types/src/compilerTypeScriptContract.d.ts.map +1 -0
- package/dist/packages/compiler-types/src/compilerTypeScriptContract.js +2 -0
- package/dist/packages/compiler-types/src/compilerTypeScriptContract.js.map +1 -0
- package/dist/packages/compiler-types/src/compilerTypeValueIdentityContract.d.ts +14 -0
- package/dist/packages/compiler-types/src/compilerTypeValueIdentityContract.d.ts.map +1 -0
- package/dist/packages/compiler-types/src/compilerTypeValueIdentityContract.js +2 -0
- package/dist/packages/compiler-types/src/compilerTypeValueIdentityContract.js.map +1 -0
- package/dist/packages/compiler-types/src/compilerValueCompletionContract.d.ts +46 -0
- package/dist/packages/compiler-types/src/compilerValueCompletionContract.d.ts.map +1 -0
- package/dist/packages/compiler-types/src/compilerValueCompletionContract.js +2 -0
- package/dist/packages/compiler-types/src/compilerValueCompletionContract.js.map +1 -0
- package/dist/packages/compiler-types/src/compilerWorkspaceSourceContract.d.ts +11 -0
- package/dist/packages/compiler-types/src/compilerWorkspaceSourceContract.d.ts.map +1 -0
- package/dist/packages/compiler-types/src/compilerWorkspaceSourceContract.js +12 -0
- package/dist/packages/compiler-types/src/compilerWorkspaceSourceContract.js.map +1 -0
- package/dist/packages/compiler-types/src/index.d.ts +60 -0
- package/dist/packages/compiler-types/src/index.d.ts.map +1 -0
- package/dist/packages/compiler-types/src/index.js +2 -0
- package/dist/packages/compiler-types/src/index.js.map +1 -0
- package/dist/packages/tool-compiler/src/index.d.ts +24 -0
- package/dist/packages/tool-compiler/src/index.d.ts.map +1 -0
- package/dist/packages/tool-compiler/src/index.js +23 -0
- package/dist/packages/tool-compiler/src/index.js.map +1 -0
- package/package.json +45 -0
|
@@ -0,0 +1,1258 @@
|
|
|
1
|
+
import { isIrAwaitSemantics, isIrCallExpressionStatementValueCarrier, isIrCatchSemantics, } from '../../compiler-completion/src/index.js';
|
|
2
|
+
import { isCompilerSourceFingerprint } from '../../compiler-provenance/src/index.js';
|
|
3
|
+
function validateIrOptionalChainEvidence(optional, evidence, path, state) {
|
|
4
|
+
const receiverType = evidence?.receiverType;
|
|
5
|
+
const valueType = evidence?.valueType;
|
|
6
|
+
const receiverNullish = evidence?.receiverNullish;
|
|
7
|
+
const valid = evidence?.receiverEvaluation === 'once' &&
|
|
8
|
+
(receiverNullish === 'excluded' || receiverNullish === 'possible') &&
|
|
9
|
+
evidence.result === 'undefined' &&
|
|
10
|
+
evidence.shortCircuit === 'nullish' &&
|
|
11
|
+
isIrTypeEvidence(receiverType) &&
|
|
12
|
+
isIrTypeEvidence(valueType) &&
|
|
13
|
+
isIrOptionalChainReceiverNullishCoherent(receiverType, receiverNullish);
|
|
14
|
+
if ((optional && !valid) || (!optional && evidence !== undefined)) {
|
|
15
|
+
addFailure('invalid-node-shape', `${path}.optionalChain`, 'optional-chain evidence must exactly match an optional access target', state);
|
|
16
|
+
}
|
|
17
|
+
if (valid) {
|
|
18
|
+
visitType(receiverType, `${path}.optionalChain.receiverType`, state);
|
|
19
|
+
visitType(valueType, `${path}.optionalChain.valueType`, state);
|
|
20
|
+
}
|
|
21
|
+
}
|
|
22
|
+
function isIrOptionalChainReceiverNullishCoherent(type, receiverNullish) {
|
|
23
|
+
if (type.kind === 'null' || type.kind === 'undefined')
|
|
24
|
+
return receiverNullish === 'possible';
|
|
25
|
+
if (type.kind === 'union' && type.types.some((member) => member.kind === 'null' || member.kind === 'undefined')) {
|
|
26
|
+
return receiverNullish === 'possible';
|
|
27
|
+
}
|
|
28
|
+
if (type.kind === 'array' ||
|
|
29
|
+
type.kind === 'function' ||
|
|
30
|
+
type.kind === 'literal' ||
|
|
31
|
+
type.kind === 'never' ||
|
|
32
|
+
type.kind === 'object' ||
|
|
33
|
+
type.kind === 'primitive' ||
|
|
34
|
+
type.kind === 'tuple') {
|
|
35
|
+
return receiverNullish === 'excluded';
|
|
36
|
+
}
|
|
37
|
+
return true;
|
|
38
|
+
}
|
|
39
|
+
function isIrTypeEvidence(value) {
|
|
40
|
+
return typeof value === 'object' && value !== null && 'kind' in value && typeof value.kind === 'string';
|
|
41
|
+
}
|
|
42
|
+
export function validateIrModuleStructure(module) {
|
|
43
|
+
const moduleScope = { id: '$#module', kind: 'module' };
|
|
44
|
+
const state = {
|
|
45
|
+
bindings: new Map(),
|
|
46
|
+
controlFlowLabels: [],
|
|
47
|
+
failures: [],
|
|
48
|
+
module,
|
|
49
|
+
references: [],
|
|
50
|
+
scopeParents: new Map([[moduleScope.id, undefined]]),
|
|
51
|
+
scopes: [moduleScope],
|
|
52
|
+
};
|
|
53
|
+
try {
|
|
54
|
+
validateModuleIdentity(module, state);
|
|
55
|
+
module.imports.forEach((imported, importIndex) => {
|
|
56
|
+
if (typeof imported.typeOnly !== 'boolean' ||
|
|
57
|
+
(imported.typeOnly && imported.bindings.some((binding) => !binding.typeOnly))) {
|
|
58
|
+
addFailure('invalid-node-shape', `$.imports[${String(importIndex)}].typeOnly`, 'module import type-only identity must be boolean and cannot contain value bindings', state);
|
|
59
|
+
}
|
|
60
|
+
imported.bindings.forEach(({ binding, typeOnly }, bindingIndex) => addBindingDefinition(binding, `$.imports[${String(importIndex)}].bindings[${String(bindingIndex)}]`, { kind: 'import', scope: 'module', space: typeOnly ? 'type' : 'value' }, state));
|
|
61
|
+
});
|
|
62
|
+
module.declarations.forEach((declaration, index) => visitDeclaration(declaration, `$.declarations[${String(index)}]`, state));
|
|
63
|
+
module.exports.forEach((exported, index) => {
|
|
64
|
+
const path = `$.exports[${String(index)}]`;
|
|
65
|
+
switch (exported.kind) {
|
|
66
|
+
case 'all':
|
|
67
|
+
case 'namespace':
|
|
68
|
+
case 'reexport':
|
|
69
|
+
break;
|
|
70
|
+
case 'default':
|
|
71
|
+
visitExpression(exported.expression, `${path}.expression`, state);
|
|
72
|
+
break;
|
|
73
|
+
case 'local':
|
|
74
|
+
addBindingReference(exported.binding, `${path}.binding`, state);
|
|
75
|
+
break;
|
|
76
|
+
default:
|
|
77
|
+
addUnknownKind(exported, path, state);
|
|
78
|
+
}
|
|
79
|
+
});
|
|
80
|
+
validateBindingReferences(state);
|
|
81
|
+
}
|
|
82
|
+
catch (error) {
|
|
83
|
+
addFailure('invalid-node-shape', '$', error instanceof Error ? error.message : String(error), state);
|
|
84
|
+
}
|
|
85
|
+
return state.failures.length === 0 ? { kind: 'valid' } : { failures: state.failures, kind: 'invalid' };
|
|
86
|
+
}
|
|
87
|
+
function addBindingDefinition(binding, path, expectation, state) {
|
|
88
|
+
if (!isNonEmptyString(binding.id) || !isNonEmptyString(binding.name)) {
|
|
89
|
+
addFailure('invalid-binding-identity', path, 'binding id and name must be nonempty strings', state);
|
|
90
|
+
return;
|
|
91
|
+
}
|
|
92
|
+
validateBindingOrigin(binding, path, state);
|
|
93
|
+
validateBindingIntroduction(binding, path, expectation, state);
|
|
94
|
+
const scope = getBindingIntroductionScope(binding.scope, expectation.scope, state);
|
|
95
|
+
const existing = state.bindings.get(binding.id) ?? [];
|
|
96
|
+
const sameScope = existing.find((definition) => definition.scope === scope);
|
|
97
|
+
if (sameScope) {
|
|
98
|
+
if (isRepeatedFunctionVariableBinding(sameScope, binding, scope, expectation))
|
|
99
|
+
return;
|
|
100
|
+
addFailure('duplicate-binding-identity', path, `binding ${binding.id} was already introduced at ${sameScope.path}`, state);
|
|
101
|
+
return;
|
|
102
|
+
}
|
|
103
|
+
if (existing.length > 0 && !isRepeatedScopedTypeParameterBinding(existing, binding, expectation)) {
|
|
104
|
+
addFailure('duplicate-binding-identity', path, `binding ${binding.id} was already introduced at ${existing[0].path}`, state);
|
|
105
|
+
return;
|
|
106
|
+
}
|
|
107
|
+
existing.push({ binding, path, scope });
|
|
108
|
+
state.bindings.set(binding.id, existing);
|
|
109
|
+
}
|
|
110
|
+
function isRepeatedScopedTypeParameterBinding(existing, binding, expectation) {
|
|
111
|
+
// Resolved type evidence may embed the same source-declared generic signature more than once.
|
|
112
|
+
// Its stable source binding identity repeats, while each embedded function type establishes an
|
|
113
|
+
// independent lexical scope. Only that exact type-parameter identity may repeat across scopes;
|
|
114
|
+
// two introductions in one scope remain a malformed duplicate.
|
|
115
|
+
return (expectation.kind === 'typeParameter' &&
|
|
116
|
+
expectation.space === 'type' &&
|
|
117
|
+
binding.kind === 'typeParameter' &&
|
|
118
|
+
existing.every((definition) => hasSameBindingIdentityMetadata(definition.binding, binding)));
|
|
119
|
+
}
|
|
120
|
+
function hasSameBindingIdentityMetadata(left, right) {
|
|
121
|
+
return (left.id === right.id &&
|
|
122
|
+
left.name === right.name &&
|
|
123
|
+
left.kind === right.kind &&
|
|
124
|
+
left.scope === right.scope &&
|
|
125
|
+
left.space === right.space &&
|
|
126
|
+
left.packageName === right.packageName &&
|
|
127
|
+
left.source === right.source &&
|
|
128
|
+
left.line === right.line &&
|
|
129
|
+
left.column === right.column &&
|
|
130
|
+
left.fingerprint === right.fingerprint);
|
|
131
|
+
}
|
|
132
|
+
function isRepeatedFunctionVariableBinding(existing, binding, scope, expectation) {
|
|
133
|
+
const previous = existing.binding;
|
|
134
|
+
return (expectation.kind === 'variable' &&
|
|
135
|
+
expectation.space === 'value' &&
|
|
136
|
+
binding.kind === 'variable' &&
|
|
137
|
+
binding.scope === 'function' &&
|
|
138
|
+
existing.scope === scope &&
|
|
139
|
+
previous.id === binding.id &&
|
|
140
|
+
previous.name === binding.name &&
|
|
141
|
+
previous.kind === binding.kind &&
|
|
142
|
+
previous.scope === binding.scope &&
|
|
143
|
+
previous.space === binding.space &&
|
|
144
|
+
previous.packageName === binding.packageName &&
|
|
145
|
+
previous.source === binding.source &&
|
|
146
|
+
previous.line === binding.line &&
|
|
147
|
+
previous.column === binding.column &&
|
|
148
|
+
previous.fingerprint === binding.fingerprint);
|
|
149
|
+
}
|
|
150
|
+
function addBindingReference(binding, path, state) {
|
|
151
|
+
state.references.push({ binding, path, scope: getCurrentLexicalScope(state).id });
|
|
152
|
+
}
|
|
153
|
+
function addFailure(code, path, reason, state) {
|
|
154
|
+
state.failures.push({ code, path, reason });
|
|
155
|
+
}
|
|
156
|
+
function addUnknownKind(value, path, state) {
|
|
157
|
+
const kind = value.kind;
|
|
158
|
+
addFailure('unknown-ir-kind', path, `unknown neutral IR kind ${String(kind)}`, state);
|
|
159
|
+
}
|
|
160
|
+
function isNonEmptyString(value) {
|
|
161
|
+
return typeof value === 'string' && value.length > 0;
|
|
162
|
+
}
|
|
163
|
+
function isPositiveInteger(value) {
|
|
164
|
+
return typeof value === 'number' && Number.isInteger(value) && value >= 1;
|
|
165
|
+
}
|
|
166
|
+
function getBindingIntroductionScope(received, expected, state) {
|
|
167
|
+
const expectedScopes = typeof expected === 'string' ? [expected] : expected;
|
|
168
|
+
const kind = expectedScopes.includes(received) ? received : expectedScopes[0];
|
|
169
|
+
return [...state.scopes].reverse().find((scope) => scope.kind === kind).id;
|
|
170
|
+
}
|
|
171
|
+
function getCurrentLexicalScope(state) {
|
|
172
|
+
return state.scopes[state.scopes.length - 1];
|
|
173
|
+
}
|
|
174
|
+
function visitDeclaration(declaration, path, state) {
|
|
175
|
+
switch (declaration.kind) {
|
|
176
|
+
case 'class':
|
|
177
|
+
validateDeclarationOrigin(declaration, path, state);
|
|
178
|
+
addBindingDefinition(declaration.binding, `${path}.binding`, { kind: 'class', scope: 'module', space: 'value' }, state);
|
|
179
|
+
visitLexicalScope('declaration', path, state, () => {
|
|
180
|
+
visitTypeParameters(declaration.typeParameters, `${path}.typeParameters`, 'declaration', state);
|
|
181
|
+
if (declaration.extends)
|
|
182
|
+
visitType(declaration.extends, `${path}.extends`, state);
|
|
183
|
+
declaration.implements.forEach((type, index) => visitType(type, `${path}.implements[${String(index)}]`, state));
|
|
184
|
+
const parameterPropertyIndexes = new Set();
|
|
185
|
+
declaration.fields.forEach((field, index) => {
|
|
186
|
+
const fieldPath = `${path}.fields[${String(index)}]`;
|
|
187
|
+
visitType(field.type, `${fieldPath}.type`, state);
|
|
188
|
+
if (field.initializer)
|
|
189
|
+
visitExpression(field.initializer, `${fieldPath}.initializer`, state);
|
|
190
|
+
const parameterProperty = field.parameterProperty;
|
|
191
|
+
if (!parameterProperty)
|
|
192
|
+
return;
|
|
193
|
+
const parameterIndex = parameterProperty.parameterIndex;
|
|
194
|
+
const constructorParameter = declaration.classConstructor?.parameters[parameterIndex];
|
|
195
|
+
if (!Number.isInteger(parameterIndex) ||
|
|
196
|
+
parameterIndex < 0 ||
|
|
197
|
+
!constructorParameter ||
|
|
198
|
+
field.static ||
|
|
199
|
+
field.initializer !== undefined ||
|
|
200
|
+
constructorParameter.binding.name !== field.name ||
|
|
201
|
+
parameterPropertyIndexes.has(parameterIndex)) {
|
|
202
|
+
addFailure('invalid-node-shape', `${fieldPath}.parameterProperty`, 'parameter property must uniquely reference its same-named constructor parameter and cannot be static or independently initialized', state);
|
|
203
|
+
return;
|
|
204
|
+
}
|
|
205
|
+
parameterPropertyIndexes.add(parameterIndex);
|
|
206
|
+
});
|
|
207
|
+
const classConstructor = declaration.classConstructor;
|
|
208
|
+
if (classConstructor) {
|
|
209
|
+
visitLexicalScope('function', `${path}.classConstructor`, state, () => {
|
|
210
|
+
visitParameters(classConstructor.parameters, `${path}.classConstructor.parameters`, state);
|
|
211
|
+
visitStatementList(classConstructor.body, `${path}.classConstructor.body`, state);
|
|
212
|
+
});
|
|
213
|
+
classConstructor.overloads.forEach((overload, index) => {
|
|
214
|
+
const overloadPath = `${path}.classConstructor.overloads[${String(index)}]`;
|
|
215
|
+
visitLexicalScope('function', overloadPath, state, () => visitParameters(overload.parameters, `${overloadPath}.parameters`, state));
|
|
216
|
+
});
|
|
217
|
+
}
|
|
218
|
+
declaration.methods.forEach((method, index) => {
|
|
219
|
+
const methodPath = `${path}.methods[${String(index)}]`;
|
|
220
|
+
visitLexicalScope('function', methodPath, state, () => {
|
|
221
|
+
visitFunctionSignature(method, methodPath, state);
|
|
222
|
+
visitStatementList(method.body, `${methodPath}.body`, state);
|
|
223
|
+
});
|
|
224
|
+
method.overloads.forEach((overload, overloadIndex) => {
|
|
225
|
+
const overloadPath = `${methodPath}.overloads[${String(overloadIndex)}]`;
|
|
226
|
+
visitLexicalScope('function', overloadPath, state, () => visitFunctionSignature(overload, overloadPath, state));
|
|
227
|
+
});
|
|
228
|
+
});
|
|
229
|
+
});
|
|
230
|
+
break;
|
|
231
|
+
case 'enum':
|
|
232
|
+
validateDeclarationOrigin(declaration, path, state);
|
|
233
|
+
addBindingDefinition(declaration.binding, `${path}.binding`, { kind: 'enum', scope: 'module', space: 'value' }, state);
|
|
234
|
+
break;
|
|
235
|
+
case 'function':
|
|
236
|
+
validateDeclarationOrigin(declaration, path, state);
|
|
237
|
+
addBindingDefinition(declaration.binding, `${path}.binding`, { kind: 'function', scope: 'module', space: 'value' }, state);
|
|
238
|
+
visitLexicalScope('function', path, state, () => {
|
|
239
|
+
visitFunctionSignature(declaration, path, state);
|
|
240
|
+
visitStatementList(declaration.body, `${path}.body`, state);
|
|
241
|
+
});
|
|
242
|
+
declaration.overloads.forEach((overload, index) => {
|
|
243
|
+
const overloadPath = `${path}.overloads[${String(index)}]`;
|
|
244
|
+
visitLexicalScope('function', overloadPath, state, () => visitFunctionSignature(overload, overloadPath, state));
|
|
245
|
+
});
|
|
246
|
+
break;
|
|
247
|
+
case 'interface':
|
|
248
|
+
validateDeclarationOrigin(declaration, path, state);
|
|
249
|
+
addBindingDefinition(declaration.binding, `${path}.binding`, { kind: 'interface', scope: 'module', space: 'type' }, state);
|
|
250
|
+
visitLexicalScope('declaration', path, state, () => {
|
|
251
|
+
visitTypeParameters(declaration.typeParameters, `${path}.typeParameters`, 'declaration', state);
|
|
252
|
+
declaration.extends.forEach((type, index) => visitType(type, `${path}.extends[${String(index)}]`, state));
|
|
253
|
+
declaration.properties.forEach((property, index) => visitType(property.type, `${path}.properties[${String(index)}].type`, state));
|
|
254
|
+
});
|
|
255
|
+
break;
|
|
256
|
+
case 'typeAlias':
|
|
257
|
+
validateDeclarationOrigin(declaration, path, state);
|
|
258
|
+
addBindingDefinition(declaration.binding, `${path}.binding`, { kind: 'typeAlias', scope: 'module', space: 'type' }, state);
|
|
259
|
+
visitLexicalScope('declaration', path, state, () => {
|
|
260
|
+
visitTypeParameters(declaration.typeParameters, `${path}.typeParameters`, 'declaration', state);
|
|
261
|
+
visitType(declaration.type, `${path}.type`, state);
|
|
262
|
+
});
|
|
263
|
+
break;
|
|
264
|
+
case 'variable':
|
|
265
|
+
validateDeclarationOrigin(declaration, path, state);
|
|
266
|
+
if (!['const', 'let', 'var'].includes(declaration.declarationKind)) {
|
|
267
|
+
addFailure('invalid-node-shape', `${path}.declarationKind`, 'module variable declaration kind must be const, let, or var', state);
|
|
268
|
+
}
|
|
269
|
+
else if ((declaration.declarationKind === 'const') === declaration.mutable) {
|
|
270
|
+
addFailure('invalid-node-shape', `${path}.mutable`, 'const module variables must be immutable and let or var module variables must be mutable', state);
|
|
271
|
+
}
|
|
272
|
+
visitVariable(declaration, path, ['module'], state);
|
|
273
|
+
break;
|
|
274
|
+
default:
|
|
275
|
+
addUnknownKind(declaration, path, state);
|
|
276
|
+
}
|
|
277
|
+
}
|
|
278
|
+
function validateDeclarationOrigin(declaration, path, state) {
|
|
279
|
+
validateSourceOrigin(declaration.origin, `${path}.origin`, 'invalid-declaration-origin', 'declaration', state);
|
|
280
|
+
}
|
|
281
|
+
function visitExpression(expression, path, state) {
|
|
282
|
+
switch (expression.kind) {
|
|
283
|
+
case 'array':
|
|
284
|
+
if (expression.type)
|
|
285
|
+
visitType(expression.type, `${path}.type`, state);
|
|
286
|
+
expression.elements.forEach((element, index) => {
|
|
287
|
+
if (element)
|
|
288
|
+
visitExpression(element, `${path}.elements[${String(index)}]`, state);
|
|
289
|
+
});
|
|
290
|
+
break;
|
|
291
|
+
case 'assignment':
|
|
292
|
+
visitExpression(expression.left, `${path}.left`, state);
|
|
293
|
+
visitExpression(expression.right, `${path}.right`, state);
|
|
294
|
+
break;
|
|
295
|
+
case 'binary':
|
|
296
|
+
visitExpression(expression.left, `${path}.left`, state);
|
|
297
|
+
visitExpression(expression.right, `${path}.right`, state);
|
|
298
|
+
if (expression.semantics.unionMemberTest) {
|
|
299
|
+
const test = expression.semantics.unionMemberTest;
|
|
300
|
+
const testPath = `${path}.semantics.unionMemberTest`;
|
|
301
|
+
if (expression.operator !== '==' &&
|
|
302
|
+
expression.operator !== '===' &&
|
|
303
|
+
expression.operator !== '!=' &&
|
|
304
|
+
expression.operator !== '!==' &&
|
|
305
|
+
expression.operator !== 'instanceof') {
|
|
306
|
+
addFailure('invalid-node-shape', testPath, 'union member test evidence requires an equality or instanceof operator', state);
|
|
307
|
+
}
|
|
308
|
+
if (typeof test.whenResult !== 'boolean') {
|
|
309
|
+
addFailure('invalid-node-shape', `${testPath}.whenResult`, 'union member test result must be boolean', state);
|
|
310
|
+
}
|
|
311
|
+
addBindingReference(test.binding, `${testPath}.binding`, state);
|
|
312
|
+
visitType(test.member, `${testPath}.member`, state);
|
|
313
|
+
}
|
|
314
|
+
break;
|
|
315
|
+
case 'await':
|
|
316
|
+
if (!isIrAwaitSemantics(expression.semantics)) {
|
|
317
|
+
addFailure('invalid-node-shape', `${path}.semantics`, 'await expression requires exact flight-compiler-await-semantics/1 evidence', state);
|
|
318
|
+
}
|
|
319
|
+
visitExpression(expression.expression, `${path}.expression`, state);
|
|
320
|
+
break;
|
|
321
|
+
case 'spread':
|
|
322
|
+
visitExpression(expression.expression, `${path}.expression`, state);
|
|
323
|
+
break;
|
|
324
|
+
case 'call':
|
|
325
|
+
validateIrOptionalChainEvidence(expression.optional, expression.semantics.optionalChain, path, state);
|
|
326
|
+
visitType(expression.semantics.resultType, `${path}.semantics.resultType`, state);
|
|
327
|
+
validateIrInvocationSignatureEvidence(expression, path, state);
|
|
328
|
+
validateIrDefaultParameterInvocationEvidence(expression, path, state);
|
|
329
|
+
validateIrExtraArgumentErasureEvidence(expression, path, state);
|
|
330
|
+
validateIrOptionalParameterInvocationEvidence(expression, path, state);
|
|
331
|
+
validateIrOverloadImplementationInvocationEvidence(expression, path, state);
|
|
332
|
+
if (expression.semantics.statementValue && !isIrCallExpressionStatementValueCarrier(expression)) {
|
|
333
|
+
addFailure('invalid-node-shape', `${path}.semantics.statementValue`, 'statement-value evidence requires a zero-argument function carrier with a final return', state);
|
|
334
|
+
}
|
|
335
|
+
visitExpression(expression.callee, `${path}.callee`, state);
|
|
336
|
+
expression.arguments.forEach((argument, index) => visitExpression(argument, `${path}.arguments[${String(index)}]`, state));
|
|
337
|
+
expression.typeArguments.forEach((type, index) => visitType(type, `${path}.typeArguments[${String(index)}]`, state));
|
|
338
|
+
break;
|
|
339
|
+
case 'new':
|
|
340
|
+
validateIrInvocationSignatureEvidence(expression, path, state);
|
|
341
|
+
validateIrDefaultParameterInvocationEvidence(expression, path, state);
|
|
342
|
+
validateIrOptionalParameterInvocationEvidence(expression, path, state);
|
|
343
|
+
validateIrOverloadImplementationInvocationEvidence(expression, path, state);
|
|
344
|
+
visitExpression(expression.callee, `${path}.callee`, state);
|
|
345
|
+
expression.arguments.forEach((argument, index) => visitExpression(argument, `${path}.arguments[${String(index)}]`, state));
|
|
346
|
+
expression.typeArguments.forEach((type, index) => visitType(type, `${path}.typeArguments[${String(index)}]`, state));
|
|
347
|
+
break;
|
|
348
|
+
case 'cast':
|
|
349
|
+
visitExpression(expression.expression, `${path}.expression`, state);
|
|
350
|
+
visitType(expression.type, `${path}.type`, state);
|
|
351
|
+
break;
|
|
352
|
+
case 'conditional':
|
|
353
|
+
visitExpression(expression.condition, `${path}.condition`, state);
|
|
354
|
+
visitExpression(expression.whenFalse, `${path}.whenFalse`, state);
|
|
355
|
+
visitExpression(expression.whenTrue, `${path}.whenTrue`, state);
|
|
356
|
+
break;
|
|
357
|
+
case 'element':
|
|
358
|
+
if (!compilerIrPropertyKeyCoercions.has(expression.semantics.key)) {
|
|
359
|
+
addFailure('invalid-node-shape', `${path}.semantics.key`, 'element access key coercion is invalid', state);
|
|
360
|
+
}
|
|
361
|
+
if (expression.semantics.closedKeys !== undefined &&
|
|
362
|
+
(!Array.isArray(expression.semantics.closedKeys) ||
|
|
363
|
+
expression.semantics.closedKeys.length === 0 ||
|
|
364
|
+
expression.semantics.closedKeys.some((key) => typeof key !== 'string') ||
|
|
365
|
+
new Set(expression.semantics.closedKeys).size !== expression.semantics.closedKeys.length)) {
|
|
366
|
+
addFailure('invalid-node-shape', `${path}.semantics.closedKeys`, 'closed element keys require one or more distinct strings', state);
|
|
367
|
+
}
|
|
368
|
+
validateIrOptionalChainEvidence(expression.optional, expression.semantics.optionalChain, path, state);
|
|
369
|
+
visitExpression(expression.index, `${path}.index`, state);
|
|
370
|
+
visitExpression(expression.object, `${path}.object`, state);
|
|
371
|
+
break;
|
|
372
|
+
case 'function':
|
|
373
|
+
if (expression.thisMode !== 'dynamic' && expression.thisMode !== 'lexical') {
|
|
374
|
+
addFailure('invalid-node-shape', `${path}.thisMode`, 'function this mode must be dynamic or lexical', state);
|
|
375
|
+
}
|
|
376
|
+
visitLexicalScope('function', path, state, () => {
|
|
377
|
+
if (expression.binding) {
|
|
378
|
+
addBindingDefinition(expression.binding, `${path}.binding`, { kind: 'function', scope: 'function', space: 'value' }, state);
|
|
379
|
+
}
|
|
380
|
+
visitParameters(expression.parameters, `${path}.parameters`, state);
|
|
381
|
+
visitType(expression.returns, `${path}.returns`, state);
|
|
382
|
+
visitTypeParameters(expression.typeParameters, `${path}.typeParameters`, 'function', state);
|
|
383
|
+
visitStatementList(expression.body, `${path}.body`, state);
|
|
384
|
+
if (expression.expression)
|
|
385
|
+
visitExpression(expression.expression, `${path}.expression`, state);
|
|
386
|
+
});
|
|
387
|
+
break;
|
|
388
|
+
case 'identifier':
|
|
389
|
+
if (expression.reference.kind === 'binding') {
|
|
390
|
+
addBindingReference(expression.reference.binding, `${path}.reference.binding`, state);
|
|
391
|
+
}
|
|
392
|
+
break;
|
|
393
|
+
case 'literal':
|
|
394
|
+
case 'regexp':
|
|
395
|
+
break;
|
|
396
|
+
case 'object':
|
|
397
|
+
validateIrObjectCopySemantics(expression, path, state);
|
|
398
|
+
expression.members.forEach((member, index) => visitObjectMember(member, `${path}.members[${String(index)}]`, state));
|
|
399
|
+
if (isIrTypeEvidence(expression.type))
|
|
400
|
+
visitType(expression.type, `${path}.type`, state);
|
|
401
|
+
else
|
|
402
|
+
addFailure('invalid-node-shape', `${path}.type`, 'object construction type evidence is required', state);
|
|
403
|
+
break;
|
|
404
|
+
case 'objectRest':
|
|
405
|
+
visitType(expression.type, `${path}.type`, state);
|
|
406
|
+
visitExpression(expression.object, `${path}.object`, state);
|
|
407
|
+
expression.excluded.forEach((key, index) => {
|
|
408
|
+
const keyPath = `${path}.excluded[${String(index)}]`;
|
|
409
|
+
if (key.kind === 'computed') {
|
|
410
|
+
if (!compilerIrPropertyKeyCoercions.has(key.coercion)) {
|
|
411
|
+
addFailure('invalid-node-shape', `${keyPath}.coercion`, 'object rest key coercion is invalid', state);
|
|
412
|
+
}
|
|
413
|
+
visitExpression(key.expression, `${keyPath}.expression`, state);
|
|
414
|
+
}
|
|
415
|
+
else if (key.name.length === 0) {
|
|
416
|
+
addFailure('invalid-node-shape', `${keyPath}.name`, 'object rest exclusion key must be nonempty', state);
|
|
417
|
+
}
|
|
418
|
+
});
|
|
419
|
+
break;
|
|
420
|
+
case 'property':
|
|
421
|
+
validateIrOptionalChainEvidence(expression.optional, expression.optionalChain, path, state);
|
|
422
|
+
visitExpression(expression.object, `${path}.object`, state);
|
|
423
|
+
if (expression.type)
|
|
424
|
+
visitType(expression.type, `${path}.type`, state);
|
|
425
|
+
break;
|
|
426
|
+
case 'template':
|
|
427
|
+
expression.parts.forEach((part, index) => {
|
|
428
|
+
if (typeof part !== 'string')
|
|
429
|
+
visitExpression(part, `${path}.parts[${String(index)}]`, state);
|
|
430
|
+
});
|
|
431
|
+
break;
|
|
432
|
+
case 'tuple':
|
|
433
|
+
expression.elements.forEach((element, index) => {
|
|
434
|
+
const elementPath = `${path}.elements[${String(index)}]`;
|
|
435
|
+
if (typeof element.optional !== 'boolean') {
|
|
436
|
+
addFailure('invalid-node-shape', `${elementPath}.optional`, 'tuple optional flag must be boolean', state);
|
|
437
|
+
}
|
|
438
|
+
if (!element.optional && !element.expression) {
|
|
439
|
+
addFailure('invalid-node-shape', elementPath, 'required tuple expression element must have a value', state);
|
|
440
|
+
}
|
|
441
|
+
if (element.expression)
|
|
442
|
+
visitExpression(element.expression, `${elementPath}.expression`, state);
|
|
443
|
+
});
|
|
444
|
+
break;
|
|
445
|
+
case 'tupleSpread': {
|
|
446
|
+
visitType(expression.type, `${path}.type`, state);
|
|
447
|
+
if (expression.type.elements.some((element) => element.rest)) {
|
|
448
|
+
addFailure('invalid-node-shape', `${path}.type`, 'tuple spread result type must have fixed width', state);
|
|
449
|
+
}
|
|
450
|
+
if (!expression.segments.some((segment) => segment.kind === 'spread')) {
|
|
451
|
+
addFailure('invalid-node-shape', `${path}.segments`, 'tuple spread requires a spread segment', state);
|
|
452
|
+
}
|
|
453
|
+
const optional = [];
|
|
454
|
+
expression.segments.forEach((segment, index) => {
|
|
455
|
+
const segmentPath = `${path}.segments[${String(index)}]`;
|
|
456
|
+
if (segment.kind === 'element') {
|
|
457
|
+
if (typeof segment.element.optional !== 'boolean') {
|
|
458
|
+
addFailure('invalid-node-shape', `${segmentPath}.element.optional`, 'tuple optional flag must be boolean', state);
|
|
459
|
+
}
|
|
460
|
+
if (!segment.element.optional && !segment.element.expression) {
|
|
461
|
+
addFailure('invalid-node-shape', `${segmentPath}.element`, 'required tuple expression element must have a value', state);
|
|
462
|
+
}
|
|
463
|
+
if (segment.element.expression) {
|
|
464
|
+
visitExpression(segment.element.expression, `${segmentPath}.element.expression`, state);
|
|
465
|
+
}
|
|
466
|
+
optional.push(segment.element.optional);
|
|
467
|
+
return;
|
|
468
|
+
}
|
|
469
|
+
visitExpression(segment.expression, `${segmentPath}.expression`, state);
|
|
470
|
+
visitType(segment.type, `${segmentPath}.type`, state);
|
|
471
|
+
if (segment.type.elements.some((element) => element.rest)) {
|
|
472
|
+
addFailure('invalid-node-shape', `${segmentPath}.type`, 'tuple spread segment must have fixed width', state);
|
|
473
|
+
}
|
|
474
|
+
optional.push(...segment.type.elements.map((element) => element.optional));
|
|
475
|
+
});
|
|
476
|
+
if (optional.length !== expression.type.elements.length) {
|
|
477
|
+
addFailure('invalid-node-shape', `${path}.segments`, 'tuple spread width must match its result type', state);
|
|
478
|
+
}
|
|
479
|
+
optional.forEach((value, index) => {
|
|
480
|
+
const target = expression.type.elements[index];
|
|
481
|
+
if (value && target && !target.optional) {
|
|
482
|
+
addFailure('invalid-node-shape', `${path}.segments`, `optional tuple spread value cannot initialize required index ${String(index)}`, state);
|
|
483
|
+
}
|
|
484
|
+
});
|
|
485
|
+
break;
|
|
486
|
+
}
|
|
487
|
+
case 'tupleRest':
|
|
488
|
+
if (!Number.isSafeInteger(expression.start) || expression.start < 0) {
|
|
489
|
+
addFailure('invalid-node-shape', `${path}.start`, 'tuple rest start must be a nonnegative integer', state);
|
|
490
|
+
}
|
|
491
|
+
visitExpression(expression.object, `${path}.object`, state);
|
|
492
|
+
break;
|
|
493
|
+
case 'tupleSuffix':
|
|
494
|
+
if (!Number.isSafeInteger(expression.start) || expression.start < 0) {
|
|
495
|
+
addFailure('invalid-node-shape', `${path}.start`, 'tuple suffix start must be a nonnegative integer', state);
|
|
496
|
+
}
|
|
497
|
+
if (!Number.isSafeInteger(expression.width) || expression.width < 0) {
|
|
498
|
+
addFailure('invalid-node-shape', `${path}.width`, 'tuple suffix width must be a nonnegative integer', state);
|
|
499
|
+
}
|
|
500
|
+
if (expression.object.kind !== 'identifier') {
|
|
501
|
+
addFailure('invalid-node-shape', `${path}.object`, 'tuple suffix receiver must be an identifier', state);
|
|
502
|
+
}
|
|
503
|
+
visitExpression(expression.object, `${path}.object`, state);
|
|
504
|
+
break;
|
|
505
|
+
case 'unary':
|
|
506
|
+
visitExpression(expression.operand, `${path}.operand`, state);
|
|
507
|
+
break;
|
|
508
|
+
case 'undefinedValue':
|
|
509
|
+
if (!hasIrTypeUndefinedOptionDomain(expression.type)) {
|
|
510
|
+
addFailure('invalid-node-shape', `${path}.type`, 'contextual undefined values require a union with undefined and a concrete value domain', state);
|
|
511
|
+
}
|
|
512
|
+
visitType(expression.type, `${path}.type`, state);
|
|
513
|
+
break;
|
|
514
|
+
case 'undefinedDefault':
|
|
515
|
+
visitExpression(expression.fallback, `${path}.fallback`, state);
|
|
516
|
+
visitExpression(expression.value, `${path}.value`, state);
|
|
517
|
+
break;
|
|
518
|
+
default:
|
|
519
|
+
addUnknownKind(expression, path, state);
|
|
520
|
+
}
|
|
521
|
+
}
|
|
522
|
+
function validateIrObjectCopySemantics(expression, path, state) {
|
|
523
|
+
const hasSpread = expression.members.some((member) => member.kind === 'spread');
|
|
524
|
+
const hasSemantics = Object.hasOwn(expression, 'copySemantics');
|
|
525
|
+
const semantics = expression.copySemantics;
|
|
526
|
+
if (!hasSpread && !hasSemantics)
|
|
527
|
+
return;
|
|
528
|
+
if (hasSpread &&
|
|
529
|
+
hasSemantics &&
|
|
530
|
+
semantics?.evaluation === 'left-to-right-once' &&
|
|
531
|
+
semantics.nullish === 'skip' &&
|
|
532
|
+
semantics.overwrite === 'replace-value-preserve-key-position' &&
|
|
533
|
+
semantics.propertyKeys === 'own-enumerable-string-and-symbol' &&
|
|
534
|
+
semantics.propertyReads === 'get-once-in-own-key-order' &&
|
|
535
|
+
semantics.targetWrites === 'create-data-property') {
|
|
536
|
+
return;
|
|
537
|
+
}
|
|
538
|
+
addFailure('invalid-node-shape', `${path}.copySemantics`, hasSpread
|
|
539
|
+
? 'object spread requires exact copy semantics'
|
|
540
|
+
: 'object copy semantics require at least one spread member', state);
|
|
541
|
+
}
|
|
542
|
+
function hasIrTypeUndefinedOptionDomain(type) {
|
|
543
|
+
if (type.kind !== 'union' || !type.types.some((member) => member.kind === 'undefined'))
|
|
544
|
+
return false;
|
|
545
|
+
return type.types.some((member) => member.kind !== 'null' && member.kind !== 'undefined');
|
|
546
|
+
}
|
|
547
|
+
function validateIrInvocationSignatureEvidence(expression, path, state) {
|
|
548
|
+
const evidence = expression.semantics.signature;
|
|
549
|
+
if (!evidence)
|
|
550
|
+
return;
|
|
551
|
+
const providedValid = evidence.providedArgumentCount === 'dynamic'
|
|
552
|
+
? expression.arguments.some((argument) => argument.kind === 'spread')
|
|
553
|
+
: Number.isSafeInteger(evidence.providedArgumentCount) &&
|
|
554
|
+
evidence.providedArgumentCount >= 0 &&
|
|
555
|
+
evidence.providedArgumentCount === expression.arguments.length &&
|
|
556
|
+
!expression.arguments.some((argument) => argument.kind === 'spread');
|
|
557
|
+
const overloadValid = !expression.semantics.overloadImplementation ||
|
|
558
|
+
expression.semantics.overloadImplementation.implementationParameterCount === evidence.parameterCount;
|
|
559
|
+
const defaultsValid = !expression.semantics.defaultParameters ||
|
|
560
|
+
expression.semantics.defaultParameters.parameterCount === evidence.parameterCount;
|
|
561
|
+
const optionalsValid = !expression.semantics.optionalParameters ||
|
|
562
|
+
expression.semantics.optionalParameters.parameterCount === evidence.parameterCount;
|
|
563
|
+
const restValid = evidence.restParameter === undefined ||
|
|
564
|
+
(Number.isSafeInteger(evidence.restParameter) &&
|
|
565
|
+
evidence.restParameter >= 0 &&
|
|
566
|
+
evidence.restParameter === evidence.parameterCount - 1);
|
|
567
|
+
if (!Number.isSafeInteger(evidence.parameterCount) ||
|
|
568
|
+
evidence.parameterCount < 0 ||
|
|
569
|
+
!providedValid ||
|
|
570
|
+
!overloadValid ||
|
|
571
|
+
!defaultsValid ||
|
|
572
|
+
!optionalsValid ||
|
|
573
|
+
!restValid) {
|
|
574
|
+
addFailure('invalid-node-shape', `${path}.semantics.signature`, 'invocation signature evidence must have exact argument state, implementation ABI arity, and final rest position', state);
|
|
575
|
+
}
|
|
576
|
+
}
|
|
577
|
+
function validateIrDefaultParameterInvocationEvidence(expression, path, state) {
|
|
578
|
+
const evidence = expression.semantics.defaultParameters;
|
|
579
|
+
if (!evidence)
|
|
580
|
+
return;
|
|
581
|
+
const defaultedValid = evidence.defaulted.length > 0 &&
|
|
582
|
+
isStrictlyIncreasingIntegerList(evidence.defaulted) &&
|
|
583
|
+
evidence.defaulted.every((index) => index < evidence.parameterCount);
|
|
584
|
+
const omittedValid = isStrictlyIncreasingIntegerList(evidence.omitted) &&
|
|
585
|
+
evidence.omitted.every((index) => evidence.defaulted.includes(index));
|
|
586
|
+
const providedPositions = Array.isArray(evidence.provided)
|
|
587
|
+
? evidence.provided.map((provided) => provided.position)
|
|
588
|
+
: [];
|
|
589
|
+
const providedEvidenceValid = Array.isArray(evidence.provided) &&
|
|
590
|
+
isStrictlyIncreasingIntegerList(providedPositions) &&
|
|
591
|
+
evidence.provided.every((provided) => evidence.defaulted.includes(provided.position) &&
|
|
592
|
+
isIrTypeEvidence(provided.argumentType) &&
|
|
593
|
+
isIrTypeEvidence(provided.parameterType) &&
|
|
594
|
+
(provided.value === 'null' || provided.value === 'undefined' || provided.value === 'value'));
|
|
595
|
+
const providedArgumentCount = evidence.providedArgumentCount;
|
|
596
|
+
const providedValid = providedArgumentCount === 'dynamic'
|
|
597
|
+
? expression.arguments.some((argument) => argument.kind === 'spread') &&
|
|
598
|
+
evidence.omitted.length === 0 &&
|
|
599
|
+
providedPositions.length === 0
|
|
600
|
+
: Number.isSafeInteger(providedArgumentCount) &&
|
|
601
|
+
providedArgumentCount >= 0 &&
|
|
602
|
+
providedArgumentCount === expression.arguments.length &&
|
|
603
|
+
!expression.arguments.some((argument) => argument.kind === 'spread') &&
|
|
604
|
+
JSON.stringify(providedPositions) ===
|
|
605
|
+
JSON.stringify(evidence.defaulted.filter((index) => index < providedArgumentCount)) &&
|
|
606
|
+
JSON.stringify(evidence.omitted) ===
|
|
607
|
+
JSON.stringify(evidence.defaulted.filter((index) => index >= providedArgumentCount));
|
|
608
|
+
if (!Number.isSafeInteger(evidence.parameterCount) ||
|
|
609
|
+
evidence.parameterCount < 0 ||
|
|
610
|
+
!defaultedValid ||
|
|
611
|
+
!omittedValid ||
|
|
612
|
+
!providedEvidenceValid ||
|
|
613
|
+
!providedValid) {
|
|
614
|
+
addFailure('invalid-node-shape', `${path}.semantics.defaultParameters`, 'default-parameter invocation evidence must have exact arity, ordered positions, value classifications, types, and omission state', state);
|
|
615
|
+
}
|
|
616
|
+
if (providedEvidenceValid) {
|
|
617
|
+
evidence.provided.forEach((provided, index) => {
|
|
618
|
+
visitType(provided.argumentType, `${path}.semantics.defaultParameters.provided[${String(index)}].argumentType`, state);
|
|
619
|
+
visitType(provided.parameterType, `${path}.semantics.defaultParameters.provided[${String(index)}].parameterType`, state);
|
|
620
|
+
});
|
|
621
|
+
}
|
|
622
|
+
}
|
|
623
|
+
function validateIrExtraArgumentErasureEvidence(expression, path, state) {
|
|
624
|
+
const evidence = expression.semantics.extraArguments;
|
|
625
|
+
if (!evidence)
|
|
626
|
+
return;
|
|
627
|
+
const signature = expression.semantics.signature;
|
|
628
|
+
const defaulted = new Set(expression.semantics.defaultParameters?.defaulted ?? []);
|
|
629
|
+
const bindingsValid = Array.isArray(evidence.argumentBindings) &&
|
|
630
|
+
evidence.argumentBindings.length === expression.arguments.length &&
|
|
631
|
+
new Set(evidence.argumentBindings.map((binding) => binding.id)).size === evidence.argumentBindings.length &&
|
|
632
|
+
evidence.argumentBindings.every((binding) => isNonEmptyString(binding.id) &&
|
|
633
|
+
isNonEmptyString(binding.name) &&
|
|
634
|
+
binding.kind === 'variable' &&
|
|
635
|
+
binding.scope === 'block' &&
|
|
636
|
+
binding.space === 'value');
|
|
637
|
+
const eligible = signature !== undefined &&
|
|
638
|
+
typeof signature.providedArgumentCount === 'number' &&
|
|
639
|
+
signature.providedArgumentCount > signature.parameterCount &&
|
|
640
|
+
signature.restParameter === undefined &&
|
|
641
|
+
!expression.optional &&
|
|
642
|
+
expression.callee.kind === 'identifier' &&
|
|
643
|
+
expression.callee.reference.kind !== 'super' &&
|
|
644
|
+
expression.callee.reference.kind !== 'this' &&
|
|
645
|
+
!expression.arguments
|
|
646
|
+
.slice(0, signature.parameterCount)
|
|
647
|
+
.some((argument, index) => argument.kind === 'undefinedValue' && defaulted.has(index)) &&
|
|
648
|
+
expression.semantics.statementValue === undefined;
|
|
649
|
+
if (!eligible || !bindingsValid || !isIrTypeEvidence(evidence.resultType)) {
|
|
650
|
+
addFailure('invalid-node-shape', `${path}.semantics.extraArguments`, 'extra-argument erasure evidence requires a fixed direct call, one distinct block binding per argument, and result type evidence', state);
|
|
651
|
+
return;
|
|
652
|
+
}
|
|
653
|
+
evidence.argumentBindings.forEach((binding, index) => {
|
|
654
|
+
validateSourceOrigin(binding, `${path}.semantics.extraArguments.argumentBindings[${String(index)}]`, 'invalid-binding-origin', 'extra-argument carrier binding', state);
|
|
655
|
+
});
|
|
656
|
+
visitType(evidence.resultType, `${path}.semantics.extraArguments.resultType`, state);
|
|
657
|
+
}
|
|
658
|
+
function validateIrOptionalParameterInvocationEvidence(expression, path, state) {
|
|
659
|
+
const evidence = expression.semantics.optionalParameters;
|
|
660
|
+
if (!evidence)
|
|
661
|
+
return;
|
|
662
|
+
const optionalValid = evidence.optional.length > 0 &&
|
|
663
|
+
isStrictlyIncreasingIntegerList(evidence.optional) &&
|
|
664
|
+
evidence.optional.every((index) => index < evidence.parameterCount);
|
|
665
|
+
const omittedValid = isStrictlyIncreasingIntegerList(evidence.omitted) &&
|
|
666
|
+
evidence.omitted.every((index) => evidence.optional.includes(index));
|
|
667
|
+
const providedArgumentCount = evidence.providedArgumentCount;
|
|
668
|
+
const providedPositions = Array.isArray(evidence.provided)
|
|
669
|
+
? evidence.provided.map((provided) => provided.position)
|
|
670
|
+
: [];
|
|
671
|
+
const providedEvidenceValid = Array.isArray(evidence.provided) &&
|
|
672
|
+
isStrictlyIncreasingIntegerList(providedPositions) &&
|
|
673
|
+
evidence.provided.every((provided) => evidence.optional.includes(provided.position) &&
|
|
674
|
+
isIrTypeEvidence(provided.argumentType) &&
|
|
675
|
+
isIrTypeEvidence(provided.parameterType) &&
|
|
676
|
+
(provided.value === 'null' || provided.value === 'undefined' || provided.value === 'value'));
|
|
677
|
+
const providedValid = providedArgumentCount === 'dynamic'
|
|
678
|
+
? expression.arguments.some((argument) => argument.kind === 'spread') &&
|
|
679
|
+
evidence.omitted.length === 0 &&
|
|
680
|
+
providedPositions.length === 0
|
|
681
|
+
: Number.isSafeInteger(providedArgumentCount) &&
|
|
682
|
+
providedArgumentCount >= 0 &&
|
|
683
|
+
providedArgumentCount === expression.arguments.length &&
|
|
684
|
+
!expression.arguments.some((argument) => argument.kind === 'spread') &&
|
|
685
|
+
JSON.stringify(providedPositions) ===
|
|
686
|
+
JSON.stringify(evidence.optional.filter((index) => index < providedArgumentCount)) &&
|
|
687
|
+
JSON.stringify(evidence.omitted) ===
|
|
688
|
+
JSON.stringify(evidence.optional.filter((index) => index >= providedArgumentCount));
|
|
689
|
+
const defaults = expression.semantics.defaultParameters;
|
|
690
|
+
const compatibleWithDefaults = !defaults ||
|
|
691
|
+
(defaults.parameterCount === evidence.parameterCount &&
|
|
692
|
+
defaults.providedArgumentCount === evidence.providedArgumentCount &&
|
|
693
|
+
defaults.defaulted.every((index) => !evidence.optional.includes(index)));
|
|
694
|
+
if (!Number.isSafeInteger(evidence.parameterCount) ||
|
|
695
|
+
evidence.parameterCount < 0 ||
|
|
696
|
+
!optionalValid ||
|
|
697
|
+
!omittedValid ||
|
|
698
|
+
!providedEvidenceValid ||
|
|
699
|
+
!providedValid ||
|
|
700
|
+
!compatibleWithDefaults) {
|
|
701
|
+
addFailure('invalid-node-shape', `${path}.semantics.optionalParameters`, 'optional-parameter invocation evidence must have exact arity, ordered positions, value classifications, types, distinct defaults, and omission state', state);
|
|
702
|
+
}
|
|
703
|
+
if (providedEvidenceValid) {
|
|
704
|
+
evidence.provided.forEach((provided, index) => {
|
|
705
|
+
visitType(provided.argumentType, `${path}.semantics.optionalParameters.provided[${String(index)}].argumentType`, state);
|
|
706
|
+
visitType(provided.parameterType, `${path}.semantics.optionalParameters.provided[${String(index)}].parameterType`, state);
|
|
707
|
+
});
|
|
708
|
+
}
|
|
709
|
+
}
|
|
710
|
+
function validateIrOverloadImplementationInvocationEvidence(expression, path, state) {
|
|
711
|
+
const evidence = expression.semantics.overloadImplementation;
|
|
712
|
+
if (!evidence)
|
|
713
|
+
return;
|
|
714
|
+
const countsValid = Number.isSafeInteger(evidence.implementationParameterCount) &&
|
|
715
|
+
evidence.implementationParameterCount >= 0 &&
|
|
716
|
+
Number.isSafeInteger(evidence.resolvedParameterCount) &&
|
|
717
|
+
evidence.resolvedParameterCount >= 0;
|
|
718
|
+
const indexValid = Number.isSafeInteger(evidence.overloadIndex) && evidence.overloadIndex >= 0;
|
|
719
|
+
const defaultsValid = !expression.semantics.defaultParameters ||
|
|
720
|
+
expression.semantics.defaultParameters.parameterCount === evidence.implementationParameterCount;
|
|
721
|
+
const optionalsValid = !expression.semantics.optionalParameters ||
|
|
722
|
+
expression.semantics.optionalParameters.parameterCount === evidence.implementationParameterCount;
|
|
723
|
+
if (!countsValid || !indexValid || !defaultsValid || !optionalsValid) {
|
|
724
|
+
addFailure('invalid-node-shape', `${path}.semantics.overloadImplementation`, 'overload implementation evidence must identify nonnegative signature arities, source order, and implementation ABI carriers', state);
|
|
725
|
+
}
|
|
726
|
+
}
|
|
727
|
+
function isStrictlyIncreasingIntegerList(values) {
|
|
728
|
+
return values.every((value, index) => Number.isSafeInteger(value) && value >= 0 && (index === 0 || values[index - 1] < value));
|
|
729
|
+
}
|
|
730
|
+
function visitFunctionSignature(signature, path, state) {
|
|
731
|
+
visitParameters(signature.parameters, `${path}.parameters`, state);
|
|
732
|
+
visitType(signature.returns, `${path}.returns`, state);
|
|
733
|
+
visitTypeParameters(signature.typeParameters, `${path}.typeParameters`, 'function', state);
|
|
734
|
+
}
|
|
735
|
+
function visitObjectMember(member, path, state) {
|
|
736
|
+
switch (member.kind) {
|
|
737
|
+
case 'computedProperty':
|
|
738
|
+
visitExpression(member.key, `${path}.key`, state);
|
|
739
|
+
visitExpression(member.value, `${path}.value`, state);
|
|
740
|
+
break;
|
|
741
|
+
case 'getAccessor':
|
|
742
|
+
case 'property':
|
|
743
|
+
visitExpression(member.value, `${path}.value`, state);
|
|
744
|
+
break;
|
|
745
|
+
case 'spread':
|
|
746
|
+
visitExpression(member.expression, `${path}.expression`, state);
|
|
747
|
+
break;
|
|
748
|
+
default:
|
|
749
|
+
addUnknownKind(member, path, state);
|
|
750
|
+
}
|
|
751
|
+
}
|
|
752
|
+
function visitParameters(parameters, path, state) {
|
|
753
|
+
validateParameterCardinality(parameters, path, state);
|
|
754
|
+
parameters.forEach((parameter, index) => {
|
|
755
|
+
const parameterPath = `${path}[${String(index)}]`;
|
|
756
|
+
addBindingDefinition(parameter.binding, `${parameterPath}.binding`, { kind: 'parameter', scope: 'function', space: 'value' }, state);
|
|
757
|
+
visitType(parameter.type, `${parameterPath}.type`, state);
|
|
758
|
+
const dependentPack = parameter.dependentCallablePack;
|
|
759
|
+
if (dependentPack) {
|
|
760
|
+
const projectedCallable = parameter.type.kind === 'named' &&
|
|
761
|
+
parameter.type.reference.kind === 'ambient' &&
|
|
762
|
+
parameter.type.reference.name === 'Parameters' &&
|
|
763
|
+
parameter.type.typeArguments.length === 1
|
|
764
|
+
? parameter.type.typeArguments[0]
|
|
765
|
+
: undefined;
|
|
766
|
+
const coherent = parameter.rest &&
|
|
767
|
+
(dependentPack.kind === 'parameters' || dependentPack.kind === 'implementation') &&
|
|
768
|
+
dependentPack.schema === 'flight-compiler-dependent-callable-pack/1' &&
|
|
769
|
+
dependentPack.callable.kind === 'typeParameter' &&
|
|
770
|
+
dependentPack.constraint.kind === 'function' &&
|
|
771
|
+
dependentPack.constraint.typeParameters.length === 0 &&
|
|
772
|
+
(dependentPack.kind === 'parameters'
|
|
773
|
+
? projectedCallable?.kind === 'named' &&
|
|
774
|
+
projectedCallable.reference.kind === 'binding' &&
|
|
775
|
+
projectedCallable.reference.path.length === 0 &&
|
|
776
|
+
projectedCallable.reference.binding.id === dependentPack.callable.id
|
|
777
|
+
: parameter.type.kind === 'array' &&
|
|
778
|
+
parameter.type.element.kind === 'unknown' &&
|
|
779
|
+
parameter.type.element.source === 'any');
|
|
780
|
+
if (!coherent) {
|
|
781
|
+
addFailure('invalid-node-shape', `${parameterPath}.dependentCallablePack`, 'dependent callable-pack evidence requires a rest Parameters<T> projection or cast-bound any[] implementation of one nongeneric callable type parameter', state);
|
|
782
|
+
}
|
|
783
|
+
addBindingReference(dependentPack.callable, `${parameterPath}.dependentCallablePack.callable`, state);
|
|
784
|
+
visitType(dependentPack.constraint, `${parameterPath}.dependentCallablePack.constraint`, state);
|
|
785
|
+
}
|
|
786
|
+
if (parameter.initializer)
|
|
787
|
+
visitExpression(parameter.initializer, `${parameterPath}.initializer`, state);
|
|
788
|
+
});
|
|
789
|
+
}
|
|
790
|
+
function visitStatement(statement, path, state) {
|
|
791
|
+
const label = 'label' in statement ? statement.label : undefined;
|
|
792
|
+
if (label) {
|
|
793
|
+
validateControlFlowLabel(label, `${path}.label`, state);
|
|
794
|
+
state.controlFlowLabels.push({
|
|
795
|
+
continuable: statement.kind === 'do' ||
|
|
796
|
+
statement.kind === 'for' ||
|
|
797
|
+
statement.kind === 'forIn' ||
|
|
798
|
+
statement.kind === 'forOf' ||
|
|
799
|
+
statement.kind === 'while',
|
|
800
|
+
label,
|
|
801
|
+
});
|
|
802
|
+
}
|
|
803
|
+
try {
|
|
804
|
+
switch (statement.kind) {
|
|
805
|
+
case 'block':
|
|
806
|
+
visitStatementList(statement.statements, `${path}.statements`, state);
|
|
807
|
+
break;
|
|
808
|
+
case 'break':
|
|
809
|
+
if (statement.target)
|
|
810
|
+
validateControlFlowTarget(statement.target, false, `${path}.target`, state);
|
|
811
|
+
break;
|
|
812
|
+
case 'continue':
|
|
813
|
+
if (statement.target)
|
|
814
|
+
validateControlFlowTarget(statement.target, true, `${path}.target`, state);
|
|
815
|
+
break;
|
|
816
|
+
case 'do':
|
|
817
|
+
case 'while':
|
|
818
|
+
visitStatement(statement.body, `${path}.body`, state);
|
|
819
|
+
visitExpression(statement.condition, `${path}.condition`, state);
|
|
820
|
+
break;
|
|
821
|
+
case 'expression':
|
|
822
|
+
case 'throw':
|
|
823
|
+
visitExpression(statement.expression, `${path}.expression`, state);
|
|
824
|
+
break;
|
|
825
|
+
case 'for':
|
|
826
|
+
visitLexicalScope('block', path, state, () => {
|
|
827
|
+
if (Array.isArray(statement.initializer)) {
|
|
828
|
+
statement.initializer.forEach((variable, index) => visitVariable(variable, `${path}.initializer[${String(index)}]`, ['block', 'function'], state));
|
|
829
|
+
}
|
|
830
|
+
else if (statement.initializer) {
|
|
831
|
+
visitExpression(statement.initializer, `${path}.initializer`, state);
|
|
832
|
+
}
|
|
833
|
+
if (statement.condition)
|
|
834
|
+
visitExpression(statement.condition, `${path}.condition`, state);
|
|
835
|
+
if (statement.increment)
|
|
836
|
+
visitExpression(statement.increment, `${path}.increment`, state);
|
|
837
|
+
visitStatement(statement.body, `${path}.body`, state);
|
|
838
|
+
});
|
|
839
|
+
break;
|
|
840
|
+
case 'forIn': {
|
|
841
|
+
visitExpression(statement.object, `${path}.object`, state);
|
|
842
|
+
if (statement.keyPlan) {
|
|
843
|
+
const keys = getIrExpressionStaticForInKeys(statement.object);
|
|
844
|
+
const validSource = statement.keyPlan.kind === 'objectLiteral'
|
|
845
|
+
? statement.object.kind === 'object' &&
|
|
846
|
+
keys !== undefined &&
|
|
847
|
+
statement.keyPlan.evaluation ===
|
|
848
|
+
(statement.object.members.every((member) => member.kind === 'property' && member.value.kind === 'literal')
|
|
849
|
+
? 'elide'
|
|
850
|
+
: 'preserve')
|
|
851
|
+
: statement.keyPlan.kind === 'closedRecord' &&
|
|
852
|
+
statement.keyPlan.evaluation === 'alreadyEvaluated' &&
|
|
853
|
+
statement.object.kind === 'identifier';
|
|
854
|
+
if (!validSource) {
|
|
855
|
+
addFailure('invalid-node-shape', `${path}.keyPlan`, 'for-in key plan source and evaluation classification must match its object expression', state);
|
|
856
|
+
}
|
|
857
|
+
else if (statement.keyPlan.keys.some((key) => typeof key !== 'string') ||
|
|
858
|
+
new Set(statement.keyPlan.keys).size !== statement.keyPlan.keys.length ||
|
|
859
|
+
JSON.stringify(statement.keyPlan.keys) !==
|
|
860
|
+
JSON.stringify(statement.keyPlan.kind === 'objectLiteral' ? keys : orderIrStaticForInKeys(statement.keyPlan.keys))) {
|
|
861
|
+
addFailure('invalid-node-shape', `${path}.keyPlan.keys`, 'static for-in keys must exactly match JavaScript object enumeration order', state);
|
|
862
|
+
}
|
|
863
|
+
}
|
|
864
|
+
visitLexicalScope('block', path, state, () => {
|
|
865
|
+
visitVariable(statement.variable, `${path}.variable`, ['block', 'function'], state);
|
|
866
|
+
if (statement.variable.type?.kind !== 'primitive' || statement.variable.type.name !== 'string') {
|
|
867
|
+
addFailure('invalid-node-shape', `${path}.variable.type`, 'for-in binding requires primitive string type evidence', state);
|
|
868
|
+
}
|
|
869
|
+
visitStatement(statement.body, `${path}.body`, state);
|
|
870
|
+
});
|
|
871
|
+
break;
|
|
872
|
+
}
|
|
873
|
+
case 'forOf':
|
|
874
|
+
visitExpression(statement.iterable, `${path}.iterable`, state);
|
|
875
|
+
visitLexicalScope('block', path, state, () => {
|
|
876
|
+
visitVariable(statement.variable, `${path}.variable`, ['block', 'function'], state);
|
|
877
|
+
visitStatement(statement.body, `${path}.body`, state);
|
|
878
|
+
});
|
|
879
|
+
break;
|
|
880
|
+
case 'if':
|
|
881
|
+
visitExpression(statement.condition, `${path}.condition`, state);
|
|
882
|
+
visitStatement(statement.consequent, `${path}.consequent`, state);
|
|
883
|
+
if (statement.otherwise)
|
|
884
|
+
visitStatement(statement.otherwise, `${path}.otherwise`, state);
|
|
885
|
+
break;
|
|
886
|
+
case 'return':
|
|
887
|
+
if (statement.expression)
|
|
888
|
+
visitExpression(statement.expression, `${path}.expression`, state);
|
|
889
|
+
break;
|
|
890
|
+
case 'switch':
|
|
891
|
+
visitExpression(statement.expression, `${path}.expression`, state);
|
|
892
|
+
visitLexicalScope('block', `${path}.cases`, state, () => {
|
|
893
|
+
statement.cases.forEach((switchCase, index) => {
|
|
894
|
+
const casePath = `${path}.cases[${String(index)}]`;
|
|
895
|
+
if (switchCase.expression)
|
|
896
|
+
visitExpression(switchCase.expression, `${casePath}.expression`, state);
|
|
897
|
+
switchCase.statements.forEach((child, statementIndex) => visitStatement(child, `${casePath}.statements[${String(statementIndex)}]`, state));
|
|
898
|
+
});
|
|
899
|
+
});
|
|
900
|
+
break;
|
|
901
|
+
case 'try':
|
|
902
|
+
visitStatement(statement.tryBody, `${path}.tryBody`, state);
|
|
903
|
+
const catchClause = statement.catchClause;
|
|
904
|
+
if (catchClause) {
|
|
905
|
+
if (!isIrCatchSemantics(catchClause.semantics)) {
|
|
906
|
+
addFailure('invalid-node-shape', `${path}.catchClause.semantics`, 'catch clause requires exact flight-compiler-catch-semantics/1 evidence', state);
|
|
907
|
+
}
|
|
908
|
+
else if ((catchClause.binding && catchClause.semantics.bindingInitialization.kind !== 'initialize') ||
|
|
909
|
+
(!catchClause.binding && catchClause.semantics.bindingInitialization.kind !== 'discard')) {
|
|
910
|
+
addFailure('invalid-node-shape', `${path}.catchClause.semantics.bindingInitialization`, 'catch binding presence must agree with thrown-value initialization evidence', state);
|
|
911
|
+
}
|
|
912
|
+
visitLexicalScope('block', `${path}.catchClause`, state, () => {
|
|
913
|
+
if (catchClause.binding) {
|
|
914
|
+
addBindingDefinition(catchClause.binding, `${path}.catchClause.binding`, { kind: 'catch', scope: 'block', space: 'value' }, state);
|
|
915
|
+
}
|
|
916
|
+
visitStatement(catchClause.body, `${path}.catchClause.body`, state);
|
|
917
|
+
});
|
|
918
|
+
}
|
|
919
|
+
if (statement.finallyBody)
|
|
920
|
+
visitStatement(statement.finallyBody, `${path}.finallyBody`, state);
|
|
921
|
+
break;
|
|
922
|
+
case 'variable':
|
|
923
|
+
statement.declarations.forEach((variable, index) => visitVariable(variable, `${path}.declarations[${String(index)}]`, ['block', 'function'], state));
|
|
924
|
+
break;
|
|
925
|
+
default:
|
|
926
|
+
addUnknownKind(statement, path, state);
|
|
927
|
+
}
|
|
928
|
+
}
|
|
929
|
+
finally {
|
|
930
|
+
if (label)
|
|
931
|
+
state.controlFlowLabels.pop();
|
|
932
|
+
}
|
|
933
|
+
}
|
|
934
|
+
function validateControlFlowLabel(label, path, state) {
|
|
935
|
+
validateSourceOrigin(label, path, 'invalid-node-shape', 'control-flow label', state);
|
|
936
|
+
if (!isNonEmptyString(label.id) || !isNonEmptyString(label.name)) {
|
|
937
|
+
addFailure('invalid-node-shape', path, 'control-flow label identity and name must be nonempty', state);
|
|
938
|
+
}
|
|
939
|
+
if (state.controlFlowLabels.some((definition) => definition.label.id === label.id)) {
|
|
940
|
+
addFailure('invalid-node-shape', path, `control-flow label ${label.id} is already active`, state);
|
|
941
|
+
}
|
|
942
|
+
}
|
|
943
|
+
function validateControlFlowTarget(target, continuable, path, state) {
|
|
944
|
+
validateSourceOrigin(target, path, 'invalid-node-shape', 'control-flow target', state);
|
|
945
|
+
let definition;
|
|
946
|
+
for (let index = state.controlFlowLabels.length - 1; index >= 0; index -= 1) {
|
|
947
|
+
const candidate = state.controlFlowLabels[index];
|
|
948
|
+
if (candidate.label.id === target.id) {
|
|
949
|
+
definition = candidate;
|
|
950
|
+
break;
|
|
951
|
+
}
|
|
952
|
+
}
|
|
953
|
+
if (!definition || definition.label.name !== target.name) {
|
|
954
|
+
addFailure('invalid-node-shape', path, `control-flow target ${target.id} is not an active label`, state);
|
|
955
|
+
}
|
|
956
|
+
else if (continuable && !definition.continuable) {
|
|
957
|
+
addFailure('invalid-node-shape', path, `continue target ${target.id} is not a loop label`, state);
|
|
958
|
+
}
|
|
959
|
+
}
|
|
960
|
+
function visitStatementList(statements, path, state) {
|
|
961
|
+
visitLexicalScope('block', path, state, () => {
|
|
962
|
+
statements.forEach((statement, index) => visitStatement(statement, `${path}[${String(index)}]`, state));
|
|
963
|
+
});
|
|
964
|
+
}
|
|
965
|
+
function visitType(type, path, state) {
|
|
966
|
+
if (!isIrTypeEvidence(type)) {
|
|
967
|
+
addFailure('invalid-node-shape', path, 'type evidence requires a discriminated type value', state);
|
|
968
|
+
return;
|
|
969
|
+
}
|
|
970
|
+
switch (type.kind) {
|
|
971
|
+
case 'array':
|
|
972
|
+
visitType(type.element, `${path}.element`, state);
|
|
973
|
+
break;
|
|
974
|
+
case 'conditionalFacet':
|
|
975
|
+
if (type.path.length === 0 || type.path.some((segment) => segment.length === 0)) {
|
|
976
|
+
addFailure('invalid-node-shape', `${path}.path`, 'conditional facet path requires one or more nonempty member names', state);
|
|
977
|
+
}
|
|
978
|
+
visitType(type.check, `${path}.check`, state);
|
|
979
|
+
visitType(type.facet, `${path}.facet`, state);
|
|
980
|
+
break;
|
|
981
|
+
case 'function':
|
|
982
|
+
visitLexicalScope('function', path, state, () => {
|
|
983
|
+
validateParameterCardinality(type.parameters, `${path}.parameters`, state);
|
|
984
|
+
type.parameters.forEach((parameter, index) => visitType(parameter.type, `${path}.parameters[${String(index)}].type`, state));
|
|
985
|
+
visitType(type.returns, `${path}.returns`, state);
|
|
986
|
+
visitTypeParameters(type.typeParameters, `${path}.typeParameters`, 'function', state);
|
|
987
|
+
});
|
|
988
|
+
break;
|
|
989
|
+
case 'indexedAccess':
|
|
990
|
+
visitType(type.index, `${path}.index`, state);
|
|
991
|
+
visitType(type.object, `${path}.object`, state);
|
|
992
|
+
break;
|
|
993
|
+
case 'intersection':
|
|
994
|
+
case 'union':
|
|
995
|
+
if (type.types.length < 2) {
|
|
996
|
+
addFailure('invalid-compound-type-arity', path, `${type.kind} types require at least two members`, state);
|
|
997
|
+
}
|
|
998
|
+
type.types.forEach((member, index) => visitType(member, `${path}.types[${String(index)}]`, state));
|
|
999
|
+
break;
|
|
1000
|
+
case 'keyof':
|
|
1001
|
+
visitType(type.type, `${path}.type`, state);
|
|
1002
|
+
break;
|
|
1003
|
+
case 'literal':
|
|
1004
|
+
case 'never':
|
|
1005
|
+
case 'null':
|
|
1006
|
+
case 'primitive':
|
|
1007
|
+
case 'undefined':
|
|
1008
|
+
case 'unknown':
|
|
1009
|
+
break;
|
|
1010
|
+
case 'named':
|
|
1011
|
+
if (type.reference.kind === 'binding') {
|
|
1012
|
+
addBindingReference(type.reference.binding, `${path}.reference.binding`, state);
|
|
1013
|
+
}
|
|
1014
|
+
type.typeArguments.forEach((argument, index) => visitType(argument, `${path}.typeArguments[${String(index)}]`, state));
|
|
1015
|
+
break;
|
|
1016
|
+
case 'object':
|
|
1017
|
+
{
|
|
1018
|
+
const propertyNames = new Set();
|
|
1019
|
+
type.properties.forEach((property, index) => {
|
|
1020
|
+
const propertyPath = `${path}.properties[${String(index)}]`;
|
|
1021
|
+
if (property.name.length === 0) {
|
|
1022
|
+
addFailure('invalid-node-shape', `${propertyPath}.name`, 'object property name must be nonempty', state);
|
|
1023
|
+
}
|
|
1024
|
+
else if (propertyNames.has(property.name)) {
|
|
1025
|
+
addFailure('invalid-node-shape', `${propertyPath}.name`, 'object property names must be unique', state);
|
|
1026
|
+
}
|
|
1027
|
+
propertyNames.add(property.name);
|
|
1028
|
+
if (property.computedKey) {
|
|
1029
|
+
if (property.computedKey.kind === 'ambient') {
|
|
1030
|
+
if (property.computedKey.name.length === 0) {
|
|
1031
|
+
addFailure('invalid-node-shape', `${propertyPath}.computedKey.name`, 'computed object property ambient key must be nonempty', state);
|
|
1032
|
+
}
|
|
1033
|
+
}
|
|
1034
|
+
else if (property.computedKey.binding.space !== 'value') {
|
|
1035
|
+
addFailure('invalid-node-shape', `${propertyPath}.computedKey.binding.space`, 'computed object property key must refer to a value binding', state);
|
|
1036
|
+
}
|
|
1037
|
+
}
|
|
1038
|
+
if (typeof property.optional !== 'boolean') {
|
|
1039
|
+
addFailure('invalid-node-shape', `${propertyPath}.optional`, 'object optional marker must be boolean', state);
|
|
1040
|
+
}
|
|
1041
|
+
if (typeof property.readonly !== 'boolean') {
|
|
1042
|
+
addFailure('invalid-node-shape', `${propertyPath}.readonly`, 'object readonly marker must be boolean', state);
|
|
1043
|
+
}
|
|
1044
|
+
if (property.phantom !== undefined && (property.phantom !== true || !property.computedKey)) {
|
|
1045
|
+
addFailure('invalid-node-shape', `${propertyPath}.phantom`, 'phantom object property must be a computed key marked true', state);
|
|
1046
|
+
}
|
|
1047
|
+
visitType(property.type, `${propertyPath}.type`, state);
|
|
1048
|
+
});
|
|
1049
|
+
}
|
|
1050
|
+
break;
|
|
1051
|
+
case 'tuple':
|
|
1052
|
+
validateParameterCardinality(type.elements, `${path}.elements`, state);
|
|
1053
|
+
type.elements.forEach((element, index) => visitType(element.type, `${path}.elements[${String(index)}].type`, state));
|
|
1054
|
+
break;
|
|
1055
|
+
case 'typeOf':
|
|
1056
|
+
if (type.reference.kind === 'binding') {
|
|
1057
|
+
addBindingReference(type.reference.binding, `${path}.reference.binding`, state);
|
|
1058
|
+
}
|
|
1059
|
+
break;
|
|
1060
|
+
default:
|
|
1061
|
+
addUnknownKind(type, path, state);
|
|
1062
|
+
}
|
|
1063
|
+
}
|
|
1064
|
+
function visitTypeParameters(parameters, path, scope, state) {
|
|
1065
|
+
parameters.forEach((parameter, index) => {
|
|
1066
|
+
const parameterPath = `${path}[${String(index)}]`;
|
|
1067
|
+
addBindingDefinition(parameter.binding, `${parameterPath}.binding`, { kind: 'typeParameter', scope, space: 'type' }, state);
|
|
1068
|
+
if (parameter.constraint)
|
|
1069
|
+
visitType(parameter.constraint, `${parameterPath}.constraint`, state);
|
|
1070
|
+
if (parameter.default)
|
|
1071
|
+
visitType(parameter.default, `${parameterPath}.default`, state);
|
|
1072
|
+
});
|
|
1073
|
+
}
|
|
1074
|
+
function getIrExpressionStaticForInKeys(expression) {
|
|
1075
|
+
if (expression.kind !== 'object' || expression.members.some((member) => member.kind !== 'property')) {
|
|
1076
|
+
return undefined;
|
|
1077
|
+
}
|
|
1078
|
+
const keys = [];
|
|
1079
|
+
expression.members.forEach((member) => {
|
|
1080
|
+
if (member.kind === 'property' && !keys.includes(member.name))
|
|
1081
|
+
keys.push(member.name);
|
|
1082
|
+
});
|
|
1083
|
+
return orderIrStaticForInKeys(keys);
|
|
1084
|
+
}
|
|
1085
|
+
function orderIrStaticForInKeys(keys) {
|
|
1086
|
+
const indices = [];
|
|
1087
|
+
const names = [];
|
|
1088
|
+
for (const key of keys) {
|
|
1089
|
+
const value = Number(key);
|
|
1090
|
+
if (Number.isSafeInteger(value) && value >= 0 && value < 4_294_967_295 && String(value) === key) {
|
|
1091
|
+
indices.push({ key, value });
|
|
1092
|
+
}
|
|
1093
|
+
else {
|
|
1094
|
+
names.push(key);
|
|
1095
|
+
}
|
|
1096
|
+
}
|
|
1097
|
+
indices.sort((left, right) => left.value - right.value);
|
|
1098
|
+
return [...indices.map((index) => index.key), ...names];
|
|
1099
|
+
}
|
|
1100
|
+
const compilerIrPropertyKeyCoercions = new Set(['number', 'string', 'symbol', 'toPropertyKey']);
|
|
1101
|
+
function visitVariable(variable, path, scopes, state) {
|
|
1102
|
+
if ('pattern' in variable) {
|
|
1103
|
+
visitBindingPattern(variable.pattern, `${path}.pattern`, scopes, state);
|
|
1104
|
+
}
|
|
1105
|
+
else {
|
|
1106
|
+
addBindingDefinition(variable.binding, `${path}.binding`, { kind: 'variable', scope: scopes, space: 'value' }, state);
|
|
1107
|
+
if (variable.initialValue !== undefined) {
|
|
1108
|
+
if (variable.initialValue !== 'undefined' && variable.initialValue !== 'uninitialized') {
|
|
1109
|
+
addFailure('invalid-node-shape', `${path}.initialValue`, 'variable initial value must be undefined or proven uninitialized', state);
|
|
1110
|
+
}
|
|
1111
|
+
if (variable.binding.scope !== 'function') {
|
|
1112
|
+
addFailure('invalid-node-shape', `${path}.initialValue`, 'only function-scoped variables may have an entry-value classification', state);
|
|
1113
|
+
}
|
|
1114
|
+
if (variable.initializer) {
|
|
1115
|
+
addFailure('invalid-node-shape', `${path}.initialValue`, 'an entry-value classification cannot share a declaration with an initializer', state);
|
|
1116
|
+
}
|
|
1117
|
+
}
|
|
1118
|
+
}
|
|
1119
|
+
if (variable.type)
|
|
1120
|
+
visitType(variable.type, `${path}.type`, state);
|
|
1121
|
+
if (variable.initializer)
|
|
1122
|
+
visitExpression(variable.initializer, `${path}.initializer`, state);
|
|
1123
|
+
}
|
|
1124
|
+
function visitBindingPattern(pattern, path, scopes, state) {
|
|
1125
|
+
switch (pattern.kind) {
|
|
1126
|
+
case 'array':
|
|
1127
|
+
validateSourceOrigin(pattern, path, 'invalid-binding-origin', 'binding pattern', state);
|
|
1128
|
+
if (!scopes.includes(pattern.scope)) {
|
|
1129
|
+
addFailure('invalid-binding-introduction', path, `binding pattern scope must be ${scopes.join(' or ')}`, state);
|
|
1130
|
+
}
|
|
1131
|
+
pattern.elements.forEach((element, index) => {
|
|
1132
|
+
if (!element)
|
|
1133
|
+
return;
|
|
1134
|
+
const elementPath = `${path}.elements[${String(index)}]`;
|
|
1135
|
+
visitBindingPattern(element.pattern, `${elementPath}.pattern`, [pattern.scope], state);
|
|
1136
|
+
if (element.initializer)
|
|
1137
|
+
visitExpression(element.initializer, `${elementPath}.initializer`, state);
|
|
1138
|
+
});
|
|
1139
|
+
if (pattern.rest)
|
|
1140
|
+
visitBindingPattern(pattern.rest, `${path}.rest`, [pattern.scope], state);
|
|
1141
|
+
if (pattern.type)
|
|
1142
|
+
visitType(pattern.type, `${path}.type`, state);
|
|
1143
|
+
break;
|
|
1144
|
+
case 'binding':
|
|
1145
|
+
addBindingDefinition(pattern.binding, `${path}.binding`, { kind: 'variable', scope: scopes, space: 'value' }, state);
|
|
1146
|
+
if (pattern.type)
|
|
1147
|
+
visitType(pattern.type, `${path}.type`, state);
|
|
1148
|
+
break;
|
|
1149
|
+
case 'object':
|
|
1150
|
+
validateSourceOrigin(pattern, path, 'invalid-binding-origin', 'binding pattern', state);
|
|
1151
|
+
if (!scopes.includes(pattern.scope)) {
|
|
1152
|
+
addFailure('invalid-binding-introduction', path, `binding pattern scope must be ${scopes.join(' or ')}`, state);
|
|
1153
|
+
}
|
|
1154
|
+
pattern.properties.forEach((property, index) => {
|
|
1155
|
+
const propertyPath = `${path}.properties[${String(index)}]`;
|
|
1156
|
+
if (property.key.kind === 'computed') {
|
|
1157
|
+
visitExpression(property.key.expression, `${propertyPath}.key.expression`, state);
|
|
1158
|
+
}
|
|
1159
|
+
else if (property.key.name.length === 0) {
|
|
1160
|
+
addFailure('invalid-node-shape', `${propertyPath}.key.name`, 'object binding key must be nonempty', state);
|
|
1161
|
+
}
|
|
1162
|
+
visitBindingPattern(property.pattern, `${propertyPath}.pattern`, [pattern.scope], state);
|
|
1163
|
+
if (property.initializer)
|
|
1164
|
+
visitExpression(property.initializer, `${propertyPath}.initializer`, state);
|
|
1165
|
+
});
|
|
1166
|
+
if (pattern.rest) {
|
|
1167
|
+
if (pattern.rest.kind !== 'binding') {
|
|
1168
|
+
addFailure('invalid-node-shape', `${path}.rest`, 'object binding rest must introduce one binding', state);
|
|
1169
|
+
}
|
|
1170
|
+
visitBindingPattern(pattern.rest, `${path}.rest`, [pattern.scope], state);
|
|
1171
|
+
}
|
|
1172
|
+
if (pattern.type)
|
|
1173
|
+
visitType(pattern.type, `${path}.type`, state);
|
|
1174
|
+
break;
|
|
1175
|
+
default:
|
|
1176
|
+
addUnknownKind(pattern, path, state);
|
|
1177
|
+
}
|
|
1178
|
+
}
|
|
1179
|
+
function validateBindingOrigin(binding, path, state) {
|
|
1180
|
+
validateSourceOrigin(binding, path, 'invalid-binding-origin', 'binding', state);
|
|
1181
|
+
}
|
|
1182
|
+
function validateBindingIntroduction(binding, path, expectation, state) {
|
|
1183
|
+
const scopes = typeof expectation.scope === 'string' ? [expectation.scope] : expectation.scope;
|
|
1184
|
+
if (binding.space !== expectation.space || binding.kind !== expectation.kind || !scopes.includes(binding.scope)) {
|
|
1185
|
+
addFailure('invalid-binding-introduction', path, `binding introduction requires ${expectation.space} ${expectation.kind} in ${scopes.join(' or ')} scope`, state);
|
|
1186
|
+
}
|
|
1187
|
+
}
|
|
1188
|
+
function validateSourceOrigin(origin, path, code, subject, state) {
|
|
1189
|
+
if (origin.packageName !== state.module.packageName ||
|
|
1190
|
+
origin.source !== state.module.source ||
|
|
1191
|
+
!isPositiveInteger(origin.line) ||
|
|
1192
|
+
!isPositiveInteger(origin.column) ||
|
|
1193
|
+
!isCompilerSourceFingerprint(origin.fingerprint)) {
|
|
1194
|
+
addFailure(code, path, `${subject} origin must identify a positive source location in its containing module and an exact SHA-256 fingerprint`, state);
|
|
1195
|
+
}
|
|
1196
|
+
}
|
|
1197
|
+
function validateBindingReferences(state) {
|
|
1198
|
+
for (const reference of state.references) {
|
|
1199
|
+
const definitions = state.bindings.get(reference.binding.id);
|
|
1200
|
+
if (!definitions) {
|
|
1201
|
+
addFailure('dangling-binding-reference', reference.path, `binding ${reference.binding.id} has no introduction in the module`, state);
|
|
1202
|
+
continue;
|
|
1203
|
+
}
|
|
1204
|
+
const definition = getNearestBindingDefinition(definitions, reference.scope, state.scopeParents);
|
|
1205
|
+
const expected = (definition ?? definitions[0]).binding;
|
|
1206
|
+
const received = reference.binding;
|
|
1207
|
+
if (expected.space !== received.space ||
|
|
1208
|
+
expected.kind !== received.kind ||
|
|
1209
|
+
expected.scope !== received.scope ||
|
|
1210
|
+
expected.packageName !== received.packageName ||
|
|
1211
|
+
expected.source !== received.source ||
|
|
1212
|
+
expected.line !== received.line ||
|
|
1213
|
+
expected.column !== received.column ||
|
|
1214
|
+
expected.fingerprint !== received.fingerprint) {
|
|
1215
|
+
addFailure('inconsistent-binding-reference', reference.path, `binding ${received.id} metadata differs from its introduction at ${(definition ?? definitions[0]).path}`, state);
|
|
1216
|
+
}
|
|
1217
|
+
if (!definition) {
|
|
1218
|
+
addFailure('out-of-scope-binding-reference', reference.path, `binding ${received.id} is introduced outside the reference's lexical scope at ${definitions[0].path}`, state);
|
|
1219
|
+
}
|
|
1220
|
+
}
|
|
1221
|
+
}
|
|
1222
|
+
function getNearestBindingDefinition(definitions, referenceScope, parents) {
|
|
1223
|
+
let scope = referenceScope;
|
|
1224
|
+
while (scope !== undefined) {
|
|
1225
|
+
const definition = definitions.find((candidate) => candidate.scope === scope);
|
|
1226
|
+
if (definition)
|
|
1227
|
+
return definition;
|
|
1228
|
+
scope = parents.get(scope);
|
|
1229
|
+
}
|
|
1230
|
+
return undefined;
|
|
1231
|
+
}
|
|
1232
|
+
function validateModuleIdentity(module, state) {
|
|
1233
|
+
if (!isNonEmptyString(module.name) || !isNonEmptyString(module.packageName) || !isNonEmptyString(module.source)) {
|
|
1234
|
+
addFailure('invalid-module-identity', '$', 'module name, packageName, and source must be nonempty strings', state);
|
|
1235
|
+
}
|
|
1236
|
+
}
|
|
1237
|
+
function validateParameterCardinality(parameters, path, state) {
|
|
1238
|
+
parameters.forEach((parameter, index) => {
|
|
1239
|
+
if ((parameter.rest && parameter.optional) ||
|
|
1240
|
+
(parameter.initializer !== undefined && !parameter.optional) ||
|
|
1241
|
+
(parameter.rest && index !== parameters.length - 1)) {
|
|
1242
|
+
addFailure('invalid-parameter-cardinality', `${path}[${String(index)}]`, 'rest values must be required, initializer-free, and last; initializers require optional cardinality', state);
|
|
1243
|
+
}
|
|
1244
|
+
});
|
|
1245
|
+
}
|
|
1246
|
+
function visitLexicalScope(kind, path, state, visit) {
|
|
1247
|
+
const parent = getCurrentLexicalScope(state).id;
|
|
1248
|
+
const scope = { id: `${path}#${kind}`, kind };
|
|
1249
|
+
state.scopeParents.set(scope.id, parent);
|
|
1250
|
+
state.scopes.push(scope);
|
|
1251
|
+
try {
|
|
1252
|
+
visit();
|
|
1253
|
+
}
|
|
1254
|
+
finally {
|
|
1255
|
+
state.scopes.pop();
|
|
1256
|
+
}
|
|
1257
|
+
}
|
|
1258
|
+
//# sourceMappingURL=compilerIrModuleStructure.js.map
|