@intentius/tsad-conformance 1.4.0
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 +59 -0
- package/dist/adapter.d.ts +65 -0
- package/dist/adapter.d.ts.map +1 -0
- package/dist/adapter.js +2 -0
- package/dist/adapter.js.map +1 -0
- package/dist/bundled.d.ts +5 -0
- package/dist/bundled.d.ts.map +1 -0
- package/dist/bundled.js +28 -0
- package/dist/bundled.js.map +1 -0
- package/dist/fixture.d.ts +49 -0
- package/dist/fixture.d.ts.map +1 -0
- package/dist/fixture.js +95 -0
- package/dist/fixture.js.map +1 -0
- package/dist/host.d.ts +33 -0
- package/dist/host.d.ts.map +1 -0
- package/dist/host.js +79 -0
- package/dist/host.js.map +1 -0
- package/dist/index.d.ts +7 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +7 -0
- package/dist/index.js.map +1 -0
- package/dist/rules.d.ts +46 -0
- package/dist/rules.d.ts.map +1 -0
- package/dist/rules.js +135 -0
- package/dist/rules.js.map +1 -0
- package/dist/runner.d.ts +26 -0
- package/dist/runner.d.ts.map +1 -0
- package/dist/runner.js +152 -0
- package/dist/runner.js.map +1 -0
- package/fixtures/F-CallLeak/a-call-returns-a-live-object/expect.json +8 -0
- package/fixtures/F-CallLeak/a-call-returns-a-live-object/project/caller.ts +5 -0
- package/fixtures/F-CallLeak/a-call-returns-a-live-object/project/leaky.ts +7 -0
- package/fixtures/F-CallLeak/a-call-returns-a-live-object/project/pure.ts +5 -0
- package/fixtures/F-Cycle/mutual-imports/expect.json +6 -0
- package/fixtures/F-Cycle/mutual-imports/project/a.ts +3 -0
- package/fixtures/F-Cycle/mutual-imports/project/b.ts +3 -0
- package/fixtures/F-Depth/exhaustion-is-a-fallback/expect.json +19 -0
- package/fixtures/F-Depth/exhaustion-is-a-fallback/project/deep.ts +3 -0
- package/fixtures/F-Depth/exhaustion-is-a-fallback/project/rec.ts +3 -0
- package/fixtures/F-Div-Depth/new-inside-function-body/expect.json +21 -0
- package/fixtures/F-Div-Depth/new-inside-function-body/project/app.ts +3 -0
- package/fixtures/F-Div-Depth/new-inside-function-body/project/fn.ts +3 -0
- package/fixtures/F-Div-Eager/referenced-not-called/expect.json +8 -0
- package/fixtures/F-Div-Eager/referenced-not-called/project/app.ts +3 -0
- package/fixtures/F-Div-NsNew/namespace-callee/expect.json +18 -0
- package/fixtures/F-Div-NsNew/namespace-callee/input.ts +3 -0
- package/fixtures/F-Div-Provenance/helper-name-from-project-import/expect.json +20 -0
- package/fixtures/F-Div-Provenance/helper-name-from-project-import/project/app.ts +3 -0
- package/fixtures/F-Div-Provenance/helper-name-from-project-import/project/local.ts +3 -0
- package/fixtures/F-Div-SameFileNew/no-module-graph/expect.json +8 -0
- package/fixtures/F-Div-SameFileNew/no-module-graph/input.ts +5 -0
- package/fixtures/F-Div-Tag/unregistered-tag/expect.json +15 -0
- package/fixtures/F-Div-Tag/unregistered-tag/input.ts +1 -0
- package/fixtures/F-Eval-Array/spread-string-rejected/expect.json +14 -0
- package/fixtures/F-Eval-Array/spread-string-rejected/input.ts +1 -0
- package/fixtures/F-Eval-Binary/division-and-float/expect.json +19 -0
- package/fixtures/F-Eval-Binary/division-and-float/input.ts +1 -0
- package/fixtures/F-Eval-Binary/logical-return-operand/expect.json +20 -0
- package/fixtures/F-Eval-Binary/logical-return-operand/input.ts +1 -0
- package/fixtures/F-Eval-Binary/plus-dispatch/expect.json +19 -0
- package/fixtures/F-Eval-Binary/plus-dispatch/input.ts +1 -0
- package/fixtures/F-Eval-Binary/relational-on-strings/expect.json +18 -0
- package/fixtures/F-Eval-Binary/relational-on-strings/input.ts +1 -0
- package/fixtures/F-Eval-CallEager/evaluated-at-fold-time/expect.json +8 -0
- package/fixtures/F-Eval-CallEager/evaluated-at-fold-time/project/app.ts +3 -0
- package/fixtures/F-Eval-CallEager/not-a-function/expect.json +22 -0
- package/fixtures/F-Eval-CallEager/not-a-function/project/app.ts +3 -0
- package/fixtures/F-Eval-CallEager/not-a-function/project/local.ts +1 -0
- package/fixtures/F-Eval-CallHelper/helper-folds/expect.json +8 -0
- package/fixtures/F-Eval-CallHelper/helper-folds/project/app.ts +3 -0
- package/fixtures/F-Eval-CallHelper/inside-function-body/expect.json +22 -0
- package/fixtures/F-Eval-CallHelper/inside-function-body/project/app.ts +3 -0
- package/fixtures/F-Eval-CallHelper/inside-function-body/project/fn.ts +5 -0
- package/fixtures/F-Eval-CallIntrinsic/call-form-folds/expect.json +8 -0
- package/fixtures/F-Eval-CallIntrinsic/call-form-folds/project/app.ts +3 -0
- package/fixtures/F-Eval-CallIntrinsic/inside-function-body/expect.json +22 -0
- package/fixtures/F-Eval-CallIntrinsic/inside-function-body/project/app.ts +3 -0
- package/fixtures/F-Eval-CallIntrinsic/inside-function-body/project/fn.ts +5 -0
- package/fixtures/F-Eval-CallLocal/local-function-folds/expect.json +7 -0
- package/fixtures/F-Eval-CallLocal/local-function-folds/project/app.ts +3 -0
- package/fixtures/F-Eval-CallLocal/local-function-folds/project/pure.ts +3 -0
- package/fixtures/F-Eval-CallLocal/recursion-folds/expect.json +17 -0
- package/fixtures/F-Eval-CallLocal/recursion-folds/project/rec.ts +3 -0
- package/fixtures/F-Eval-CallLocal/recursion-folds/project/shallow.ts +3 -0
- package/fixtures/F-Eval-CallLocal/spread-argument-rejected/expect.json +20 -0
- package/fixtures/F-Eval-CallLocal/spread-argument-rejected/project/app.ts +5 -0
- package/fixtures/F-Eval-CallLocal/spread-argument-rejected/project/pure.ts +3 -0
- package/fixtures/F-Eval-CallMethod/method-missing/expect.json +17 -0
- package/fixtures/F-Eval-CallMethod/method-missing/input.ts +1 -0
- package/fixtures/F-Eval-CallMethod/null-receiver-dot/expect.json +13 -0
- package/fixtures/F-Eval-CallMethod/null-receiver-dot/input.ts +2 -0
- package/fixtures/F-Eval-CallMethod/null-receiver-optional/expect.json +2 -0
- package/fixtures/F-Eval-CallMethod/null-receiver-optional/input.ts +2 -0
- package/fixtures/F-Eval-CallMethod/real-receiver/expect.json +2 -0
- package/fixtures/F-Eval-CallMethod/real-receiver/input.ts +1 -0
- package/fixtures/F-Eval-Template/number-formatting/expect.json +11 -0
- package/fixtures/F-Eval-Template/number-formatting/input.ts +1 -0
- package/fixtures/F-Eval-Template/tostring-of-non-numbers/expect.json +10 -0
- package/fixtures/F-Eval-Template/tostring-of-non-numbers/input.ts +1 -0
- package/fixtures/F-Eval-Unary/coercion/expect.json +19 -0
- package/fixtures/F-Eval-Unary/coercion/input.ts +1 -0
- package/fixtures/F-Eval-Undefined/bare-undefined/expect.json +2 -0
- package/fixtures/F-Eval-Undefined/bare-undefined/input.ts +1 -0
- package/fixtures/F-Exc-Registry/call-form-without-registry/expect.json +15 -0
- package/fixtures/F-Exc-Registry/call-form-without-registry/input.ts +1 -0
- package/fixtures/F-Host-Closed-vs-Open/package-call-is-closed/expect.json +9 -0
- package/fixtures/F-Host-Closed-vs-Open/package-call-is-closed/project/closed.ts +3 -0
- package/fixtures/F-Host-Closed-vs-Open/package-call-is-closed/project/open.ts +3 -0
- package/fixtures/F-Host-Closed-vs-Open/package-call-is-closed/project/pure.ts +3 -0
- package/fixtures/F-Host-DataExports/plain-data-export/expect.json +8 -0
- package/fixtures/F-Host-DataExports/plain-data-export/project/app.ts +3 -0
- package/fixtures/F-Host-Registry/tag-called-as-function/expect.json +8 -0
- package/fixtures/F-Host-Registry/tag-called-as-function/project/app.ts +3 -0
- package/fixtures/F-Host-Trust/unowned-package/expect.json +6 -0
- package/fixtures/F-Host-Trust/unowned-package/project/app.ts +3 -0
- package/fixtures/F-Namespace/synthetic-namespace-object/expect.json +7 -0
- package/fixtures/F-Namespace/synthetic-namespace-object/project/use.ts +3 -0
- package/fixtures/F-Namespace/synthetic-namespace-object/project/values.ts +2 -0
- package/fixtures/F-NoExports/nothing-to-produce/expect.json +7 -0
- package/fixtures/F-NoExports/nothing-to-produce/project/defaulted.ts +1 -0
- package/fixtures/F-NoExports/nothing-to-produce/project/empty.ts +3 -0
- package/fixtures/F-Prebuild/same-file-construction-shared/expect.json +19 -0
- package/fixtures/F-Prebuild/same-file-construction-shared/project/shared.ts +6 -0
- package/fixtures/F-Profile-DataHost/plain-data-across-files/expect.json +39 -0
- package/fixtures/F-Profile-DataHost/plain-data-across-files/project/defaults.ts +5 -0
- package/fixtures/F-Profile-DataHost/plain-data-across-files/project/service.ts +10 -0
- package/fixtures/F-Seed/seeded-by-its-own-body/expect.json +8 -0
- package/fixtures/F-Seed/seeded-by-its-own-body/project/app.ts +8 -0
- package/fixtures/F-Seed/seeded-by-its-own-body/project/lone.ts +1 -0
- package/fixtures/F-Succ/backward-along-captures/expect.json +26 -0
- package/fixtures/F-Succ/backward-along-captures/project/breaker.ts +10 -0
- package/fixtures/F-Succ/backward-along-captures/project/shared.ts +1 -0
- package/fixtures/F-Succ/backward-along-captures/project/sibling.ts +3 -0
- package/fixtures/F-Succ/forward-into-imports/expect.json +8 -0
- package/fixtures/F-Succ/forward-into-imports/project/app.ts +10 -0
- package/fixtures/F-Succ/forward-into-imports/project/config.ts +1 -0
- package/fixtures/F-Taint/independent-file-still-folds/expect.json +9 -0
- package/fixtures/F-Taint/independent-file-still-folds/project/alone.ts +1 -0
- package/fixtures/F-Taint/independent-file-still-folds/project/app.ts +8 -0
- package/fixtures/F-Total/one-bad-declarator-fails-the-file/expect.json +7 -0
- package/fixtures/F-Total/one-bad-declarator-fails-the-file/project/mixed.ts +3 -0
- package/fixtures/F-Val-Arity/props-attributes-and-spread/expect.json +14 -0
- package/fixtures/F-Val-Arity/props-attributes-and-spread/project/arities.ts +5 -0
- package/fixtures/F-Val-Callable/host-function-as-value/expect.json +16 -0
- package/fixtures/F-Val-Callable/host-function-as-value/project/app.ts +3 -0
- package/fixtures/F-Val-Fate/revive-every-envelope/expect.json +15 -0
- package/fixtures/F-Val-Fate/revive-every-envelope/project/entities.ts +6 -0
- package/fixtures/F-Val-Live/plain-data-is-not-live/expect.json +9 -0
- package/fixtures/F-Val-Live/plain-data-is-not-live/project/breaker.ts +10 -0
- package/fixtures/F-Val-Live/plain-data-is-not-live/project/quiet.ts +3 -0
- package/fixtures/F-Val-Live/plain-data-is-not-live/project/source.ts +5 -0
- package/fixtures/F-Val-Position/attrref-in-host-arguments/expect.json +8 -0
- package/fixtures/F-Val-Position/attrref-in-host-arguments/project/rejected.ts +4 -0
- package/fixtures/F-Val-Undefined/array-element-undefined/expect.json +15 -0
- package/fixtures/F-Val-Undefined/array-element-undefined/input.ts +1 -0
- package/fixtures/F-Val-Undefined/conditional-yields-undefined/expect.json +13 -0
- package/fixtures/F-Val-Undefined/conditional-yields-undefined/input.ts +2 -0
- package/fixtures/F-Val-Undefined/optional-chain-yields-undefined-property/expect.json +13 -0
- package/fixtures/F-Val-Undefined/optional-chain-yields-undefined-property/input.ts +2 -0
- package/fixtures/F-Val-Undefined/property-literal-undefined/expect.json +16 -0
- package/fixtures/F-Val-Undefined/property-literal-undefined/input.ts +1 -0
- package/fixtures/F-Val-Undefined/spread-carries-undefined/expect.json +14 -0
- package/fixtures/F-Val-Undefined/spread-carries-undefined/input.ts +2 -0
- package/fixtures/S-Array/spread/expect.json +1 -0
- package/fixtures/S-Array/spread/input.ts +1 -0
- package/fixtures/S-Binary/arithmetic-and-concat/expect.json +1 -0
- package/fixtures/S-Binary/arithmetic-and-concat/input.ts +1 -0
- package/fixtures/S-Binary/lazy-untaken-unfoldable/expect.json +1 -0
- package/fixtures/S-Binary/lazy-untaken-unfoldable/input.ts +1 -0
- package/fixtures/S-Binary/nullish-coalesce/expect.json +1 -0
- package/fixtures/S-Binary/nullish-coalesce/input.ts +1 -0
- package/fixtures/S-CallLocal/imported-callee-is-shape-valid/expect.json +10 -0
- package/fixtures/S-CallLocal/imported-callee-is-shape-valid/input.ts +3 -0
- package/fixtures/S-Conditional/taken-branch-only/expect.json +1 -0
- package/fixtures/S-Conditional/taken-branch-only/input.ts +1 -0
- package/fixtures/S-ExportDefault/imported-by-sibling/expect.json +30 -0
- package/fixtures/S-ExportDefault/imported-by-sibling/project/app.ts +3 -0
- package/fixtures/S-ExportDefault/imported-by-sibling/project/policy.ts +1 -0
- package/fixtures/S-ExportDefault/plain-object/expect.json +21 -0
- package/fixtures/S-ExportDefault/plain-object/input.ts +1 -0
- package/fixtures/S-Ident/const-chain/expect.json +1 -0
- package/fixtures/S-Ident/const-chain/input.ts +1 -0
- package/fixtures/S-Ident/process/expect.json +1 -0
- package/fixtures/S-Ident/process/input.ts +1 -0
- package/fixtures/S-Ident/unresolved/expect.json +1 -0
- package/fixtures/S-Ident/unresolved/input.ts +1 -0
- package/fixtures/S-Index/dynamic-key/expect.json +1 -0
- package/fixtures/S-Index/dynamic-key/input.ts +1 -0
- package/fixtures/S-Index/literal-key/expect.json +1 -0
- package/fixtures/S-Index/literal-key/input.ts +1 -0
- package/fixtures/S-Literal/null-and-booleans/expect.json +1 -0
- package/fixtures/S-Literal/null-and-booleans/input.ts +1 -0
- package/fixtures/S-Literal/numeric/expect.json +1 -0
- package/fixtures/S-Literal/numeric/input.ts +1 -0
- package/fixtures/S-LocalFunction/arrow-const-call/expect.json +21 -0
- package/fixtures/S-LocalFunction/arrow-const-call/project/label.ts +3 -0
- package/fixtures/S-LocalFunction/function-as-value-still-rejects/expect.json +11 -0
- package/fixtures/S-LocalFunction/function-as-value-still-rejects/input.ts +3 -0
- package/fixtures/S-LocalFunction/same-file-declaration-call/expect.json +19 -0
- package/fixtures/S-LocalFunction/same-file-declaration-call/project/twice.ts +5 -0
- package/fixtures/S-Member/nested/expect.json +1 -0
- package/fixtures/S-Member/nested/input.ts +1 -0
- package/fixtures/S-Member/nullish-plain-refuses/expect.json +1 -0
- package/fixtures/S-Member/nullish-plain-refuses/input.ts +1 -0
- package/fixtures/S-Member/optional-chain/expect.json +1 -0
- package/fixtures/S-Member/optional-chain/input.ts +1 -0
- package/fixtures/S-Object/spread-later-wins/expect.json +1 -0
- package/fixtures/S-Object/spread-later-wins/input.ts +1 -0
- package/fixtures/S-Object/spread-non-object/expect.json +1 -0
- package/fixtures/S-Object/spread-non-object/input.ts +1 -0
- package/fixtures/S-Reject/arrow-as-value/expect.json +1 -0
- package/fixtures/S-Reject/arrow-as-value/input.ts +1 -0
- package/fixtures/S-Reject/call-as-value/expect.json +1 -0
- package/fixtures/S-Reject/call-as-value/input.ts +1 -0
- package/fixtures/S-Template/coercion/expect.json +2 -0
- package/fixtures/S-Template/coercion/input.ts +2 -0
- package/fixtures/S-Template/composite-step-span/expect.json +2 -0
- package/fixtures/S-Template/composite-step-span/input.ts +1 -0
- package/fixtures/S-Template/const-span/expect.json +2 -0
- package/fixtures/S-Template/const-span/input.ts +2 -0
- package/fixtures/S-Template/envelope-span/expect.json +2 -0
- package/fixtures/S-Template/envelope-span/input.ts +2 -0
- package/fixtures/S-Template/nested-construction-span/expect.json +2 -0
- package/fixtures/S-Template/nested-construction-span/input.ts +1 -0
- package/fixtures/S-Template/no-substitution/expect.json +2 -0
- package/fixtures/S-Template/no-substitution/input.ts +1 -0
- package/fixtures/S-Template/unfoldable-span/expect.json +16 -0
- package/fixtures/S-Template/unfoldable-span/input.ts +1 -0
- package/fixtures/S-Unary/not-and-negate/expect.json +1 -0
- package/fixtures/S-Unary/not-and-negate/input.ts +1 -0
- package/fixtures/S-Unclaimed/composite-step/expect.json +3 -0
- package/fixtures/S-Unclaimed/composite-step/input.ts +1 -0
- package/fixtures/S-Unwrap/as-and-parens/expect.json +1 -0
- package/fixtures/S-Unwrap/as-and-parens/input.ts +1 -0
- package/fixtures/UNCOVERED.md +37 -0
- package/package.json +35 -0
- package/spec/VERSION +1 -0
- package/spec/divergence.md +129 -0
- package/spec/grammar.md +277 -0
- package/spec/hosts.md +175 -0
- package/spec/judgments.md +1049 -0
- package/spec/rules.md +102 -0
- package/spec/values.md +247 -0
- package/src/adapter.ts +52 -0
- package/src/adapters/chant.ts +125 -0
- package/src/bundled.ts +27 -0
- package/src/chant-agreement.test.ts +67 -0
- package/src/corpus.test.ts +66 -0
- package/src/corpus.ts +540 -0
- package/src/fixture.ts +117 -0
- package/src/host.ts +105 -0
- package/src/index.ts +6 -0
- package/src/rules.test.ts +50 -0
- package/src/rules.ts +140 -0
- package/src/runner.test.ts +46 -0
- package/src/runner.ts +119 -0
- package/src/version.test.ts +31 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export const value = 1;
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
{
|
|
2
|
+
"rules": [
|
|
3
|
+
"F-Succ",
|
|
4
|
+
"F-Capture",
|
|
5
|
+
"F-Identity",
|
|
6
|
+
"F-Memo",
|
|
7
|
+
"F-Taint",
|
|
8
|
+
"F-Obs-Report"
|
|
9
|
+
],
|
|
10
|
+
"project": true,
|
|
11
|
+
"verdicts": {
|
|
12
|
+
"breaker.ts": "run",
|
|
13
|
+
"shared.ts": "run",
|
|
14
|
+
"sibling.ts": "run"
|
|
15
|
+
},
|
|
16
|
+
"tentative": {
|
|
17
|
+
"breaker.ts": "run",
|
|
18
|
+
"shared.ts": "fold",
|
|
19
|
+
"sibling.ts": "fold"
|
|
20
|
+
},
|
|
21
|
+
"taintedBy": {
|
|
22
|
+
"shared.ts": "breaker.ts",
|
|
23
|
+
"sibling.ts": "shared.ts"
|
|
24
|
+
},
|
|
25
|
+
"note": "The backward edge, two hops. breaker.ts is in the seed and taints shared.ts forward; shared.ts then taints sibling.ts backward because sibling.ts captured its registry object. Nothing in sibling.ts predicts its own verdict, which is why a fallback report has to be able to name the capture. The captured value is a plain object, which F-Identity's reference test admits and its entity test would not: the edge exists here because F-Capture over-approximates on purpose. It is also the fixture that holds F-Memo: the edge only exists because the object in sibling.ts's namespace is the very object shared.ts produced, and it caught a revival pass that rebuilt plain structures and handed out copies. The reason on the capturer must be able to say it was forced to run because the source runs and it captured the source's objects; nothing in its own source predicts that (F-Obs-Report)."
|
|
26
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export const registry = { name: "shared" };
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
{
|
|
2
|
+
"rules": ["F-Succ", "F-Taint", "F-Import"],
|
|
3
|
+
"project": true,
|
|
4
|
+
"verdicts": { "app.ts": "run", "config.ts": "run" },
|
|
5
|
+
"tentative": { "app.ts": "run", "config.ts": "fold" },
|
|
6
|
+
"taintedBy": { "config.ts": "app.ts" },
|
|
7
|
+
"note": "The forward edge. config.ts folds on its own, and runs anyway because app.ts, which imports it, runs: app.ts's real import would construct a second settings object. This is chant#1107's observation, that fixing a leaf buys nothing while an importer still runs."
|
|
8
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export const settings = { port: 8080 };
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
{
|
|
2
|
+
"rules": ["F-Taint", "F-Fix", "F-Verdict"],
|
|
3
|
+
"project": true,
|
|
4
|
+
"verdicts": { "app.ts": "run", "alone.ts": "fold" },
|
|
5
|
+
"tentative": { "app.ts": "run", "alone.ts": "fold" },
|
|
6
|
+
"taintedBy": {},
|
|
7
|
+
"exports": { "alone.ts": { "value": { "kept": true, "items": [1, 2] } } },
|
|
8
|
+
"note": "The control. T(B) is the LEAST set closed under Succ, so a file no edge reaches keeps its fold verdict. An implementation that fell back whenever any file in the build fell back would pass the other three fixtures and fail this one."
|
|
9
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export const value = { kept: true, items: [1, 2] };
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"rules": ["F-Total", "F-Declarator", "F-Reference"],
|
|
3
|
+
"project": true,
|
|
4
|
+
"verdicts": { "mixed.ts": "run" },
|
|
5
|
+
"tentative": { "mixed.ts": "run" },
|
|
6
|
+
"note": "No partial namespace is ever produced. The first declarator reduces and the second does not, and the verdict is run for the whole file, so a consumer never sees a half-folded module."
|
|
7
|
+
}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
{
|
|
2
|
+
"rules": ["F-Val-Arity"],
|
|
3
|
+
"project": true,
|
|
4
|
+
"host": "shapes",
|
|
5
|
+
"verdicts": { "arities.ts": "fold" },
|
|
6
|
+
"exports": {
|
|
7
|
+
"arities.ts": {
|
|
8
|
+
"withProps": { "entityType": "Bucket", "lexicon": "shapes", "props": { "name": "a" }, "attributes": {} },
|
|
9
|
+
"withAttributes": { "entityType": "Bucket", "lexicon": "shapes", "props": { "name": "b" }, "attributes": { "region": "eu" } },
|
|
10
|
+
"spread": { "left": 1, "right": "two", "entityType": "Pair", "lexicon": "shapes" }
|
|
11
|
+
}
|
|
12
|
+
},
|
|
13
|
+
"note": "Both arms. A leading object literal is props, a second one is attributes, and anything else is spread positionally. The three forms are distinguished at fold time by the shape of the argument list, so revival has only to honour what the envelope recorded."
|
|
14
|
+
}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
{
|
|
2
|
+
"rules": [
|
|
3
|
+
"F-Val-Callable",
|
|
4
|
+
"F-Eval-Ident",
|
|
5
|
+
"F-Import"
|
|
6
|
+
],
|
|
7
|
+
"project": true,
|
|
8
|
+
"host": "shapes",
|
|
9
|
+
"verdicts": {
|
|
10
|
+
"app.ts": "run"
|
|
11
|
+
},
|
|
12
|
+
"rejectRule": {
|
|
13
|
+
"app.ts": "F-Eval-Ident"
|
|
14
|
+
},
|
|
15
|
+
"note": "A host function bound by an import and used as a value (#69). The binding exists, so a call would fold (it is a registered helper); the value use is refused, because a callable is reached only by the form that invokes it and could never reach a serializer. chant refuses the same file by never binding an unregistered callable; the verdicts agree."
|
|
16
|
+
}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
{
|
|
2
|
+
"rules": ["F-Val-Fate", "F-Val-Position"],
|
|
3
|
+
"project": true,
|
|
4
|
+
"host": "shapes",
|
|
5
|
+
"verdicts": { "entities.ts": "fold" },
|
|
6
|
+
"exports": {
|
|
7
|
+
"entities.ts": {
|
|
8
|
+
"bucket": { "entityType": "Bucket", "lexicon": "shapes", "props": { "name": "logs" }, "attributes": {} },
|
|
9
|
+
"tagged": "bucket-1",
|
|
10
|
+
"shouted": "DONE",
|
|
11
|
+
"reference": { "who": { "__attrRef": { "entity": "bucket", "attribute": "name" } } }
|
|
12
|
+
}
|
|
13
|
+
},
|
|
14
|
+
"note": "Four of the six envelopes and the one that survives. The resource is constructed by the class the file imports, the intrinsic tag and the helper are invoked, and the attribute reference passes through unrevived because nothing in the build has named the instance yet."
|
|
15
|
+
}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
{
|
|
2
|
+
"rules": ["F-Val-Live", "F-Identity"],
|
|
3
|
+
"project": true,
|
|
4
|
+
"verdicts": { "source.ts": "run", "breaker.ts": "run", "quiet.ts": "fold" },
|
|
5
|
+
"tentative": { "source.ts": "fold", "breaker.ts": "run", "quiet.ts": "fold" },
|
|
6
|
+
"taintedBy": { "source.ts": "breaker.ts" },
|
|
7
|
+
"exports": { "quiet.ts": { "data": { "n": 2, "nested": { "deeper": [2, 2] } } } },
|
|
8
|
+
"note": "The entity test earning its keep. breaker.ts is in the seed and taints source.ts forward. quiet.ts calls the same function and survives, because nothing the call returned carries a live object: under the reference test every parameter helper would be a taint source and quiet.ts would fall back with it."
|
|
9
|
+
}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
{
|
|
2
|
+
"rules": ["F-Val-Position", "F-Val-Fate"],
|
|
3
|
+
"project": true,
|
|
4
|
+
"host": "shapes",
|
|
5
|
+
"verdicts": { "rejected.ts": "run" },
|
|
6
|
+
"tentative": { "rejected.ts": "run" },
|
|
7
|
+
"note": "The other arm. An attribute reference passes through revival everywhere except inside a host call's arguments, where it is rejected: the receiver would see a look-alike plain object instead of a live instance and produce wrong output rather than absent output. Wrong output is the one failure a fallback cannot repair, so this is a rejection and not a pass-through."
|
|
8
|
+
}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
{
|
|
2
|
+
"rules": [
|
|
3
|
+
"F-Val-Undefined",
|
|
4
|
+
"F-Eval-Array"
|
|
5
|
+
],
|
|
6
|
+
"export": "x",
|
|
7
|
+
"shape": "accept",
|
|
8
|
+
"fold": "fold",
|
|
9
|
+
"value": [
|
|
10
|
+
1,
|
|
11
|
+
"$undefined",
|
|
12
|
+
3
|
|
13
|
+
],
|
|
14
|
+
"note": "In an array position undefined stays undefined in the namespace and becomes null at emission, not absent: the array keeps its length (F-Val-Undefined)."
|
|
15
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export const x = [1, undefined, 3];
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
{
|
|
2
|
+
"rules": [
|
|
3
|
+
"F-Val-Undefined",
|
|
4
|
+
"F-Eval-Conditional"
|
|
5
|
+
],
|
|
6
|
+
"export": "x",
|
|
7
|
+
"shape": "accept",
|
|
8
|
+
"fold": "fold",
|
|
9
|
+
"value": {
|
|
10
|
+
"a": "$undefined"
|
|
11
|
+
},
|
|
12
|
+
"note": "The idiom a selective-by-omission consumer will write: a field set only when a condition holds. The untaken branch is never folded; the taken one yields undefined and the key is present with it."
|
|
13
|
+
}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
{
|
|
2
|
+
"rules": [
|
|
3
|
+
"F-Val-Undefined",
|
|
4
|
+
"F-Eval-Member"
|
|
5
|
+
],
|
|
6
|
+
"export": "x",
|
|
7
|
+
"shape": "accept",
|
|
8
|
+
"fold": "fold",
|
|
9
|
+
"value": {
|
|
10
|
+
"b": "$undefined"
|
|
11
|
+
},
|
|
12
|
+
"note": "A short-circuited chain yields undefined, and the property it lands in is present with that value, exactly as running the expression leaves it."
|
|
13
|
+
}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
{
|
|
2
|
+
"rules": [
|
|
3
|
+
"F-Val-Undefined",
|
|
4
|
+
"F-Eval-Undefined",
|
|
5
|
+
"F-Eval-Object",
|
|
6
|
+
"F-Val-Serializable"
|
|
7
|
+
],
|
|
8
|
+
"export": "x",
|
|
9
|
+
"shape": "accept",
|
|
10
|
+
"fold": "fold",
|
|
11
|
+
"value": {
|
|
12
|
+
"a": 1,
|
|
13
|
+
"b": "$undefined"
|
|
14
|
+
},
|
|
15
|
+
"note": "The key is present in the folded namespace with the value undefined; emission drops it (F-Val-Undefined). A consumer whose contract is selective-by-omission has to know which of the two it is reading, and the namespace keeps the distinction that JSON loses (#82)."
|
|
16
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export const x = { a: 1, b: undefined };
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
{
|
|
2
|
+
"rules": [
|
|
3
|
+
"F-Val-Undefined",
|
|
4
|
+
"F-Eval-Object"
|
|
5
|
+
],
|
|
6
|
+
"export": "x",
|
|
7
|
+
"shape": "accept",
|
|
8
|
+
"fold": "fold",
|
|
9
|
+
"value": {
|
|
10
|
+
"a": "$undefined",
|
|
11
|
+
"b": 1
|
|
12
|
+
},
|
|
13
|
+
"note": "Object spread copies own enumerable entries, and an undefined-valued entry is one of them (R10.5). The key travels; only emission drops it."
|
|
14
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{ "rules": ["S-Array", "F-Eval-Array"], "export": "x", "shape": "accept", "fold": "fold", "value": [1, 2, 3, 4] }
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
const t = [2, 3]; export const x = [1, ...t, 4];
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{ "rules": ["S-Binary", "F-Eval-Binary"], "export": "x", "shape": "accept", "fold": "fold", "value": [3, "a1", 3.5, true, false], "note": "R10.1: ECMAScript semantics per operator, including + string dispatch." }
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export const x = [1 + 2, "a" + 1, 7 / 2, 3 === 3, 2 < 1];
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{ "rules": ["S-Binary", "F-Eval-Binary", "F-Exc-Lazy"], "export": "x", "shape": "reject", "fold": "fold", "value": false, "note": "F-Exc-Lazy: the classifier rejects (right operand out of subset); the folder never folds the untaken side. The exception to F-Direction, exercised." }
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export const x = false && getId();
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{ "rules": ["S-Binary", "F-Eval-Binary"], "export": "x", "shape": "accept", "fold": "fold", "value": "d" }
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
const u = undefined; export const x = u ?? "d";
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
{
|
|
2
|
+
"rules": [
|
|
3
|
+
"S-CallLocal",
|
|
4
|
+
"S-Call"
|
|
5
|
+
],
|
|
6
|
+
"export": "x",
|
|
7
|
+
"shape": "accept",
|
|
8
|
+
"fold": "run",
|
|
9
|
+
"note": "The callee is bound by an import from a project specifier, which the classifier can see in the file, so the call is shape-valid (spec 1.2). An expression fixture has no module graph, so the folder cannot resolve twice and refuses; the whole-build form is F-Eval-CallLocal/local-function-folds. chant's classifier rejects this today (chant#2435), and the agreement test holds the shape half out until it does not."
|
|
10
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{ "rules": ["S-Conditional", "F-Eval-Conditional", "F-Exc-Lazy"], "export": "x", "shape": "reject", "fold": "fold", "value": "yes", "note": "F-Exc-Lazy for the conditional: untaken branch is never folded." }
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export const x = true ? "yes" : getId();
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
{
|
|
2
|
+
"rules": [
|
|
3
|
+
"S-ExportDefault",
|
|
4
|
+
"F-Import",
|
|
5
|
+
"F-Declarator"
|
|
6
|
+
],
|
|
7
|
+
"project": true,
|
|
8
|
+
"profiles": [
|
|
9
|
+
"data-host"
|
|
10
|
+
],
|
|
11
|
+
"verdicts": {
|
|
12
|
+
"policy.ts": "fold",
|
|
13
|
+
"app.ts": "fold"
|
|
14
|
+
},
|
|
15
|
+
"exports": {
|
|
16
|
+
"policy.ts": {
|
|
17
|
+
"default": {
|
|
18
|
+
"name": "svc",
|
|
19
|
+
"replicas": 2
|
|
20
|
+
}
|
|
21
|
+
},
|
|
22
|
+
"app.ts": {
|
|
23
|
+
"doubled": {
|
|
24
|
+
"name": "svc",
|
|
25
|
+
"replicas": 4
|
|
26
|
+
}
|
|
27
|
+
}
|
|
28
|
+
},
|
|
29
|
+
"note": "A default import binds the target's default export (F-Import), and the value is data like any other."
|
|
30
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export default { name: "svc", replicas: 2 };
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
{
|
|
2
|
+
"rules": [
|
|
3
|
+
"S-ExportDefault",
|
|
4
|
+
"F-Declarator",
|
|
5
|
+
"F-Scan"
|
|
6
|
+
],
|
|
7
|
+
"export": "default",
|
|
8
|
+
"shape": "accept",
|
|
9
|
+
"fold": "fold",
|
|
10
|
+
"value": {
|
|
11
|
+
"a": 1,
|
|
12
|
+
"b": [
|
|
13
|
+
2,
|
|
14
|
+
3
|
|
15
|
+
]
|
|
16
|
+
},
|
|
17
|
+
"profiles": [
|
|
18
|
+
"data-host"
|
|
19
|
+
],
|
|
20
|
+
"note": "The idiom of every configuration file (spec 1.2, #94). The export is named default. Tagged data-host only: the full profile keeps export default under S-Disqualify until chant admits it, and the first consumer worked around it with a named export."
|
|
21
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export default { a: 1, b: [2, 3] };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{ "rules": ["S-Ident", "F-Eval-Ident"], "export": "x", "shape": "accept", "fold": "fold", "value": 1, "note": "F-Eval-Ident step 2: a const resolves to its initializer, transitively." }
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
const a = 1; const b = a; export const x = b;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{ "rules": ["F-Eval-Ident"], "export": "x", "shape": "accept", "fold": "run", "note": "F-Eval-Ident step 4: a bare process reference is a pointed rejection." }
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export const x = process;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{ "rules": ["S-Ident", "F-Eval-Ident", "F-Div-Ident"], "export": "x", "shape": "accept", "fold": "run", "note": "F-Direction: shape accepts any identifier; the folder rejects an unresolved one. The canonical permitted-direction divergence." }
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export const x = nope;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{ "rules": ["S-Index", "F-Eval-Index"], "export": "x", "shape": "reject", "fold": "run", "note": "EVL003: a non-literal key is rejected at shape and at fold." }
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
const o = { k: "v" }; const key = "k"; export const x = o[key];
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{ "rules": ["S-Index", "F-Eval-Index"], "export": "x", "shape": "accept", "fold": "fold", "value": "v" }
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
const o = { k: "v" }; export const x = o["k"];
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{ "rules": ["S-Literal", "S-Array", "F-Eval-Literal", "F-Eval-Array"], "export": "x", "shape": "accept", "fold": "fold", "value": [true, false, null] }
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export const x = [true, false, null];
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{ "rules": ["S-Literal", "F-Eval-Literal"], "export": "x", "shape": "accept", "fold": "fold", "value": 42 }
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export const x = 42;
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
{
|
|
2
|
+
"rules": [
|
|
3
|
+
"S-LocalFunction",
|
|
4
|
+
"F-Bind",
|
|
5
|
+
"F-Eval-CallLocal",
|
|
6
|
+
"S-FnBody"
|
|
7
|
+
],
|
|
8
|
+
"project": true,
|
|
9
|
+
"verdicts": {
|
|
10
|
+
"label.ts": "fold"
|
|
11
|
+
},
|
|
12
|
+
"exports": {
|
|
13
|
+
"label.ts": {
|
|
14
|
+
"y": {
|
|
15
|
+
"label": "k",
|
|
16
|
+
"upper": true
|
|
17
|
+
}
|
|
18
|
+
}
|
|
19
|
+
},
|
|
20
|
+
"note": "A const bound to an arrow is a project-local function, and its concise body is S-FnBody's first alternative. This is the helper the first consumer wrote and had refused; chant's build folds it (chant#2435 is the classifier)."
|
|
21
|
+
}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
{
|
|
2
|
+
"rules": [
|
|
3
|
+
"S-LocalFunction",
|
|
4
|
+
"F-Eval-Ident",
|
|
5
|
+
"F-Val-Callable"
|
|
6
|
+
],
|
|
7
|
+
"export": "f",
|
|
8
|
+
"shape": "accept",
|
|
9
|
+
"fold": "run",
|
|
10
|
+
"note": "Binding the arrow as a function changes nothing about its use as a value: F-Eval-Ident step 3 rejects a FoldableFunction in value position, so nothing unserialisable reaches the namespace."
|
|
11
|
+
}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
{
|
|
2
|
+
"rules": [
|
|
3
|
+
"S-LocalFunction",
|
|
4
|
+
"F-Bind",
|
|
5
|
+
"F-Eval-CallLocal"
|
|
6
|
+
],
|
|
7
|
+
"project": true,
|
|
8
|
+
"verdicts": {
|
|
9
|
+
"twice.ts": "fold"
|
|
10
|
+
},
|
|
11
|
+
"exports": {
|
|
12
|
+
"twice.ts": {
|
|
13
|
+
"x": {
|
|
14
|
+
"doubled": 42
|
|
15
|
+
}
|
|
16
|
+
}
|
|
17
|
+
},
|
|
18
|
+
"note": "A same-file function declaration, not exported, binds a project-local function (spec 1.2, #95). chant's build folded this before the text said so; its classifier and its expression folder still refuse it (chant#2435), which is why this is a whole-build fixture."
|
|
19
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{ "rules": ["S-Member", "F-Eval-Member"], "export": "x", "shape": "accept", "fold": "fold", "value": "deep" }
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
const o = { a: { b: "deep" } }; export const x = o.a.b;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{ "rules": ["S-Member", "F-Eval-Member", "F-Div-Nullish"], "export": "x", "shape": "accept", "fold": "run", "note": "chant-v0.63.0: a plain read on undefined refuses (running throws). Shape cannot see it." }
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
const o = { a: { b: 1 } }; export const x = o.nope.b;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"rules": ["S-Member", "F-Eval-Member"], "export": "x", "shape": "accept", "fold": "fold", "value": "$undefined", "note": "?. on a nullish object short-circuits the chain to undefined (F-Eval-Member steps 3\u20134, chant-v0.63.0). The folded value is undefined itself; what a serializer does with it is F-Val-Undefined's question, not this fixture's."}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
const o = { a: { b: 1 } }; export const x = o.nope?.b;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{ "rules": ["S-Object", "S-SpreadProp", "F-Eval-Object"], "export": "x", "shape": "accept", "fold": "fold", "value": { "a": 1, "b": 3, "c": 4 }, "note": "R10.5: insertion order, later key wins." }
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
const d = { a: 1, b: 2 }; export const x = { ...d, b: 3, c: 4 };
|