From: Mark Thom Date: Wed, 17 May 2017 01:35:22 +0000 (-0600) Subject: add (non)-deterministic REPL demarcations X-Git-Tag: v0.8.110~729 X-Git-Url: https://git.sagredo.dev/?a=commitdiff_plain;h=5fa98815569caa280289b3f507efd5ba4d9b1645;p=scryer-prolog.git add (non)-deterministic REPL demarcations --- diff --git a/src/prolog/io.rs b/src/prolog/io.rs index 3a9fb341..12149d49 100644 --- a/src/prolog/io.rs +++ b/src/prolog/io.rs @@ -304,8 +304,14 @@ Each predicate must have the same name and arity."; pub fn print(wam: &mut Machine, result: EvalSession) { match result { EvalSession::InitialQuerySuccess(alloc_locs, mut heap_locs) => { - println!("true"); + print!("true"); + if !wam.or_stack_is_empty() { + print!(" "); + } + + println!("."); + if heap_locs.is_empty() { return; }