Skip to content

Commit 7bdf0a7

Browse files
committed
Allow matching functions when rewriting
1 parent 7bf75ea commit 7bdf0a7

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

booster/library/Booster/Pattern/Match.hs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -294,6 +294,7 @@ match1 _ t1@FunctionApplication{} t2@KSet{}
294294
match1 Eval (FunctionApplication symbol1 sorts1 args1) (ConsApplication symbol2 sorts2 args2) = matchSymbolAplications Eval symbol1 sorts1 args1 symbol2 sorts2 args2
295295
match1 _ t1@FunctionApplication{} t2@ConsApplication{} = addIndeterminate t1 t2
296296
match1 Eval (FunctionApplication symbol1 sorts1 args1) (FunctionApplication symbol2 sorts2 args2) = matchSymbolAplications Eval symbol1 sorts1 args1 symbol2 sorts2 args2
297+
match1 Rewrite (FunctionApplication symbol1 sorts1 args1) (FunctionApplication symbol2 sorts2 args2) = matchSymbolAplications Rewrite symbol1 sorts1 args1 symbol2 sorts2 args2
297298
match1 _ t1@FunctionApplication{} t2@FunctionApplication{} = addIndeterminate t1 t2
298299
match1 Rewrite t1@FunctionApplication{} (Var t2) = failWith $ SubjectVariableMatch t1 t2
299300
match1 _ t1@FunctionApplication{} t2@Var{} = addIndeterminate t1 t2

0 commit comments

Comments
 (0)