add structural tests for partial strings, rename ast.rs

This commit is contained in:
Mark Thom
2018-09-04 21:20:45 -06:00
parent 9713286023
commit 33d1a7c701
27 changed files with 46 additions and 30 deletions

View File

@@ -1,7 +1,7 @@
use prolog_parser::ast::*;
use prolog::ast::*;
use prolog::heap_print::*;
use prolog::instructions::*;
use prolog::compile::*;
use prolog::machine::*;
@@ -1936,4 +1936,7 @@ fn test_queries_on_string_lists()
assert_prolog_failure!(&mut wam, "?- partial_string(\"abc\", X), partial_string(\"ababc\", Y), Y = [a,b|Z],
X == Z.");
assert_prolog_success!(&mut wam, "?- partial_string(\"abc\", X), X @> \"abc\".");
assert_prolog_failure!(&mut wam, "?- partial_string(\"abc\", X), X \\=@= \"abc\".");
assert_prolog_failure!(&mut wam, "?- partial_string(\"abc\", X), X @< \"abc\".");
}