From: Mark Thom Date: Sun, 17 Feb 2019 18:51:24 +0000 (-0700) Subject: do not count calls to $reify_switch as inferences X-Git-Tag: v0.8.110~244 X-Git-Url: https://git.sagredo.dev/?a=commitdiff_plain;h=896914b8e9790596c611822c2cddbdac09d865f7;p=scryer-prolog.git do not count calls to $reify_switch as inferences --- diff --git a/src/prolog/lib/reif.pl b/src/prolog/lib/reif.pl index dc7a68a0..ad12fcc6 100644 --- a/src/prolog/lib/reif.pl +++ b/src/prolog/lib/reif.pl @@ -5,18 +5,18 @@ :- use_module(library(control), [(\=)/2]). :- use_module(library(dif)). -/* in essence, '$reify_switch'(T, Then_0, Else_0) is this: +/* in essence, '$reify_switch'(T, Then_0, Else_0) is semantically this: ( T == true -> call(Then_0) ; T == false -> call(Else_0) ; nonvar(T) -> throw(error(type_error(boolean, T), _)) ; throw(error(instantiation_error, _)) ). - but without creating choice points. + but it does not create choice points. */ if_(If_1, Then_0, Else_0) :- call(If_1, T), - '$reify_switch'(T, Then_0, Else_0). + '$call_with_default_policy'('$reify_switch'(T, Then_0, Else_0)). =(X, Y, T) :- ( X == Y -> T = true