-
-
Notifications
You must be signed in to change notification settings - Fork 177
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
ENHANCED: gui tracer support for
Head ==> Body
rules.
- Loading branch information
1 parent
5f7de8a
commit d5b6bcb
Showing
1 changed file
with
11 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,7 +3,7 @@ | |
Author: Jan Wielemaker | ||
E-mail: [email protected] | ||
WWW: http://www.swi-prolog.org | ||
Copyright (c) 2005-2023, University of Amsterdam | ||
Copyright (c) 2005-2024, University of Amsterdam | ||
VU University Amsterdam | ||
CWI, Amsterdam | ||
SWI-Prolog Solutions b.v. | ||
|
@@ -280,8 +280,10 @@ | |
functor(Bindings, varnames, L), | ||
do_make_varnames(Offsets, Names, Bindings). | ||
|
||
dcg_head((Head --> _Body), Head). | ||
dcg_head((Head ==> _Body), Head). | ||
dcg_head((Head,_ --> _Body), Head). | ||
dcg_head((Head --> _Body), Head). | ||
dcg_head((Head,_ ==> _Body), Head). | ||
dcg_head((Head ==> _Body), Head). | ||
|
||
do_make_varnames([], _, _). | ||
do_make_varnames([N=Var|TO], Names, Bindings) :- | ||
|
@@ -405,6 +407,12 @@ | |
unify_clause((Head => Body), Compiled1, Module, TermPos0, TermPos) :- | ||
!, | ||
unify_clause2((Head :- Body), Compiled1, Module, TermPos0, TermPos). | ||
unify_clause(Read, Compiled1, Module, TermPos0, TermPos) :- | ||
Read = (_ ==> _), | ||
ci_expand(Read, Compiled2, Module, TermPos0, TermPos1), | ||
Compiled2 \= (_ ==> _), | ||
!, | ||
unify_clause(Compiled2, Compiled1, Module, TermPos1, TermPos). | ||
unify_clause(Read, Decompiled, Module, TermPos0, TermPos) :- | ||
unify_clause2(Read, Decompiled, Module, TermPos0, TermPos). | ||
|
||
|