@nudojs/core 1.9.0 → 1.9.1

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.
@@ -30,6 +30,7 @@ import {
30
30
  litValue,
31
31
  literalMeetsConstraint,
32
32
  locateContractParam,
33
+ makeSymbolicRestAbs,
33
34
  numLit,
34
35
  pTrue,
35
36
  parseSource,
@@ -45,7 +46,7 @@ import {
45
46
  withEvalBudgetOverride,
46
47
  withExecPhi,
47
48
  withFnBudgetOverride
48
- } from "./chunk-3SLNJPNY.js";
49
+ } from "./chunk-733OATC3.js";
49
50
 
50
51
  // src/algebra/directive-scan.ts
51
52
  function cleanDirectiveLine(raw, kind) {
@@ -3615,8 +3616,10 @@ function generalizeFromAstUncached(fnName, source, opts = {}) {
3615
3616
  }
3616
3617
  return result;
3617
3618
  };
3619
+ const restIdx = formals.findIndex((f) => f.kind === "rest");
3620
+ const symbolicArgs = restIdx === -1 ? typeParams.map((t) => t.value) : typeParams.map((t, i) => i === restIdx ? makeSymbolicRestAbs() : t.value);
3618
3621
  const symbolic = run(
3619
- typeParams.map((t) => t.value),
3622
+ symbolicArgs,
3620
3623
  // 入口契约进 Φ,让 body 内的单调性可传播
3621
3624
  entryReqs && entryReqs.length > 0 ? entryReqs.length === 1 ? entryReqs[0].pred : { op: "and", args: entryReqs.map((r) => r.pred) } : pTrue
3622
3625
  );