diff options
Diffstat (limited to '')
-rw-r--r-- | new-luxc/source/luxc/lang/synthesis/expression.lux | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/new-luxc/source/luxc/lang/synthesis/expression.lux b/new-luxc/source/luxc/lang/synthesis/expression.lux index 531606ba7..9ea397576 100644 --- a/new-luxc/source/luxc/lang/synthesis/expression.lux +++ b/new-luxc/source/luxc/lang/synthesis/expression.lux @@ -60,9 +60,9 @@ (-> ls;Synthesis (List ls;Synthesis) ls;Synthesis) (` ("lux call" (~ funcS) (~@ argsS)))) -(def: (synthesize-case synthesize inputA branchesA) +(def: (synthesize-case synthesize outer-arity inputA branchesA) (-> (-> la;Analysis ls;Synthesis) - la;Analysis (List [la;Pattern la;Analysis]) + ls;Arity la;Analysis (List [la;Pattern la;Analysis]) ls;Synthesis) (let [inputS (synthesize inputA)] (case (list;reverse branchesA) @@ -84,7 +84,7 @@ (function [pattern expr] (|> (synthesize expr) (~) ("lux case exec") - ("lux case seq" (~ (caseS;path pattern))) + ("lux case seq" (~ (caseS;path outer-arity pattern))) (`)))) pathS (list/fold caseS;weave (transform-branch lastP lastA) @@ -143,7 +143,7 @@ (var$ (maybe;default var (dict;get var resolver)))) (^code ("lux case" (~ inputA) (~ [_ (#;Record branchesA)]))) - (synthesize-case (recur outer-arity resolver num-locals) inputA branchesA) + (synthesize-case (recur outer-arity resolver num-locals) outer-arity inputA branchesA) (^multi (^code ("lux function" [(~@ scope)] (~ bodyA))) [(s;run scope (p;some s;int)) (#e;Success raw-env)]) |