@sunshaobei/dsh-workflow 0.0.0-stage → 2.1.2
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/README.md +43 -2
- package/cordis.patch.yml +17 -0
- package/lib/client.js +14708 -0
- package/lib/core.js +137 -0
- package/lib/engine-adapter.js +1387 -0
- package/lib/host-driver.js +298 -0
- package/lib/index.js +536 -0
- package/lib/projection.js +159 -0
- package/lib/registry.js +218 -0
- package/lib/session-records.js +54 -0
- package/lib/submission-commit.js +34 -0
- package/lib/world-driver.js +275 -0
- package/package.json +67 -4
- package/vendor/PROVENANCE.md +9 -0
- package/vendor/dynamic-workflow/analysis/actor-graph.d.ts +47 -0
- package/vendor/dynamic-workflow/analysis/actor-graph.d.ts.map +1 -0
- package/vendor/dynamic-workflow/analysis/actor-graph.js +95 -0
- package/vendor/dynamic-workflow/analysis/actor-models.d.ts +60 -0
- package/vendor/dynamic-workflow/analysis/actor-models.d.ts.map +1 -0
- package/vendor/dynamic-workflow/analysis/actor-models.js +208 -0
- package/vendor/dynamic-workflow/analysis/actor-names.d.ts +56 -0
- package/vendor/dynamic-workflow/analysis/actor-names.d.ts.map +1 -0
- package/vendor/dynamic-workflow/analysis/actor-names.js +155 -0
- package/vendor/dynamic-workflow/analysis/analyze.d.ts +63 -0
- package/vendor/dynamic-workflow/analysis/analyze.d.ts.map +1 -0
- package/vendor/dynamic-workflow/analysis/analyze.js +92 -0
- package/vendor/dynamic-workflow/analysis/array-methods.d.ts +21 -0
- package/vendor/dynamic-workflow/analysis/array-methods.d.ts.map +1 -0
- package/vendor/dynamic-workflow/analysis/array-methods.js +132 -0
- package/vendor/dynamic-workflow/analysis/artifact-types.d.ts +39 -0
- package/vendor/dynamic-workflow/analysis/artifact-types.d.ts.map +1 -0
- package/vendor/dynamic-workflow/analysis/artifact-types.js +114 -0
- package/vendor/dynamic-workflow/analysis/artifacts.d.ts +67 -0
- package/vendor/dynamic-workflow/analysis/artifacts.d.ts.map +1 -0
- package/vendor/dynamic-workflow/analysis/artifacts.js +263 -0
- package/vendor/dynamic-workflow/analysis/assign.d.ts +42 -0
- package/vendor/dynamic-workflow/analysis/assign.d.ts.map +1 -0
- package/vendor/dynamic-workflow/analysis/assign.js +287 -0
- package/vendor/dynamic-workflow/analysis/callbacks.d.ts +71 -0
- package/vendor/dynamic-workflow/analysis/callbacks.d.ts.map +1 -0
- package/vendor/dynamic-workflow/analysis/callbacks.js +133 -0
- package/vendor/dynamic-workflow/analysis/calls.d.ts +40 -0
- package/vendor/dynamic-workflow/analysis/calls.d.ts.map +1 -0
- package/vendor/dynamic-workflow/analysis/calls.js +495 -0
- package/vendor/dynamic-workflow/analysis/causality-graph-lanes.d.ts +25 -0
- package/vendor/dynamic-workflow/analysis/causality-graph-lanes.d.ts.map +1 -0
- package/vendor/dynamic-workflow/analysis/causality-graph-lanes.js +161 -0
- package/vendor/dynamic-workflow/analysis/causality-graph-types.d.ts +163 -0
- package/vendor/dynamic-workflow/analysis/causality-graph-types.d.ts.map +1 -0
- package/vendor/dynamic-workflow/analysis/causality-graph-types.js +8 -0
- package/vendor/dynamic-workflow/analysis/causality-graph.d.ts +39 -0
- package/vendor/dynamic-workflow/analysis/causality-graph.d.ts.map +1 -0
- package/vendor/dynamic-workflow/analysis/causality-graph.js +530 -0
- package/vendor/dynamic-workflow/analysis/causality-order-calls.d.ts +29 -0
- package/vendor/dynamic-workflow/analysis/causality-order-calls.d.ts.map +1 -0
- package/vendor/dynamic-workflow/analysis/causality-order-calls.js +266 -0
- package/vendor/dynamic-workflow/analysis/causality-order-functions.d.ts +26 -0
- package/vendor/dynamic-workflow/analysis/causality-order-functions.d.ts.map +1 -0
- package/vendor/dynamic-workflow/analysis/causality-order-functions.js +116 -0
- package/vendor/dynamic-workflow/analysis/causality-order-loops.d.ts +5 -0
- package/vendor/dynamic-workflow/analysis/causality-order-loops.d.ts.map +1 -0
- package/vendor/dynamic-workflow/analysis/causality-order-loops.js +148 -0
- package/vendor/dynamic-workflow/analysis/causality-order-settle.d.ts +39 -0
- package/vendor/dynamic-workflow/analysis/causality-order-settle.d.ts.map +1 -0
- package/vendor/dynamic-workflow/analysis/causality-order-settle.js +263 -0
- package/vendor/dynamic-workflow/analysis/causality-order-state.d.ts +110 -0
- package/vendor/dynamic-workflow/analysis/causality-order-state.d.ts.map +1 -0
- package/vendor/dynamic-workflow/analysis/causality-order-state.js +162 -0
- package/vendor/dynamic-workflow/analysis/causality-order-strands.d.ts +79 -0
- package/vendor/dynamic-workflow/analysis/causality-order-strands.d.ts.map +1 -0
- package/vendor/dynamic-workflow/analysis/causality-order-strands.js +154 -0
- package/vendor/dynamic-workflow/analysis/causality-order-types.d.ts +174 -0
- package/vendor/dynamic-workflow/analysis/causality-order-types.d.ts.map +1 -0
- package/vendor/dynamic-workflow/analysis/causality-order-types.js +1 -0
- package/vendor/dynamic-workflow/analysis/causality-order-walk.d.ts +17 -0
- package/vendor/dynamic-workflow/analysis/causality-order-walk.d.ts.map +1 -0
- package/vendor/dynamic-workflow/analysis/causality-order-walk.js +282 -0
- package/vendor/dynamic-workflow/analysis/causality-order.d.ts +60 -0
- package/vendor/dynamic-workflow/analysis/causality-order.d.ts.map +1 -0
- package/vendor/dynamic-workflow/analysis/causality-order.js +110 -0
- package/vendor/dynamic-workflow/analysis/causality-reduce.d.ts +60 -0
- package/vendor/dynamic-workflow/analysis/causality-reduce.d.ts.map +1 -0
- package/vendor/dynamic-workflow/analysis/causality-reduce.js +198 -0
- package/vendor/dynamic-workflow/analysis/classes.d.ts +47 -0
- package/vendor/dynamic-workflow/analysis/classes.d.ts.map +1 -0
- package/vendor/dynamic-workflow/analysis/classes.js +264 -0
- package/vendor/dynamic-workflow/analysis/constants.d.ts +35 -0
- package/vendor/dynamic-workflow/analysis/constants.d.ts.map +1 -0
- package/vendor/dynamic-workflow/analysis/constants.js +23 -0
- package/vendor/dynamic-workflow/analysis/control-flow.d.ts +26 -0
- package/vendor/dynamic-workflow/analysis/control-flow.d.ts.map +1 -0
- package/vendor/dynamic-workflow/analysis/control-flow.js +132 -0
- package/vendor/dynamic-workflow/analysis/core-json.d.ts +45 -0
- package/vendor/dynamic-workflow/analysis/core-json.d.ts.map +1 -0
- package/vendor/dynamic-workflow/analysis/core-json.js +49 -0
- package/vendor/dynamic-workflow/analysis/core.d.ts +194 -0
- package/vendor/dynamic-workflow/analysis/core.d.ts.map +1 -0
- package/vendor/dynamic-workflow/analysis/core.js +204 -0
- package/vendor/dynamic-workflow/analysis/domain.d.ts +269 -0
- package/vendor/dynamic-workflow/analysis/domain.d.ts.map +1 -0
- package/vendor/dynamic-workflow/analysis/domain.js +523 -0
- package/vendor/dynamic-workflow/analysis/facade-misuse.d.ts +56 -0
- package/vendor/dynamic-workflow/analysis/facade-misuse.d.ts.map +1 -0
- package/vendor/dynamic-workflow/analysis/facade-misuse.js +350 -0
- package/vendor/dynamic-workflow/analysis/fanout-cardinality.d.ts +11 -0
- package/vendor/dynamic-workflow/analysis/fanout-cardinality.d.ts.map +1 -0
- package/vendor/dynamic-workflow/analysis/fanout-cardinality.js +121 -0
- package/vendor/dynamic-workflow/analysis/flow-graph.d.ts +113 -0
- package/vendor/dynamic-workflow/analysis/flow-graph.d.ts.map +1 -0
- package/vendor/dynamic-workflow/analysis/flow-graph.js +411 -0
- package/vendor/dynamic-workflow/analysis/flow-phase.d.ts +28 -0
- package/vendor/dynamic-workflow/analysis/flow-phase.d.ts.map +1 -0
- package/vendor/dynamic-workflow/analysis/flow-phase.js +104 -0
- package/vendor/dynamic-workflow/analysis/flow-strands.d.ts +39 -0
- package/vendor/dynamic-workflow/analysis/flow-strands.d.ts.map +1 -0
- package/vendor/dynamic-workflow/analysis/flow-strands.js +47 -0
- package/vendor/dynamic-workflow/analysis/flow-tree.d.ts +35 -0
- package/vendor/dynamic-workflow/analysis/flow-tree.d.ts.map +1 -0
- package/vendor/dynamic-workflow/analysis/flow-tree.js +33 -0
- package/vendor/dynamic-workflow/analysis/graph.d.ts +5 -0
- package/vendor/dynamic-workflow/analysis/graph.d.ts.map +1 -0
- package/vendor/dynamic-workflow/analysis/graph.js +199 -0
- package/vendor/dynamic-workflow/analysis/handoff-graph.d.ts +48 -0
- package/vendor/dynamic-workflow/analysis/handoff-graph.d.ts.map +1 -0
- package/vendor/dynamic-workflow/analysis/handoff-graph.js +0 -0
- package/vendor/dynamic-workflow/analysis/heap-ops.d.ts +14 -0
- package/vendor/dynamic-workflow/analysis/heap-ops.d.ts.map +1 -0
- package/vendor/dynamic-workflow/analysis/heap-ops.js +70 -0
- package/vendor/dynamic-workflow/analysis/hole-id.d.ts +28 -0
- package/vendor/dynamic-workflow/analysis/hole-id.d.ts.map +1 -0
- package/vendor/dynamic-workflow/analysis/hole-id.js +41 -0
- package/vendor/dynamic-workflow/analysis/hole-sites.d.ts +32 -0
- package/vendor/dynamic-workflow/analysis/hole-sites.d.ts.map +1 -0
- package/vendor/dynamic-workflow/analysis/hole-sites.js +215 -0
- package/vendor/dynamic-workflow/analysis/hole-splice.d.ts +45 -0
- package/vendor/dynamic-workflow/analysis/hole-splice.d.ts.map +1 -0
- package/vendor/dynamic-workflow/analysis/hole-splice.js +100 -0
- package/vendor/dynamic-workflow/analysis/interpret.d.ts +26 -0
- package/vendor/dynamic-workflow/analysis/interpret.d.ts.map +1 -0
- package/vendor/dynamic-workflow/analysis/interpret.js +200 -0
- package/vendor/dynamic-workflow/analysis/literals.d.ts +18 -0
- package/vendor/dynamic-workflow/analysis/literals.d.ts.map +1 -0
- package/vendor/dynamic-workflow/analysis/literals.js +125 -0
- package/vendor/dynamic-workflow/analysis/mermaid.d.ts +60 -0
- package/vendor/dynamic-workflow/analysis/mermaid.d.ts.map +1 -0
- package/vendor/dynamic-workflow/analysis/mermaid.js +477 -0
- package/vendor/dynamic-workflow/analysis/patterns.d.ts +31 -0
- package/vendor/dynamic-workflow/analysis/patterns.d.ts.map +1 -0
- package/vendor/dynamic-workflow/analysis/patterns.js +94 -0
- package/vendor/dynamic-workflow/analysis/phase-graph.d.ts +47 -0
- package/vendor/dynamic-workflow/analysis/phase-graph.d.ts.map +1 -0
- package/vendor/dynamic-workflow/analysis/phase-graph.js +334 -0
- package/vendor/dynamic-workflow/analysis/phases.d.ts +24 -0
- package/vendor/dynamic-workflow/analysis/phases.d.ts.map +1 -0
- package/vendor/dynamic-workflow/analysis/phases.js +54 -0
- package/vendor/dynamic-workflow/analysis/promise-ops.d.ts +52 -0
- package/vendor/dynamic-workflow/analysis/promise-ops.d.ts.map +1 -0
- package/vendor/dynamic-workflow/analysis/promise-ops.js +123 -0
- package/vendor/dynamic-workflow/analysis/relays.d.ts +12 -0
- package/vendor/dynamic-workflow/analysis/relays.d.ts.map +1 -0
- package/vendor/dynamic-workflow/analysis/relays.js +78 -0
- package/vendor/dynamic-workflow/analysis/serialize.d.ts +125 -0
- package/vendor/dynamic-workflow/analysis/serialize.d.ts.map +1 -0
- package/vendor/dynamic-workflow/analysis/serialize.js +321 -0
- package/vendor/dynamic-workflow/analysis/site-phases.d.ts +32 -0
- package/vendor/dynamic-workflow/analysis/site-phases.d.ts.map +1 -0
- package/vendor/dynamic-workflow/analysis/site-phases.js +69 -0
- package/vendor/dynamic-workflow/analysis/sites-labels.d.ts +71 -0
- package/vendor/dynamic-workflow/analysis/sites-labels.d.ts.map +1 -0
- package/vendor/dynamic-workflow/analysis/sites-labels.js +189 -0
- package/vendor/dynamic-workflow/analysis/sites.d.ts +267 -0
- package/vendor/dynamic-workflow/analysis/sites.d.ts.map +1 -0
- package/vendor/dynamic-workflow/analysis/sites.js +225 -0
- package/vendor/dynamic-workflow/analysis/state.d.ts +254 -0
- package/vendor/dynamic-workflow/analysis/state.d.ts.map +1 -0
- package/vendor/dynamic-workflow/analysis/state.js +569 -0
- package/vendor/dynamic-workflow/analysis/taint.d.ts +97 -0
- package/vendor/dynamic-workflow/analysis/taint.d.ts.map +1 -0
- package/vendor/dynamic-workflow/analysis/taint.js +649 -0
- package/vendor/dynamic-workflow/analysis/types.d.ts +100 -0
- package/vendor/dynamic-workflow/analysis/types.d.ts.map +1 -0
- package/vendor/dynamic-workflow/analysis/types.js +1 -0
- package/vendor/dynamic-workflow/analysis/world-run.d.ts +27 -0
- package/vendor/dynamic-workflow/analysis/world-run.d.ts.map +1 -0
- package/vendor/dynamic-workflow/analysis/world-run.js +44 -0
- package/vendor/dynamic-workflow/compiler/compile.d.ts +59 -0
- package/vendor/dynamic-workflow/compiler/compile.d.ts.map +1 -0
- package/vendor/dynamic-workflow/compiler/compile.js +159 -0
- package/vendor/dynamic-workflow/compiler/libs.generated.d.ts +3 -0
- package/vendor/dynamic-workflow/compiler/libs.generated.d.ts.map +1 -0
- package/vendor/dynamic-workflow/compiler/libs.generated.js +64 -0
- package/vendor/dynamic-workflow/engine/artifact-spec.d.ts +26 -0
- package/vendor/dynamic-workflow/engine/artifact-spec.d.ts.map +1 -0
- package/vendor/dynamic-workflow/engine/artifact-spec.js +173 -0
- package/vendor/dynamic-workflow/engine/ask-observation-types.d.ts +54 -0
- package/vendor/dynamic-workflow/engine/ask-observation-types.d.ts.map +1 -0
- package/vendor/dynamic-workflow/engine/ask-observation-types.js +19 -0
- package/vendor/dynamic-workflow/engine/cached-ask-facts.d.ts +28 -0
- package/vendor/dynamic-workflow/engine/cached-ask-facts.d.ts.map +1 -0
- package/vendor/dynamic-workflow/engine/cached-ask-facts.js +35 -0
- package/vendor/dynamic-workflow/engine/concurrency.d.ts +151 -0
- package/vendor/dynamic-workflow/engine/concurrency.d.ts.map +1 -0
- package/vendor/dynamic-workflow/engine/concurrency.js +282 -0
- package/vendor/dynamic-workflow/engine/engine-artifacts-primary.d.ts +17 -0
- package/vendor/dynamic-workflow/engine/engine-artifacts-primary.d.ts.map +1 -0
- package/vendor/dynamic-workflow/engine/engine-artifacts-primary.js +29 -0
- package/vendor/dynamic-workflow/engine/engine-artifacts.d.ts +55 -0
- package/vendor/dynamic-workflow/engine/engine-artifacts.d.ts.map +1 -0
- package/vendor/dynamic-workflow/engine/engine-artifacts.js +367 -0
- package/vendor/dynamic-workflow/engine/engine-config.d.ts +90 -0
- package/vendor/dynamic-workflow/engine/engine-config.d.ts.map +1 -0
- package/vendor/dynamic-workflow/engine/engine-config.js +6 -0
- package/vendor/dynamic-workflow/engine/engine-holes.d.ts +116 -0
- package/vendor/dynamic-workflow/engine/engine-holes.d.ts.map +1 -0
- package/vendor/dynamic-workflow/engine/engine-holes.js +142 -0
- package/vendor/dynamic-workflow/engine/engine-launch.d.ts +34 -0
- package/vendor/dynamic-workflow/engine/engine-launch.d.ts.map +1 -0
- package/vendor/dynamic-workflow/engine/engine-launch.js +26 -0
- package/vendor/dynamic-workflow/engine/engine-phase-stamp.d.ts +35 -0
- package/vendor/dynamic-workflow/engine/engine-phase-stamp.d.ts.map +1 -0
- package/vendor/dynamic-workflow/engine/engine-phase-stamp.js +74 -0
- package/vendor/dynamic-workflow/engine/engine-report.d.ts +27 -0
- package/vendor/dynamic-workflow/engine/engine-report.d.ts.map +1 -0
- package/vendor/dynamic-workflow/engine/engine-report.js +151 -0
- package/vendor/dynamic-workflow/engine/engine-resume.d.ts +18 -0
- package/vendor/dynamic-workflow/engine/engine-resume.d.ts.map +1 -0
- package/vendor/dynamic-workflow/engine/engine-resume.js +38 -0
- package/vendor/dynamic-workflow/engine/engine-settlement.d.ts +30 -0
- package/vendor/dynamic-workflow/engine/engine-settlement.d.ts.map +1 -0
- package/vendor/dynamic-workflow/engine/engine-settlement.js +79 -0
- package/vendor/dynamic-workflow/engine/engine-state.d.ts +99 -0
- package/vendor/dynamic-workflow/engine/engine-state.d.ts.map +1 -0
- package/vendor/dynamic-workflow/engine/engine-state.js +13 -0
- package/vendor/dynamic-workflow/engine/engine-world.d.ts +36 -0
- package/vendor/dynamic-workflow/engine/engine-world.d.ts.map +1 -0
- package/vendor/dynamic-workflow/engine/engine-world.js +189 -0
- package/vendor/dynamic-workflow/engine/engine.d.ts +263 -0
- package/vendor/dynamic-workflow/engine/engine.d.ts.map +1 -0
- package/vendor/dynamic-workflow/engine/engine.js +602 -0
- package/vendor/dynamic-workflow/engine/errors.d.ts +87 -0
- package/vendor/dynamic-workflow/engine/errors.d.ts.map +1 -0
- package/vendor/dynamic-workflow/engine/errors.js +56 -0
- package/vendor/dynamic-workflow/engine/hash-mismatch.d.ts +10 -0
- package/vendor/dynamic-workflow/engine/hash-mismatch.d.ts.map +1 -0
- package/vendor/dynamic-workflow/engine/hash-mismatch.js +15 -0
- package/vendor/dynamic-workflow/engine/hash.d.ts +16 -0
- package/vendor/dynamic-workflow/engine/hash.d.ts.map +1 -0
- package/vendor/dynamic-workflow/engine/hash.js +48 -0
- package/vendor/dynamic-workflow/engine/imported-cache-types.d.ts +96 -0
- package/vendor/dynamic-workflow/engine/imported-cache-types.d.ts.map +1 -0
- package/vendor/dynamic-workflow/engine/imported-cache-types.js +6 -0
- package/vendor/dynamic-workflow/engine/imported-cache.d.ts +127 -0
- package/vendor/dynamic-workflow/engine/imported-cache.d.ts.map +1 -0
- package/vendor/dynamic-workflow/engine/imported-cache.js +244 -0
- package/vendor/dynamic-workflow/engine/index.d.ts +11 -0
- package/vendor/dynamic-workflow/engine/index.d.ts.map +1 -0
- package/vendor/dynamic-workflow/engine/index.js +10 -0
- package/vendor/dynamic-workflow/engine/journal-memory.d.ts +32 -0
- package/vendor/dynamic-workflow/engine/journal-memory.d.ts.map +1 -0
- package/vendor/dynamic-workflow/engine/journal-memory.js +243 -0
- package/vendor/dynamic-workflow/engine/journal-read-types.d.ts +72 -0
- package/vendor/dynamic-workflow/engine/journal-read-types.d.ts.map +1 -0
- package/vendor/dynamic-workflow/engine/journal-read-types.js +28 -0
- package/vendor/dynamic-workflow/engine/persona.d.ts +20 -0
- package/vendor/dynamic-workflow/engine/persona.d.ts.map +1 -0
- package/vendor/dynamic-workflow/engine/persona.js +43 -0
- package/vendor/dynamic-workflow/engine/replay-order.d.ts +96 -0
- package/vendor/dynamic-workflow/engine/replay-order.d.ts.map +1 -0
- package/vendor/dynamic-workflow/engine/replay-order.js +229 -0
- package/vendor/dynamic-workflow/engine/run-terminal.d.ts +35 -0
- package/vendor/dynamic-workflow/engine/run-terminal.d.ts.map +1 -0
- package/vendor/dynamic-workflow/engine/run-terminal.js +7 -0
- package/vendor/dynamic-workflow/engine/scheduler-submit.d.ts +22 -0
- package/vendor/dynamic-workflow/engine/scheduler-submit.d.ts.map +1 -0
- package/vendor/dynamic-workflow/engine/scheduler-submit.js +84 -0
- package/vendor/dynamic-workflow/engine/scheduler-types.d.ts +105 -0
- package/vendor/dynamic-workflow/engine/scheduler-types.d.ts.map +1 -0
- package/vendor/dynamic-workflow/engine/scheduler-types.js +17 -0
- package/vendor/dynamic-workflow/engine/scheduler.d.ts +113 -0
- package/vendor/dynamic-workflow/engine/scheduler.d.ts.map +1 -0
- package/vendor/dynamic-workflow/engine/scheduler.js +484 -0
- package/vendor/dynamic-workflow/engine/types.d.ts +979 -0
- package/vendor/dynamic-workflow/engine/types.d.ts.map +1 -0
- package/vendor/dynamic-workflow/engine/types.js +26 -0
- package/vendor/dynamic-workflow/engine/world-read-input.d.ts +10 -0
- package/vendor/dynamic-workflow/engine/world-read-input.d.ts.map +1 -0
- package/vendor/dynamic-workflow/engine/world-read-input.js +55 -0
- package/vendor/dynamic-workflow/facade/artifact-caps.d.ts +48 -0
- package/vendor/dynamic-workflow/facade/artifact-caps.d.ts.map +1 -0
- package/vendor/dynamic-workflow/facade/artifact-caps.js +47 -0
- package/vendor/dynamic-workflow/facade/dts-hole.d.ts +16 -0
- package/vendor/dynamic-workflow/facade/dts-hole.d.ts.map +1 -0
- package/vendor/dynamic-workflow/facade/dts-hole.js +26 -0
- package/vendor/dynamic-workflow/facade/dts-model.d.ts +11 -0
- package/vendor/dynamic-workflow/facade/dts-model.d.ts.map +1 -0
- package/vendor/dynamic-workflow/facade/dts-model.js +18 -0
- package/vendor/dynamic-workflow/facade/dts-stream.d.ts +15 -0
- package/vendor/dynamic-workflow/facade/dts-stream.d.ts.map +1 -0
- package/vendor/dynamic-workflow/facade/dts-stream.js +41 -0
- package/vendor/dynamic-workflow/facade/dts.d.ts +29 -0
- package/vendor/dynamic-workflow/facade/dts.d.ts.map +1 -0
- package/vendor/dynamic-workflow/facade/dts.js +324 -0
- package/vendor/dynamic-workflow/facade/registry.d.ts +218 -0
- package/vendor/dynamic-workflow/facade/registry.d.ts.map +1 -0
- package/vendor/dynamic-workflow/facade/registry.js +203 -0
- package/vendor/dynamic-workflow/facade/report-caps.d.ts +40 -0
- package/vendor/dynamic-workflow/facade/report-caps.d.ts.map +1 -0
- package/vendor/dynamic-workflow/facade/report-caps.js +39 -0
- package/vendor/dynamic-workflow/facade/world-read-caps.d.ts +37 -0
- package/vendor/dynamic-workflow/facade/world-read-caps.d.ts.map +1 -0
- package/vendor/dynamic-workflow/facade/world-read-caps.js +36 -0
- package/vendor/dynamic-workflow/index.d.ts +41 -0
- package/vendor/dynamic-workflow/index.d.ts.map +1 -0
- package/vendor/dynamic-workflow/index.js +51 -0
- package/vendor/dynamic-workflow/lowering/index.d.ts +2 -0
- package/vendor/dynamic-workflow/lowering/index.d.ts.map +1 -0
- package/vendor/dynamic-workflow/lowering/index.js +1 -0
- package/vendor/dynamic-workflow/lowering/lower-hole.d.ts +16 -0
- package/vendor/dynamic-workflow/lowering/lower-hole.d.ts.map +1 -0
- package/vendor/dynamic-workflow/lowering/lower-hole.js +63 -0
- package/vendor/dynamic-workflow/lowering/lower.d.ts +82 -0
- package/vendor/dynamic-workflow/lowering/lower.d.ts.map +1 -0
- package/vendor/dynamic-workflow/lowering/lower.js +333 -0
- package/vendor/dynamic-workflow/projections.d.ts +26 -0
- package/vendor/dynamic-workflow/projections.d.ts.map +1 -0
- package/vendor/dynamic-workflow/projections.js +23 -0
- package/vendor/dynamic-workflow/schema/actor-submit-profiles.d.ts +49 -0
- package/vendor/dynamic-workflow/schema/actor-submit-profiles.d.ts.map +1 -0
- package/vendor/dynamic-workflow/schema/actor-submit-profiles.js +69 -0
- package/vendor/dynamic-workflow/schema/emit.d.ts +55 -0
- package/vendor/dynamic-workflow/schema/emit.d.ts.map +1 -0
- package/vendor/dynamic-workflow/schema/emit.js +325 -0
- package/vendor/dynamic-workflow/schema/jsdoc.d.ts +10 -0
- package/vendor/dynamic-workflow/schema/jsdoc.d.ts.map +1 -0
- package/vendor/dynamic-workflow/schema/jsdoc.js +83 -0
- package/vendor/dynamic-workflow/schema/serialize.d.ts +8 -0
- package/vendor/dynamic-workflow/schema/serialize.d.ts.map +1 -0
- package/vendor/dynamic-workflow/schema/serialize.js +20 -0
- package/vendor/dynamic-workflow/schema/synthesize.d.ts +48 -0
- package/vendor/dynamic-workflow/schema/synthesize.d.ts.map +1 -0
- package/vendor/dynamic-workflow/schema/synthesize.js +138 -0
- package/vendor/dynamic-workflow/schema/types.d.ts +67 -0
- package/vendor/dynamic-workflow/schema/types.d.ts.map +1 -0
- package/vendor/dynamic-workflow/schema/types.js +18 -0
- package/vendor/dynamic-workflow/schema/validate.d.ts +15 -0
- package/vendor/dynamic-workflow/schema/validate.d.ts.map +1 -0
- package/vendor/dynamic-workflow/schema/validate.js +213 -0
- package/vendor/dynamic-workflow/testing/index.d.ts +6 -0
- package/vendor/dynamic-workflow/testing/index.d.ts.map +1 -0
- package/vendor/dynamic-workflow/testing/index.js +5 -0
- package/vendor/dynamic-workflow/testing/journal-contract-artifacts.d.ts +9 -0
- package/vendor/dynamic-workflow/testing/journal-contract-artifacts.d.ts.map +1 -0
- package/vendor/dynamic-workflow/testing/journal-contract-artifacts.js +195 -0
- package/vendor/dynamic-workflow/testing/journal-contract-events.d.ts +9 -0
- package/vendor/dynamic-workflow/testing/journal-contract-events.d.ts.map +1 -0
- package/vendor/dynamic-workflow/testing/journal-contract-events.js +163 -0
- package/vendor/dynamic-workflow/testing/journal-contract-helpers.d.ts +9 -0
- package/vendor/dynamic-workflow/testing/journal-contract-helpers.d.ts.map +1 -0
- package/vendor/dynamic-workflow/testing/journal-contract-helpers.js +12 -0
- package/vendor/dynamic-workflow/testing/journal-contract-isolation.d.ts +9 -0
- package/vendor/dynamic-workflow/testing/journal-contract-isolation.d.ts.map +1 -0
- package/vendor/dynamic-workflow/testing/journal-contract-isolation.js +46 -0
- package/vendor/dynamic-workflow/testing/journal-contract-nodes.d.ts +9 -0
- package/vendor/dynamic-workflow/testing/journal-contract-nodes.d.ts.map +1 -0
- package/vendor/dynamic-workflow/testing/journal-contract-nodes.js +234 -0
- package/vendor/dynamic-workflow/testing/journal-contract-reads.d.ts +11 -0
- package/vendor/dynamic-workflow/testing/journal-contract-reads.d.ts.map +1 -0
- package/vendor/dynamic-workflow/testing/journal-contract-reads.js +281 -0
- package/vendor/dynamic-workflow/testing/journal-contract-runs.d.ts +9 -0
- package/vendor/dynamic-workflow/testing/journal-contract-runs.d.ts.map +1 -0
- package/vendor/dynamic-workflow/testing/journal-contract-runs.js +396 -0
- package/vendor/dynamic-workflow/testing/journal-contract-script.d.ts +12 -0
- package/vendor/dynamic-workflow/testing/journal-contract-script.d.ts.map +1 -0
- package/vendor/dynamic-workflow/testing/journal-contract-script.js +82 -0
- package/vendor/dynamic-workflow/testing/journal-contract.d.ts +15 -0
- package/vendor/dynamic-workflow/testing/journal-contract.d.ts.map +1 -0
- package/vendor/dynamic-workflow/testing/journal-contract.js +31 -0
- package/vendor/dynamic-workflow-runtime/child-cell-streams.js +128 -0
- package/vendor/dynamic-workflow-runtime/child-entry-file.js +43 -0
- package/vendor/dynamic-workflow-runtime/child-source.js +299 -0
- package/vendor/dynamic-workflow-runtime/harness.js +302 -0
- package/vendor/dynamic-workflow-runtime/index.js +4 -0
- package/vendor/dynamic-workflow-runtime/protocol.js +2 -0
- package/vendor/mcode-host/dynamic-workflow-import.js +269 -0
- package/vendor/mcode-host/workflow-git-world-read.js +183 -0
- package/vendor/mcode-host/workflow-world-read.js +282 -0
|
@@ -0,0 +1,350 @@
|
|
|
1
|
+
import ts from "typescript";
|
|
2
|
+
import { FACADE_FILE_NAME } from "../facade/dts.js";
|
|
3
|
+
import { facadeContainerOf, isSiteProducing, SITE_MEMBER_NAMES } from "../facade/registry.js";
|
|
4
|
+
import { findWorkflowBody } from "./domain.js";
|
|
5
|
+
import { isFacadeDeclared, resolveSymbol } from "./sites.js";
|
|
6
|
+
/**
|
|
7
|
+
* The facade-siting diagnostic. Kept in its own module,
|
|
8
|
+
* a sibling of the site-table substrate: this is an
|
|
9
|
+
* analysis diagnostic, not part of the shared table, and it walks the body in a
|
|
10
|
+
* different shape (every reference / conversion, not just call sites).
|
|
11
|
+
*/
|
|
12
|
+
/**
|
|
13
|
+
* Package-local diagnostic code for the facade-siting rule. Not a TS diagnostic code
|
|
14
|
+
* (those come from the checker); this marks an analysis diagnostic produced by
|
|
15
|
+
* {@link collectFacadeMisuse}. Kept out of the TS code space to stay unambiguous.
|
|
16
|
+
*/
|
|
17
|
+
export const FACADE_SITING_CODE = 9001;
|
|
18
|
+
/** Depth cap for the structural facade-site walk; scripts nest shallowly, cyclic types converge. */
|
|
19
|
+
const FACADE_SITE_DEPTH = 4;
|
|
20
|
+
/**
|
|
21
|
+
* Assignment operators whose right-hand side flows a value into the left-hand slot's
|
|
22
|
+
* declared type: plain `=` and the logical compounds `||=`/`&&=`/`??=`. Arithmetic
|
|
23
|
+
* compounds (`+=`, …) coerce and cannot carry a facade handle into a facade-typed slot,
|
|
24
|
+
* so they are not conversion boundaries.
|
|
25
|
+
*/
|
|
26
|
+
const VALUE_ASSIGNMENT_OPS = new Set([
|
|
27
|
+
ts.SyntaxKind.EqualsToken,
|
|
28
|
+
ts.SyntaxKind.BarBarEqualsToken,
|
|
29
|
+
ts.SyntaxKind.AmpersandAmpersandEqualsToken,
|
|
30
|
+
ts.SyntaxKind.QuestionQuestionEqualsToken,
|
|
31
|
+
]);
|
|
32
|
+
/**
|
|
33
|
+
* The facade-siting diagnostic: facade callables are second-class — `agent`, `Agent.ask`,
|
|
34
|
+
* `files.glob`/`files.read`, `artifact.file`/`artifact.chart`, and `log` may appear only as the
|
|
35
|
+
* callee of a direct call. Any other reference (aliasing `const spawn = agent`, method
|
|
36
|
+
* extraction `const f = planner.ask`, `.bind`/`.call`/`.apply` receivers, passing a
|
|
37
|
+
* facade function as an argument) destroys site identity: journal keys, replay, and
|
|
38
|
+
* the GUI all key off static site ids, and a facade call reachable only through an
|
|
39
|
+
* escaped function value has no site. Widening cannot represent it and silently
|
|
40
|
+
* dropping it would be unsound, so it is rejected at compile time.
|
|
41
|
+
*
|
|
42
|
+
* Three passes over the workflow body:
|
|
43
|
+
*
|
|
44
|
+
* 1. Reference scan — every identifier / property-access whose checker-resolved
|
|
45
|
+
* symbol is a facade callable, in any position other than the callee of a direct
|
|
46
|
+
* call; PLUS every destructuring binding/assignment that extracts a facade
|
|
47
|
+
* callable off its containing object (see {@link flagExtractedMember}).
|
|
48
|
+
* 2. Defense in depth — any direct CallExpression whose callee resolves to a
|
|
49
|
+
* site-producing facade callable but that never registered as a site (catches
|
|
50
|
+
* escape forms the reference scan misses).
|
|
51
|
+
* 3. Retyping boundary — any conversion of a value that carries a site-producing
|
|
52
|
+
* facade member (`Agent.ask`, `files.glob`/`read`) to a type that does NOT (a
|
|
53
|
+
* structurally-compatible local interface, `any`, `unknown`). TypeScript resolves
|
|
54
|
+
* members by *declared type*, so `const d = planner as Askable; d.ask(...)` or
|
|
55
|
+
* `function run(a: Askable) { a.ask(...) }; run(planner)` makes `.ask` resolve to
|
|
56
|
+
* the local declaration — pass 1 sees a non-facade symbol, pass 2's resolved
|
|
57
|
+
* signature points at the local interface: no site, no diagnostic, and the real
|
|
58
|
+
* facade call runs unsited. Enforced at the conversion boundary
|
|
59
|
+
* (`as`/`satisfies`, argument→parameter, return, annotated binding) rather than by
|
|
60
|
+
* tracking value provenance through the cast (see {@link facadeSiteMember}).
|
|
61
|
+
*
|
|
62
|
+
* Destructuring extraction: `const { ask } = planner`, `const { read }
|
|
63
|
+
* = files`, renamed `{ ask: f }`, nested `{ p: { ask } }`, parameter `function f({ ask }:
|
|
64
|
+
* Agent)`, and assignment `({ ask } = planner)` are all method extraction — the destructured
|
|
65
|
+
* twin of the already-rejected `const f = planner.ask`. A shorthand binding identifier
|
|
66
|
+
* resolves to the freshly-declared LOCAL (not the facade method), so the identifier scan is
|
|
67
|
+
* blind; and routing the value through a script-locally-typed helper hides the eventual call
|
|
68
|
+
* from Pass 2's signature check too. Both holes close by flagging at the EXTRACTION site
|
|
69
|
+
* (see {@link scanRefs}): resolve the source property on the destructured value's type and
|
|
70
|
+
* reject a facade callable.
|
|
71
|
+
*/
|
|
72
|
+
export function collectFacadeMisuse(workflow, table) {
|
|
73
|
+
const { program, scriptFile, toScriptLoc } = workflow;
|
|
74
|
+
const checker = program.getTypeChecker();
|
|
75
|
+
const body = findWorkflowBody(scriptFile);
|
|
76
|
+
const diagnostics = [];
|
|
77
|
+
const flag = (at, name) => {
|
|
78
|
+
const loc = toScriptLoc(at.getStart(scriptFile));
|
|
79
|
+
diagnostics.push({
|
|
80
|
+
code: FACADE_SITING_CODE,
|
|
81
|
+
column: loc.column,
|
|
82
|
+
line: loc.line,
|
|
83
|
+
message: `facade function '${name}' may only be called directly; ` +
|
|
84
|
+
`taking a reference to it defeats site identity (journal and replay key off call sites)`,
|
|
85
|
+
});
|
|
86
|
+
};
|
|
87
|
+
// Resolve the source property a destructuring form pulls off its containing object
|
|
88
|
+
// (`{ ask } = planner` -> `ask` on Agent) and flag it when facade-callable. Flags at
|
|
89
|
+
// `nameNode`; a renamed form's property name is also seen by the identifier scan below,
|
|
90
|
+
// so both may flag the same spot — the trailing dedupe collapses that.
|
|
91
|
+
const flagExtractedMember = (nameNode, containerType) => {
|
|
92
|
+
if (!ts.isIdentifier(nameNode) && !ts.isStringLiteralLike(nameNode))
|
|
93
|
+
return;
|
|
94
|
+
const property = checker.getPropertyOfType(containerType, nameNode.text);
|
|
95
|
+
if (isFacadeCallable(property))
|
|
96
|
+
flag(nameNode, nameNode.text);
|
|
97
|
+
};
|
|
98
|
+
// Pass 1: reference scan.
|
|
99
|
+
const scanRefs = (node) => {
|
|
100
|
+
if (ts.isPropertyAccessExpression(node)) {
|
|
101
|
+
const symbol = resolveSymbol(node.name, checker);
|
|
102
|
+
if (isFacadeCallable(symbol) && !isDirectCallee(node))
|
|
103
|
+
flag(node.name, symbol.name);
|
|
104
|
+
}
|
|
105
|
+
else if (ts.isIdentifier(node) && !isPropertyAccessName(node)) {
|
|
106
|
+
const symbol = resolveSymbol(node, checker);
|
|
107
|
+
if (isFacadeCallable(symbol) && !isDirectCallee(node))
|
|
108
|
+
flag(node, symbol.name);
|
|
109
|
+
}
|
|
110
|
+
else if (ts.isBindingElement(node) && ts.isObjectBindingPattern(node.parent)) {
|
|
111
|
+
// Destructuring EXTRACTION off an object binding pattern (`const { ask } = planner`,
|
|
112
|
+
// renamed, nested, or parameter): the container is the binding pattern's type, and a
|
|
113
|
+
// renamed element carries the source property name, a shorthand its own bound name.
|
|
114
|
+
flagExtractedMember(node.propertyName ?? node.name, checker.getTypeAtLocation(node.parent));
|
|
115
|
+
}
|
|
116
|
+
else if (ts.isShorthandPropertyAssignment(node) && ts.isBinaryExpression(node.parent.parent)) {
|
|
117
|
+
// Destructuring ASSIGNMENT `({ ask } = planner)`: the object literal is the assignment
|
|
118
|
+
// target (its LHS), and the source property lives on the right-hand side's type.
|
|
119
|
+
const assign = node.parent.parent;
|
|
120
|
+
if (assign.left === node.parent && assign.operatorToken.kind === ts.SyntaxKind.EqualsToken) {
|
|
121
|
+
flagExtractedMember(node.name, checker.getTypeAtLocation(assign.right));
|
|
122
|
+
}
|
|
123
|
+
}
|
|
124
|
+
ts.forEachChild(node, scanRefs);
|
|
125
|
+
};
|
|
126
|
+
// Pass 2: defense in depth — a direct facade call the collector did not site.
|
|
127
|
+
// `report` sites belong in here for the same reason `agent` sites do: `report` is
|
|
128
|
+
// site-producing (registry), so a sited direct call must not be flagged, while a
|
|
129
|
+
// report call the collector somehow missed must be.
|
|
130
|
+
const sited = new Set([
|
|
131
|
+
...table.asks.map((site) => site.call),
|
|
132
|
+
...table.actors.map((site) => site.call),
|
|
133
|
+
...table.worldReads.map((site) => site.call),
|
|
134
|
+
...table.reports.map((site) => site.call),
|
|
135
|
+
// 产物站点与 report 同席:它们产生站点(registry),
|
|
136
|
+
// 所以已 site 的直接调用不得被误报,而收集漏掉的那一次必须被报出来。
|
|
137
|
+
...table.artifacts.map((site) => site.call),
|
|
138
|
+
...table.joins.map((site) => site.call),
|
|
139
|
+
// 留白同席:`hole` 产生站点(registry),已 site 的直接调用不得误报。
|
|
140
|
+
...table.holes.map((site) => site.call),
|
|
141
|
+
]);
|
|
142
|
+
const scanCalls = (node) => {
|
|
143
|
+
if (ts.isCallExpression(node) && !sited.has(node)) {
|
|
144
|
+
// Resolve through the CALL's signature, not the callee's symbol: a computed
|
|
145
|
+
// member access (`files["read"]`) has no callee symbol, but the resolved
|
|
146
|
+
// signature still points at the facade method declaration. The (container, member)
|
|
147
|
+
// pair — not the bare member name — decides whether the callee is site-producing:
|
|
148
|
+
// `git.log` is, the top-level `log()` is not, and they share a name. Keying on the
|
|
149
|
+
// name alone would flag every unsited `log("progress")` call as misuse.
|
|
150
|
+
const callee = facadeCallee(node, checker);
|
|
151
|
+
if (callee !== undefined && isSiteProducing(callee.container, callee.member)) {
|
|
152
|
+
flag(node.expression, callee.member);
|
|
153
|
+
}
|
|
154
|
+
}
|
|
155
|
+
ts.forEachChild(node, scanCalls);
|
|
156
|
+
};
|
|
157
|
+
// Pass 3: retyping boundary. A value that really is an `Agent`/`files` (its type
|
|
158
|
+
// carries a site-producing facade member) converted to a type that carries none
|
|
159
|
+
// launders the site. Anchored at the escaping value expression; the reported name is
|
|
160
|
+
// the member the disguised type exposes locally (what the author calls through), so
|
|
161
|
+
// the message reads as "'.ask' can no longer be a facade call here".
|
|
162
|
+
const flagRetype = (at, name) => {
|
|
163
|
+
const loc = toScriptLoc(at.getStart(scriptFile));
|
|
164
|
+
diagnostics.push({
|
|
165
|
+
code: FACADE_SITING_CODE,
|
|
166
|
+
column: loc.column,
|
|
167
|
+
line: loc.line,
|
|
168
|
+
message: `facade function '${name}' may only be called directly; retyping a facade value to a ` +
|
|
169
|
+
`structurally-compatible non-facade type escapes site identity ` +
|
|
170
|
+
`(the disguised '.${name}(...)' resolves to the local type and runs unsited)`,
|
|
171
|
+
});
|
|
172
|
+
};
|
|
173
|
+
const checkConversion = (valueExpr, destType) => {
|
|
174
|
+
if (destType === undefined)
|
|
175
|
+
return;
|
|
176
|
+
const laundered = facadeSiteMember(checker.getTypeAtLocation(valueExpr), checker);
|
|
177
|
+
if (laundered === undefined)
|
|
178
|
+
return;
|
|
179
|
+
if (facadeSiteMember(destType, checker) !== undefined)
|
|
180
|
+
return;
|
|
181
|
+
const viaDest = [...SITE_MEMBER_NAMES].find((name) => destType.getProperty(name) !== undefined);
|
|
182
|
+
flagRetype(valueExpr, viaDest ?? laundered);
|
|
183
|
+
};
|
|
184
|
+
const scanRetyping = (node) => {
|
|
185
|
+
if (ts.isAsExpression(node) || ts.isSatisfiesExpression(node)) {
|
|
186
|
+
checkConversion(node.expression, checker.getTypeFromTypeNode(node.type));
|
|
187
|
+
}
|
|
188
|
+
else if (ts.isCallExpression(node) || ts.isNewExpression(node)) {
|
|
189
|
+
for (const arg of node.arguments ?? [])
|
|
190
|
+
checkConversion(arg, checker.getContextualType(arg));
|
|
191
|
+
}
|
|
192
|
+
else if (ts.isReturnStatement(node) && node.expression !== undefined) {
|
|
193
|
+
checkConversion(node.expression, checker.getContextualType(node.expression));
|
|
194
|
+
}
|
|
195
|
+
else if (ts.isArrowFunction(node) && !ts.isBlock(node.body)) {
|
|
196
|
+
checkConversion(node.body, checker.getContextualType(node.body));
|
|
197
|
+
}
|
|
198
|
+
else if (ts.isVariableDeclaration(node) &&
|
|
199
|
+
node.type !== undefined &&
|
|
200
|
+
node.initializer !== undefined) {
|
|
201
|
+
checkConversion(node.initializer, checker.getTypeFromTypeNode(node.type));
|
|
202
|
+
}
|
|
203
|
+
else if (ts.isBinaryExpression(node) &&
|
|
204
|
+
VALUE_ASSIGNMENT_OPS.has(node.operatorToken.kind) &&
|
|
205
|
+
(ts.isIdentifier(node.left) ||
|
|
206
|
+
ts.isPropertyAccessExpression(node.left) ||
|
|
207
|
+
ts.isElementAccessExpression(node.left))) {
|
|
208
|
+
// Assignment into an already-typed slot (`d = planner` on `let d: Askable`,
|
|
209
|
+
// `slot.a = planner`, `arr[0] = planner`). Destructuring-pattern targets are
|
|
210
|
+
// ArrayLiteral/ObjectLiteral LHS — pass 1 handles extraction there, so they are
|
|
211
|
+
// excluded above. An evolving-any binding is narrowed to the real type at its use
|
|
212
|
+
// (the call stays sited), so it is not a laundering boundary; an explicit `: any`
|
|
213
|
+
// annotation is (the call runs unsited), so only the implicit case is skipped.
|
|
214
|
+
const destType = checker.getTypeAtLocation(node.left);
|
|
215
|
+
if (!isEvolvingAny(node.left, destType, checker))
|
|
216
|
+
checkConversion(node.right, destType);
|
|
217
|
+
}
|
|
218
|
+
ts.forEachChild(node, scanRetyping);
|
|
219
|
+
};
|
|
220
|
+
for (const statement of body.statements)
|
|
221
|
+
scanRefs(statement);
|
|
222
|
+
for (const statement of body.statements)
|
|
223
|
+
scanCalls(statement);
|
|
224
|
+
for (const statement of body.statements)
|
|
225
|
+
scanRetyping(statement);
|
|
226
|
+
// Dedupe: the passes can, in principle, name the same escape at the same spot.
|
|
227
|
+
const seen = new Set();
|
|
228
|
+
return diagnostics.filter((diagnostic) => {
|
|
229
|
+
const key = `${diagnostic.line}:${diagnostic.column}:${diagnostic.message}`;
|
|
230
|
+
if (seen.has(key))
|
|
231
|
+
return false;
|
|
232
|
+
seen.add(key);
|
|
233
|
+
return true;
|
|
234
|
+
});
|
|
235
|
+
}
|
|
236
|
+
/** True iff the symbol is a facade-declared function or method (a callable). */
|
|
237
|
+
function isFacadeCallable(symbol) {
|
|
238
|
+
return (isFacadeDeclared(symbol) &&
|
|
239
|
+
symbol !== undefined &&
|
|
240
|
+
(symbol.flags & (ts.SymbolFlags.Function | ts.SymbolFlags.Method)) !== 0);
|
|
241
|
+
}
|
|
242
|
+
/**
|
|
243
|
+
* The first site-producing facade member reachable in `type` (the world-read registry's
|
|
244
|
+
* members plus `ask`, as declared in the facade `.d.ts`), or undefined. Walks the type
|
|
245
|
+
* directly, then union / intersection constituents, type arguments (`Agent[]`,
|
|
246
|
+
* `Promise<Agent>`), and properties (a container holding a facade value), depth- and
|
|
247
|
+
* cycle-bounded.
|
|
248
|
+
*
|
|
249
|
+
* This is the "is this value really an `Agent` / the `files` object" test the retyping
|
|
250
|
+
* boundary keys off. It deliberately keys on the *site member*, not on any facade-
|
|
251
|
+
* declared symbol: an artifact result carries no site member — a `Node<T>` exposes only
|
|
252
|
+
* `then`, an awaited result is a primitive — so retyping ask/read RESULTS stays legal,
|
|
253
|
+
* while retyping the receiver that would resolve `.ask`/`.read` to a facade site is caught.
|
|
254
|
+
*
|
|
255
|
+
* **Bare member names are sound HERE, unlike in passes 1 and 2, and the next task relies on
|
|
256
|
+
* the difference.** Identity is not decided by the name: the name is looked up as a PROPERTY
|
|
257
|
+
* OF A TYPE and then run through `isFacadeDeclared`. Property resolution against a type is
|
|
258
|
+
* already declaration-based, so `SITE_MEMBER_NAMES` supplies candidate keys and the
|
|
259
|
+
* facade-declared check is the identity test. The top-level `log` is a function declaration,
|
|
260
|
+
* not a property of any facade type, so `git.log`'s arrival cannot make a `log` property
|
|
261
|
+
* resolve to it. The invariant this rests on: **no two facade containers declare the same
|
|
262
|
+
* member name** — a collision would keep the boolean answer correct but make the RETURNED
|
|
263
|
+
* name (which the diagnostic message quotes) ambiguous. `files.grep` and the `git.*` members
|
|
264
|
+
* keep that invariant; breaking it would mean threading the container through here too.
|
|
265
|
+
*/
|
|
266
|
+
function facadeSiteMember(type, checker, seen = new Set(), depth = 0) {
|
|
267
|
+
if (depth > FACADE_SITE_DEPTH || seen.has(type))
|
|
268
|
+
return undefined;
|
|
269
|
+
seen.add(type);
|
|
270
|
+
for (const name of SITE_MEMBER_NAMES) {
|
|
271
|
+
if (isFacadeDeclared(type.getProperty(name)))
|
|
272
|
+
return name;
|
|
273
|
+
}
|
|
274
|
+
if (type.isUnionOrIntersection()) {
|
|
275
|
+
for (const constituent of type.types) {
|
|
276
|
+
const found = facadeSiteMember(constituent, checker, seen, depth + 1);
|
|
277
|
+
if (found !== undefined)
|
|
278
|
+
return found;
|
|
279
|
+
}
|
|
280
|
+
}
|
|
281
|
+
for (const arg of typeArguments(type, checker)) {
|
|
282
|
+
const found = facadeSiteMember(arg, checker, seen, depth + 1);
|
|
283
|
+
if (found !== undefined)
|
|
284
|
+
return found;
|
|
285
|
+
}
|
|
286
|
+
for (const property of type.getProperties()) {
|
|
287
|
+
if (property.valueDeclaration === undefined)
|
|
288
|
+
continue;
|
|
289
|
+
const propType = checker.getTypeOfSymbolAtLocation(property, property.valueDeclaration);
|
|
290
|
+
const found = facadeSiteMember(propType, checker, seen, depth + 1);
|
|
291
|
+
if (found !== undefined)
|
|
292
|
+
return found;
|
|
293
|
+
}
|
|
294
|
+
return undefined;
|
|
295
|
+
}
|
|
296
|
+
/** Instantiated type arguments of an object reference (`Agent[]`, `Node<Agent>`); [] otherwise. */
|
|
297
|
+
function typeArguments(type, checker) {
|
|
298
|
+
if ((type.flags & ts.TypeFlags.Object) === 0)
|
|
299
|
+
return [];
|
|
300
|
+
if ((type.objectFlags & ts.ObjectFlags.Reference) === 0)
|
|
301
|
+
return [];
|
|
302
|
+
return checker.getTypeArguments(type);
|
|
303
|
+
}
|
|
304
|
+
/**
|
|
305
|
+
* True iff `left` is an evolving-any binding (`let x;` with no annotation, typed `any`).
|
|
306
|
+
* Such a binding narrows to the assigned type at its use, so a facade call through it
|
|
307
|
+
* stays sited — it is not a laundering boundary. An explicit `: any`/`: unknown`
|
|
308
|
+
* annotation is a different case (the call runs unsited) and is NOT skipped.
|
|
309
|
+
*/
|
|
310
|
+
function isEvolvingAny(left, leftType, checker) {
|
|
311
|
+
if ((leftType.flags & ts.TypeFlags.Any) === 0 || !ts.isIdentifier(left))
|
|
312
|
+
return false;
|
|
313
|
+
const declaration = checker.getSymbolAtLocation(left)?.valueDeclaration;
|
|
314
|
+
return (declaration !== undefined &&
|
|
315
|
+
ts.isVariableDeclaration(declaration) &&
|
|
316
|
+
declaration.type === undefined);
|
|
317
|
+
}
|
|
318
|
+
/**
|
|
319
|
+
* The facade callable a call resolves to, as a (declaring container, member) pair — or
|
|
320
|
+
* undefined if the call does not resolve into the facade `.d.ts`. Resolving through the
|
|
321
|
+
* signature — not the callee expression's symbol — is what lets the defense-in-depth pass
|
|
322
|
+
* see a computed member callee (`files["read"](x)`), whose callee has no symbol but whose
|
|
323
|
+
* resolved signature is still the facade method. The container comes from the same
|
|
324
|
+
* declaration (`files.read` → `"files"`; a top-level `agent()` → undefined), so the caller
|
|
325
|
+
* can ask the registry rather than matching a bare name.
|
|
326
|
+
*/
|
|
327
|
+
function facadeCallee(call, checker) {
|
|
328
|
+
const declaration = checker.getResolvedSignature(call)?.declaration;
|
|
329
|
+
if (declaration === undefined || declaration.getSourceFile().fileName !== FACADE_FILE_NAME) {
|
|
330
|
+
return undefined;
|
|
331
|
+
}
|
|
332
|
+
const name = declaration.name;
|
|
333
|
+
if (name === undefined || !ts.isIdentifier(name))
|
|
334
|
+
return undefined;
|
|
335
|
+
return { container: facadeContainerOf(declaration), member: name.text };
|
|
336
|
+
}
|
|
337
|
+
/** True iff `node` is the member name of a property access (`x.NAME`), not a value. */
|
|
338
|
+
function isPropertyAccessName(node) {
|
|
339
|
+
return ts.isPropertyAccessExpression(node.parent) && node.parent.name === node;
|
|
340
|
+
}
|
|
341
|
+
/**
|
|
342
|
+
* True iff `node` is the callee expression of a direct call (`f(...)`, `x.m(...)`).
|
|
343
|
+
* Distinct from `domain.isDirectCallee` (which asks whether an expression is a callable
|
|
344
|
+
* literal for exactness): here "direct" is the syntactic siting position — the one spot a
|
|
345
|
+
* facade callable is allowed to appear.
|
|
346
|
+
*/
|
|
347
|
+
function isDirectCallee(node) {
|
|
348
|
+
const parent = node.parent;
|
|
349
|
+
return ts.isCallExpression(parent) && parent.expression === node;
|
|
350
|
+
}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import ts from "typescript";
|
|
2
|
+
/**
|
|
3
|
+
* fan-out 的**字面量基数**:
|
|
4
|
+
* 被迭代的表达式是无展开元素的数组字面量,或一个只初始化一次、从未被写入的 `const`
|
|
5
|
+
* 绑定到这样的字面量时,基数 = 字面量长度;其余一律 `undefined`。
|
|
6
|
+
*
|
|
7
|
+
* 这是**铸造期**(interpret.ts)的工作——它要看 AST 与 checker,而投影不许再看代码。
|
|
8
|
+
* 原则是宁缺毋滥:任何不确定都给缺席,交接图随之画一张 `many` 卡,绝不猜一个数。
|
|
9
|
+
*/
|
|
10
|
+
export declare function literalCardinality(iterated: ts.Expression, checker: ts.TypeChecker): number | undefined;
|
|
11
|
+
//# sourceMappingURL=fanout-cardinality.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"fanout-cardinality.d.ts","sourceRoot":"","sources":["../../src/analysis/fanout-cardinality.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,YAAY,CAAC;AAE5B;;;;;;;GAOG;AACH,wBAAgB,kBAAkB,CAAC,QAAQ,EAAE,EAAE,CAAC,UAAU,EAAE,OAAO,EAAE,EAAE,CAAC,WAAW,GAAG,MAAM,GAAG,SAAS,CAiBvG"}
|
|
@@ -0,0 +1,121 @@
|
|
|
1
|
+
import ts from "typescript";
|
|
2
|
+
/**
|
|
3
|
+
* fan-out 的**字面量基数**:
|
|
4
|
+
* 被迭代的表达式是无展开元素的数组字面量,或一个只初始化一次、从未被写入的 `const`
|
|
5
|
+
* 绑定到这样的字面量时,基数 = 字面量长度;其余一律 `undefined`。
|
|
6
|
+
*
|
|
7
|
+
* 这是**铸造期**(interpret.ts)的工作——它要看 AST 与 checker,而投影不许再看代码。
|
|
8
|
+
* 原则是宁缺毋滥:任何不确定都给缺席,交接图随之画一张 `many` 卡,绝不猜一个数。
|
|
9
|
+
*/
|
|
10
|
+
export function literalCardinality(iterated, checker) {
|
|
11
|
+
const expr = unwrap(iterated);
|
|
12
|
+
if (ts.isArrayLiteralExpression(expr))
|
|
13
|
+
return spreadFreeLength(expr);
|
|
14
|
+
if (!ts.isIdentifier(expr))
|
|
15
|
+
return undefined;
|
|
16
|
+
const symbol = checker.getSymbolAtLocation(expr);
|
|
17
|
+
const decl = symbol?.valueDeclaration;
|
|
18
|
+
if (symbol === undefined || decl === undefined || !ts.isVariableDeclaration(decl))
|
|
19
|
+
return undefined;
|
|
20
|
+
if (!ts.isIdentifier(decl.name))
|
|
21
|
+
return undefined;
|
|
22
|
+
const list = decl.parent;
|
|
23
|
+
if (!ts.isVariableDeclarationList(list) || (list.flags & ts.NodeFlags.Const) === 0)
|
|
24
|
+
return undefined;
|
|
25
|
+
if (decl.initializer === undefined)
|
|
26
|
+
return undefined;
|
|
27
|
+
const init = unwrap(decl.initializer);
|
|
28
|
+
if (!ts.isArrayLiteralExpression(init))
|
|
29
|
+
return undefined;
|
|
30
|
+
const length = spreadFreeLength(init);
|
|
31
|
+
if (length === undefined)
|
|
32
|
+
return undefined;
|
|
33
|
+
return isEverWritten(symbol, decl.getSourceFile(), checker) ? undefined : length;
|
|
34
|
+
}
|
|
35
|
+
/** `(xs)`, `xs as const`, `xs!`, `xs satisfies T` 都是同一个数组。 */
|
|
36
|
+
function unwrap(expr) {
|
|
37
|
+
let current = expr;
|
|
38
|
+
for (;;) {
|
|
39
|
+
if (ts.isParenthesizedExpression(current))
|
|
40
|
+
current = current.expression;
|
|
41
|
+
else if (ts.isAsExpression(current) || ts.isSatisfiesExpression(current))
|
|
42
|
+
current = current.expression;
|
|
43
|
+
else if (ts.isNonNullExpression(current))
|
|
44
|
+
current = current.expression;
|
|
45
|
+
else if (ts.isTypeAssertionExpression(current))
|
|
46
|
+
current = current.expression;
|
|
47
|
+
else
|
|
48
|
+
return current;
|
|
49
|
+
}
|
|
50
|
+
}
|
|
51
|
+
function spreadFreeLength(literal) {
|
|
52
|
+
if (literal.elements.some((element) => ts.isSpreadElement(element) || ts.isOmittedExpression(element))) {
|
|
53
|
+
return undefined;
|
|
54
|
+
}
|
|
55
|
+
return literal.elements.length > 0 ? literal.elements.length : undefined;
|
|
56
|
+
}
|
|
57
|
+
/** 就地改变数组内容的方法:经它们调用过的绑定不再是字面量长度。 */
|
|
58
|
+
const MUTATORS = new Set(["push", "pop", "shift", "unshift", "splice", "sort", "reverse", "fill", "copyWithin", "length"]);
|
|
59
|
+
/**
|
|
60
|
+
* 该绑定是否被写过:`xs.push(…)` 之类的就地方法、`xs[i] = …` / `xs[i]++`、`xs.length = 0`,
|
|
61
|
+
* 以及(虽然 `const` 已禁止)对名字本身的赋值。别名(`const ys = xs; ys.push()`)与把数组
|
|
62
|
+
* 传进函数不在检查范围——只看这三类写;它们之外的形状本来就会给出缺席以外的答案。
|
|
63
|
+
*/
|
|
64
|
+
function isEverWritten(symbol, file, checker) {
|
|
65
|
+
let written = false;
|
|
66
|
+
const visit = (node) => {
|
|
67
|
+
if (written)
|
|
68
|
+
return;
|
|
69
|
+
if (ts.isIdentifier(node) && node.parent !== undefined && checker.getSymbolAtLocation(node) === symbol) {
|
|
70
|
+
if (isWriteReference(node))
|
|
71
|
+
written = true;
|
|
72
|
+
}
|
|
73
|
+
ts.forEachChild(node, visit);
|
|
74
|
+
};
|
|
75
|
+
visit(file);
|
|
76
|
+
return written;
|
|
77
|
+
}
|
|
78
|
+
function isWriteReference(id) {
|
|
79
|
+
const parent = id.parent;
|
|
80
|
+
// 声明处本身不是写。
|
|
81
|
+
if (ts.isVariableDeclaration(parent) && parent.name === id)
|
|
82
|
+
return false;
|
|
83
|
+
// xs.push(...) / xs.length = 0
|
|
84
|
+
if (ts.isPropertyAccessExpression(parent) && parent.expression === id) {
|
|
85
|
+
const name = parent.name.text;
|
|
86
|
+
if (!MUTATORS.has(name))
|
|
87
|
+
return false;
|
|
88
|
+
if (name === "length")
|
|
89
|
+
return isAssignmentTarget(parent);
|
|
90
|
+
return ts.isCallExpression(parent.parent) && parent.parent.expression === parent;
|
|
91
|
+
}
|
|
92
|
+
// xs[i] = ... / xs[i]++ / delete xs[i]
|
|
93
|
+
if (ts.isElementAccessExpression(parent) && parent.expression === id)
|
|
94
|
+
return isAssignmentTarget(parent);
|
|
95
|
+
// xs = ... (const 下类型错误,但仍算写)
|
|
96
|
+
return isAssignmentTarget(id);
|
|
97
|
+
}
|
|
98
|
+
function isAssignmentTarget(node) {
|
|
99
|
+
const parent = node.parent;
|
|
100
|
+
if (ts.isBinaryExpression(parent) && parent.left === node) {
|
|
101
|
+
const op = parent.operatorToken.kind;
|
|
102
|
+
return op >= ts.SyntaxKind.FirstAssignment && op <= ts.SyntaxKind.LastAssignment;
|
|
103
|
+
}
|
|
104
|
+
if (ts.isPrefixUnaryExpression(parent) || ts.isPostfixUnaryExpression(parent)) {
|
|
105
|
+
return parent.operator === ts.SyntaxKind.PlusPlusToken || parent.operator === ts.SyntaxKind.MinusMinusToken;
|
|
106
|
+
}
|
|
107
|
+
if (ts.isDeleteExpression(parent))
|
|
108
|
+
return true;
|
|
109
|
+
// 解构赋值目标:[xs[0]] = ... / ({ a: xs[0] } = ...)
|
|
110
|
+
if (ts.isArrayLiteralExpression(parent) || ts.isPropertyAssignment(parent) || ts.isShorthandPropertyAssignment(parent)) {
|
|
111
|
+
let up = parent;
|
|
112
|
+
while (ts.isArrayLiteralExpression(up) || ts.isObjectLiteralExpression(up) || ts.isPropertyAssignment(up) || ts.isShorthandPropertyAssignment(up) || ts.isSpreadElement(up)) {
|
|
113
|
+
up = up.parent;
|
|
114
|
+
}
|
|
115
|
+
return ts.isBinaryExpression(up) && up.operatorToken.kind === ts.SyntaxKind.EqualsToken && up.left !== undefined && containsNode(up.left, node);
|
|
116
|
+
}
|
|
117
|
+
return false;
|
|
118
|
+
}
|
|
119
|
+
function containsNode(root, target) {
|
|
120
|
+
return target.pos >= root.pos && target.end <= root.end;
|
|
121
|
+
}
|
|
@@ -0,0 +1,113 @@
|
|
|
1
|
+
import type { ScriptLoc } from "../compiler/compile.js";
|
|
2
|
+
import type { AnalysisCore } from "./core.js";
|
|
3
|
+
/**
|
|
4
|
+
* The control-flow projection: "where can
|
|
5
|
+
* execution go next", as opposed to the causality graph's "what must precede what".
|
|
6
|
+
*
|
|
7
|
+
* Input is the core's trace read as a STRUCTURED CONTROL TREE (flow-tree.ts): regions are
|
|
8
|
+
* the inner nodes, events the leaves in pre-order, and each leaf's `regions` chain names
|
|
9
|
+
* its ancestors. The walk already resolved everything that needed the AST — arm grouping (`choice`), helper
|
|
10
|
+
* boundaries (`call`), try parts, and every `jump`'s target region — so this module is a
|
|
11
|
+
* pure function of the core and must not import `typescript`.
|
|
12
|
+
*
|
|
13
|
+
* Nodes are OCCURRENCES (each `issue` leaf, each `mark` leaf), not sites: a helper called
|
|
14
|
+
* twice contributes two nodes for one step id. The phase quotient (`phaseEdges`) folds
|
|
15
|
+
* them back by phase. Neither level is transitively reduced — a CFG never is.
|
|
16
|
+
*
|
|
17
|
+
* The graph is CONCURRENT: a `strand` region (an asynchronous activation the walk inlined)
|
|
18
|
+
* is entered by a `fork` and left by a `join` at the barrier that awaits its promise, not
|
|
19
|
+
* at its spawn point. Its exits wait in the strand park (flow-strands.ts) in between, and a
|
|
20
|
+
* `mark` reached while strands are parked records their phases as `alongside` — a node
|
|
21
|
+
* fact, because "an earlier phase is still running here" is not a transfer of control and
|
|
22
|
+
* cannot be read off the edges once they fold.
|
|
23
|
+
*/
|
|
24
|
+
export type FlowNodeKind = "issue" | "mark";
|
|
25
|
+
export interface FlowNode {
|
|
26
|
+
/** `${step}@${k}` — the k-th issue of that step; `${phase}@${k}` for a mark. */
|
|
27
|
+
id: string;
|
|
28
|
+
kind: FlowNodeKind;
|
|
29
|
+
/** issue: the step's site id. */
|
|
30
|
+
site?: string;
|
|
31
|
+
/** The phase current at this leaf (a mark's is the phase it switched TO). */
|
|
32
|
+
phase: string;
|
|
33
|
+
/**
|
|
34
|
+
* mark only: the phases whose strands are still running when this marker is entered —
|
|
35
|
+
* every strand parked here, minus this node's own phase and minus any strand the marker
|
|
36
|
+
* sits inside. In the trace's phase-table order, absent when empty. Flow-insensitive
|
|
37
|
+
* across choice arms, like the walk's `issued` set: over-claiming "may run alongside" is
|
|
38
|
+
* the licensed direction.
|
|
39
|
+
*/
|
|
40
|
+
alongside?: string[];
|
|
41
|
+
/** Inside a never-called body the sweep placed: runs at an unknown point, if at all. */
|
|
42
|
+
detached?: true;
|
|
43
|
+
}
|
|
44
|
+
export type FlowEdgeKind = "next" | "branch" | "loop" | "exit" | "fork" | "join" | "jump" | "throw" | "may-throw";
|
|
45
|
+
export type FlowVia = "continue" | "break" | "return" | "recur";
|
|
46
|
+
export interface FlowEdge {
|
|
47
|
+
from: string;
|
|
48
|
+
to: string;
|
|
49
|
+
kind: FlowEdgeKind;
|
|
50
|
+
/** The jump statement kind behind a `loop` / `exit` / `jump` / `join` edge, when any. */
|
|
51
|
+
via?: FlowVia;
|
|
52
|
+
}
|
|
53
|
+
export interface FlowPhase {
|
|
54
|
+
id: string;
|
|
55
|
+
/** Absent for {@link UNPHASED_ID}. */
|
|
56
|
+
name?: string;
|
|
57
|
+
/** The first marker that minted the phase; absent for {@link UNPHASED_ID}. */
|
|
58
|
+
loc?: ScriptLoc;
|
|
59
|
+
/**
|
|
60
|
+
* Phases whose strands were still running when this one was entered: the union of
|
|
61
|
+
* {@link FlowNode.alongside} over the phase's mark nodes, in phase-table order, absent
|
|
62
|
+
* when empty. All-or-nothing with the rest of the phase vocabulary.
|
|
63
|
+
*/
|
|
64
|
+
alongside?: string[];
|
|
65
|
+
/** The filled hole whose body wrote this phase (a hole's own phase names the hole enclosing it). */
|
|
66
|
+
fill?: string;
|
|
67
|
+
}
|
|
68
|
+
/**
|
|
69
|
+
* An OPEN hole as the display lists it (docs/dynamic-workflow/presentation.md, `holes`): the
|
|
70
|
+
* station the rail draws dashed ahead of the run. `phase` is where the hole STANDS — the
|
|
71
|
+
* phase of its issue node, the hole's own memberless phase being `siteId` itself.
|
|
72
|
+
*/
|
|
73
|
+
export interface FlowHole {
|
|
74
|
+
siteId: string;
|
|
75
|
+
name: string;
|
|
76
|
+
/** The author's spelling of the type argument. */
|
|
77
|
+
type: string;
|
|
78
|
+
phase?: string;
|
|
79
|
+
/** The tail form `return await hole<T>(...)`: the script's end is open. */
|
|
80
|
+
tail?: true;
|
|
81
|
+
}
|
|
82
|
+
/** Terminal node ids. `sink` is the causality graph's sink: the script completed normally. */
|
|
83
|
+
export declare const FLOW_ENTRY = "entry";
|
|
84
|
+
export declare const FLOW_SINK = "sink";
|
|
85
|
+
export declare const FLOW_ABORT = "abort";
|
|
86
|
+
export interface ControlFlowGraph {
|
|
87
|
+
/** Leaf-stream order; detached nodes last (the sweep runs after the main walk). */
|
|
88
|
+
nodes: FlowNode[];
|
|
89
|
+
/** Canonical order: by from-node, to-node, kind, via; `entry` first, terminals last. */
|
|
90
|
+
edges: FlowEdge[];
|
|
91
|
+
/**
|
|
92
|
+
* The phase quotient, present iff the script declares a phase (all-or-nothing, exactly
|
|
93
|
+
* like the causality graph's `phaseEdges`). Same-phase edges dissolve except `loop`
|
|
94
|
+
* back edges, which stay as self-loops.
|
|
95
|
+
*/
|
|
96
|
+
phaseEdges?: FlowEdge[];
|
|
97
|
+
/** Phases that appear on some node, in first-reach order, {@link UNPHASED_ID} first. */
|
|
98
|
+
phases?: FlowPhase[];
|
|
99
|
+
/** The open holes in source order; present iff the script has one (see {@link FlowHole}). */
|
|
100
|
+
holes?: FlowHole[];
|
|
101
|
+
}
|
|
102
|
+
/**
|
|
103
|
+
* A dangling exit: the edge it will make once it learns where control goes next. Exported
|
|
104
|
+
* for flow-strands.ts only — a strand's exits leave this module to wait for their join —
|
|
105
|
+
* and deliberately not re-exported from the package barrels.
|
|
106
|
+
*/
|
|
107
|
+
export interface Src {
|
|
108
|
+
from: string;
|
|
109
|
+
kind: FlowEdgeKind;
|
|
110
|
+
via?: FlowVia;
|
|
111
|
+
}
|
|
112
|
+
export declare function projectControlFlow(core: AnalysisCore): ControlFlowGraph;
|
|
113
|
+
//# sourceMappingURL=flow-graph.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"flow-graph.d.ts","sourceRoot":"","sources":["../../src/analysis/flow-graph.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,wBAAwB,CAAC;AAExD,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,WAAW,CAAC;AAK9C;;;;;;;;;;;;;;;;;;;;GAoBG;AAEH,MAAM,MAAM,YAAY,GAAG,OAAO,GAAG,MAAM,CAAC;AAE5C,MAAM,WAAW,QAAQ;IACvB,gFAAgF;IAChF,EAAE,EAAE,MAAM,CAAC;IACX,IAAI,EAAE,YAAY,CAAC;IACnB,iCAAiC;IACjC,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,6EAA6E;IAC7E,KAAK,EAAE,MAAM,CAAC;IACd;;;;;;OAMG;IACH,SAAS,CAAC,EAAE,MAAM,EAAE,CAAC;IACrB,wFAAwF;IACxF,QAAQ,CAAC,EAAE,IAAI,CAAC;CACjB;AAED,MAAM,MAAM,YAAY,GACpB,MAAM,GACN,QAAQ,GACR,MAAM,GACN,MAAM,GACN,MAAM,GACN,MAAM,GACN,MAAM,GACN,OAAO,GACP,WAAW,CAAC;AAEhB,MAAM,MAAM,OAAO,GAAG,UAAU,GAAG,OAAO,GAAG,QAAQ,GAAG,OAAO,CAAC;AAEhE,MAAM,WAAW,QAAQ;IACvB,IAAI,EAAE,MAAM,CAAC;IACb,EAAE,EAAE,MAAM,CAAC;IACX,IAAI,EAAE,YAAY,CAAC;IACnB,yFAAyF;IACzF,GAAG,CAAC,EAAE,OAAO,CAAC;CACf;AAED,MAAM,WAAW,SAAS;IACxB,EAAE,EAAE,MAAM,CAAC;IACX,sCAAsC;IACtC,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,8EAA8E;IAC9E,GAAG,CAAC,EAAE,SAAS,CAAC;IAChB;;;;OAIG;IACH,SAAS,CAAC,EAAE,MAAM,EAAE,CAAC;IACrB,oGAAoG;IACpG,IAAI,CAAC,EAAE,MAAM,CAAC;CACf;AAED;;;;GAIG;AACH,MAAM,WAAW,QAAQ;IACvB,MAAM,EAAE,MAAM,CAAC;IACf,IAAI,EAAE,MAAM,CAAC;IACb,kDAAkD;IAClD,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,2EAA2E;IAC3E,IAAI,CAAC,EAAE,IAAI,CAAC;CACb;AAED,8FAA8F;AAC9F,eAAO,MAAM,UAAU,UAAU,CAAC;AAClC,eAAO,MAAM,SAAS,SAAS,CAAC;AAChC,eAAO,MAAM,UAAU,UAAU,CAAC;AAElC,MAAM,WAAW,gBAAgB;IAC/B,mFAAmF;IACnF,KAAK,EAAE,QAAQ,EAAE,CAAC;IAClB,wFAAwF;IACxF,KAAK,EAAE,QAAQ,EAAE,CAAC;IAClB;;;;OAIG;IACH,UAAU,CAAC,EAAE,QAAQ,EAAE,CAAC;IACxB,wFAAwF;IACxF,MAAM,CAAC,EAAE,SAAS,EAAE,CAAC;IACrB,6FAA6F;IAC7F,KAAK,CAAC,EAAE,QAAQ,EAAE,CAAC;CACpB;AAID;;;;GAIG;AACH,MAAM,WAAW,GAAG;IAClB,IAAI,EAAE,MAAM,CAAC;IACb,IAAI,EAAE,YAAY,CAAC;IACnB,GAAG,CAAC,EAAE,OAAO,CAAC;CACf;AAkED,wBAAgB,kBAAkB,CAAC,IAAI,EAAE,YAAY,GAAG,gBAAgB,CA6UvE"}
|