Mark Thom
10af206024
make chars callable ( #713 )
2021-03-17 19:50:41 -06:00
Mark Thom
6c23d7aec8
always print variable bindings before names ( #865 )
2021-03-17 19:27:53 -06:00
Mark Thom
7937ccee30
check that a load context path is a filename before potentially returning it as a string
2021-03-17 18:58:33 -06:00
Mark Thom
b98e8c34eb
findall/4 should be declared as a meta-predicate ( #873 )
2021-03-17 18:13:06 -06:00
notoria
f4be0cf4b3
Extend alnum, add forgotten graphic_token
2021-03-17 20:47:09 +01:00
Mark Thom
5f7abda22d
remove operators declared at user-level from files when reloading
2021-03-16 18:30:34 -06:00
Mark Thom
51424aed32
clear user-level definitions when reloading a file ( #455 )
2021-03-16 02:30:09 -06:00
Mark Thom
914fb09ed0
don't warn about overwriting a clause asserted to a dynamic predicate whose clauses have all been retracted ( #870 )
2021-03-15 14:22:54 -06:00
Mark Thom
7ea7e5c951
remove intra-module predicates from module code directory when module is being re-defined ( #848 )
2021-03-13 23:22:24 -07:00
Skgland
d437609365
improve comment
2021-03-11 01:52:21 +01:00
Mark Thom
d4d47182b4
fix is_cyclic_term ( #864 )
2021-03-10 16:11:48 -07:00
Mark Thom
bc2d0191ff
Merge pull request #861 from notoria/mod
...
Small improvement for mod in CLP(Z)
2021-03-10 13:52:48 -07:00
notoria
bd222ed2bf
Added a test for mod in CLP(Z)
2021-03-10 21:20:18 +01:00
notoria
93b835ae0d
Use functional notation in CLP(Z) for compatibility
2021-03-07 20:59:25 +01:00
notoria
aa2d57cf37
Implemented a propagator for xor in CLP(Z)
2021-03-07 18:52:10 +01:00
notoria
f6d4821a68
Small improvement for mod in CLP(Z)
2021-03-07 18:38:04 +01:00
Markus Triska
842176a595
is is --> is
2021-03-05 18:36:00 +01:00
Markus Triska
0fb74b56b3
FIXED: CLP(B): weighted_maximum/3 with repeated variables
...
Many thanks to @jburse for reporting this issue:
https://github.com/triska/clpz/issues/15
Example:
?- sat(~(Y*X)), sat(Z=:=Y), weighted_maximum([7,2,5],[X,Y,Z],W).
W = 7, Y = 0, X = 1, Z = 0
; W = 7, Y = 1, X = 0, Z = 1
; false.
2021-03-05 18:35:19 +01:00
Markus Triska
87abcd6a52
adapt comment to Scryer Prolog
2021-03-05 18:16:38 +01:00
Mark Thom
0a71e40030
qualify '$print_project_attributes_exception' call ( #857 )
2021-03-05 01:14:56 -07:00
Mark Thom
1b9db035ba
call project_attributes from top-level ( #846 )
2021-03-04 16:05:06 -07:00
Markus Triska
d92951ba5b
ENHANCED: more readable indentation of nested disjunctions
...
Example:
?- portray_clause((h :- a ; b ; c)).
h :-
( a
; b
; c
).
true.
2021-03-04 21:40:24 +01:00
Markus Triska
c5749cbbb1
remove unnecessary argument
2021-03-04 21:40:24 +01:00
Markus Triska
761d707b69
use the new portray_clause/1 output for generated definitions
2021-03-03 22:34:09 +01:00
Markus Triska
d327a05e12
separate side-effects from declarative description to facilitate test cases etc.
2021-03-03 22:34:09 +01:00
Markus Triska
6477d21e24
ENHANCED: more readable indentation of nested ( If -> Then ; Else ) constructs
...
Example:
?- portray_clause((h :- ( a -> b ; c -> d ; e, f))).
h :-
( a ->
b
; c ->
d
; e,
f
).
true.
2021-03-03 22:34:09 +01:00
Mark Thom
d3612e956e
catch exceptions thrown from initialization goals ( #852 )
2021-03-03 13:56:13 -07:00
Mark Thom
5a3ee3a46e
has_tail must be false for use as a filename from open/{3,4}
2021-03-03 12:16:47 -07:00
Markus Triska
5b60c8aa7e
remove min_/3 and max_/3 which are also defined elsewhere
2021-03-02 19:59:57 +01:00
Markus Triska
8c5a688566
remove group_pairs_by_key/2, which is now provided by library(pairs)
2021-03-02 19:58:20 +01:00
Mark Thom
7ea9706c94
warn when overwriting a predicate ( #848 )
2021-03-02 11:43:47 -07:00
Mark Thom
5976e2d873
do not check for non-unifiability in dif:attribute_goals, which is sure to succeed, resulting in no goals being printed at top-level ( #844 )
2021-03-02 10:34:25 -07:00
Mark Thom
e8971e0d8b
use atom_chars to convert .scryerrc path string to atom
2021-02-28 23:26:22 -07:00
Mark Thom
498c4660d0
use plain ! while interpreting control functors in metacalls ( #724 )
2021-02-28 19:12:35 -07:00
Mark Thom
54c142fc0d
apply expand_module_names to call(A) goals
2021-02-28 19:01:36 -07:00
Mark Thom
6079402dc4
suppress tabled/2 existence errors in tabling library, do not print evaluation errors generated by term and goal expansion in loader.pl
2021-02-28 18:56:24 -07:00
Mark Thom
d6e04beb95
check that Module is an atom before calling Module:goal_expansion/2
2021-02-28 18:28:12 -07:00
Mark Thom
9a225e6244
wrap variable goals in module-expanded call/1
2021-02-28 18:15:33 -07:00
Mark Thom
a03f00628b
do not print error messages if .scryerrc[.pl] does not exist ( #842 )
2021-02-28 17:57:35 -07:00
Mark Thom
360485d830
print errors arising from term and goal expansion calls from loader.pl
2021-02-28 16:19:37 -07:00
Mark Thom
3f1cfd2995
introduce bind_fn, use in applicable Fact/Query instructions ( #841 )
2021-02-28 16:19:06 -07:00
Mark Thom
08e2b601f1
pop non-composite terms from iter stack in is_cyclic_term
2021-02-28 12:28:19 -07:00
Mark Thom
101ed9a633
add error value to occurs_check prolog flag ( #783 )
2021-02-28 11:44:23 -07:00
Skgland
0a08464d4f
move the signal handler to the binary
2021-02-28 19:21:31 +01:00
Skgland
a638d42d92
remove #[allow(dead_code)]
...
only commenting out the unused variant as `OptArgIndexKeyType`
as it appears to mirror `OptArgIndexKey` and there List is not unused
so this appears to be not yet used rather than obsolete
2021-02-28 19:21:31 +01:00
Skgland
90256ea2f5
fix CI lib build with beta compiler
2021-02-28 19:21:31 +01:00
Skgland
2f428b7261
split into lib and bin
...
* makes most pub things in src/ pub(crate) as not to expose things accidentally
* only those things needed by src/bin/scryer-prolog.rs and tests/scryer.rs
should be pub
* split src/main.rs into src/lib.rs and src/bin/scryer-prolog.rs
* add tests folder and run most of the files in src/tests with cargo test
added bytes method to Stream in src/machine/streams.rs to check if stdout is as expected
2021-02-28 19:21:30 +01:00
Mark Thom
f935060b2b
restore .scryerrc loading
2021-02-28 11:03:55 -07:00
Mark Thom
a367812348
add occurs_check flag ( #309 )
2021-02-28 10:41:32 -07:00
Mark Thom
8e6a89b279
enable op declarations with lists of operands using term expansion ( #839 )
2021-02-28 09:15:03 -07:00