]> Repositorios git - scryer-prolog.git/commitdiff
Fix priority in op/3
authorbakaq <[email protected]>
Sun, 13 Oct 2024 02:37:58 +0000 (23:37 -0300)
committerbakaq <[email protected]>
Sun, 13 Oct 2024 02:37:58 +0000 (23:37 -0300)
src/toplevel.pl

index 090d2094751e613211edacaf76a671f3d0564dfe..e60791067042c6eb8f05d4549b46a49c3197a9b2 100644 (file)
@@ -170,14 +170,14 @@ repl :-
 %% Enable op declarations with lists of operands, i.e.,
 %% :- op(900, fy, [$,@]).
 
-user:term_expansion((:- op(Pred, Spec, Ops)), OpResults) :-
+user:term_expansion((:- op(Pri, Spec, Ops)), OpResults) :-
     ground(Ops),
     Ops = [Op | OtherOps],
-    expand_op_list([Op | OtherOps], Pred, Spec, OpResults).
+    expand_op_list([Op | OtherOps], Pri, Spec, OpResults).
 
 expand_op_list([], _, _, []).
-expand_op_list([Op | OtherOps], Pred, Spec, [(:- op(Pred, Spec, Op)) | OtherResults]) :-
-    expand_op_list(OtherOps, Pred, Spec, OtherResults).
+expand_op_list([Op | OtherOps], Pri, Spec, [(:- op(Pri, Spec, Op)) | OtherResults]) :-
+    expand_op_list(OtherOps, Pri, Spec, OtherResults).
 
 
 read_and_match :-