]> Repositorios git - scryer-prolog.git/log
scryer-prolog.git
2 years agoadditional write fixes, use rustyline 12.0.0 (#1876, #1901)
Mark [Sat, 22 Jul 2023 17:53:09 +0000 (11:53 -0600)]
additional write fixes, use rustyline 12.0.0 (#1876, #1901)

2 years agocorrect max_depth option (#1876)
Mark [Fri, 21 Jul 2023 21:05:27 +0000 (15:05 -0600)]
correct max_depth option (#1876)

2 years agoMerge pull request #1899 from triska/master
Mark Thom [Sat, 22 Jul 2023 05:26:20 +0000 (23:26 -0600)]
Merge pull request #1899 from triska/master

remove another !/0 which is now no longer necessary due to improved indexing

2 years agoremove another !/0 which is now no longer necessary due to improved indexing
Markus Triska [Sat, 22 Jul 2023 04:52:29 +0000 (06:52 +0200)]
remove another !/0 which is now no longer necessary due to improved indexing

2 years agocorrect max_depth option (#1876)
Mark [Fri, 21 Jul 2023 21:05:27 +0000 (15:05 -0600)]
correct max_depth option (#1876)

2 years agoremove now unnecessary cut in lists.pl
Mark [Fri, 21 Jul 2023 17:35:57 +0000 (11:35 -0600)]
remove now unnecessary cut in lists.pl

2 years agoimprove goal expansion and (',') interpretation error handling
Mark [Thu, 20 Jul 2023 20:27:10 +0000 (14:27 -0600)]
improve goal expansion and (',') interpretation error handling

2 years agoadd log10, hyperbolic tan and inverse hyperbolic tan functions (#1898)
Mark [Thu, 20 Jul 2023 18:33:23 +0000 (12:33 -0600)]
add log10, hyperbolic tan and inverse hyperbolic tan functions (#1898)

2 years agoadd EMIT_NEWLINE to add newlines to readline input only after query terms begin to...
Mark [Thu, 20 Jul 2023 15:39:06 +0000 (09:39 -0600)]
add EMIT_NEWLINE to add newlines to readline input only after query terms begin to be read (#1074, #1897)

2 years agocheck for unexpected EOF in get_to_eof (#1897)
Mark [Wed, 19 Jul 2023 23:13:47 +0000 (17:13 -0600)]
check for unexpected EOF in get_to_eof (#1897)

2 years agodereference TermWriteResult variables sooner in read_term_body (#1894)
Mark [Tue, 18 Jul 2023 21:39:51 +0000 (15:39 -0600)]
dereference TermWriteResult variables sooner in read_term_body (#1894)

2 years agoremove failing append choicepoint in atom_concat/3 special case (#1893)
Mark [Tue, 18 Jul 2023 20:44:02 +0000 (14:44 -0600)]
remove failing append choicepoint in atom_concat/3 special case (#1893)

2 years agoMerge pull request #1885 from mthom/setof_bagof_fixes
Mark Thom [Tue, 18 Jul 2023 18:35:10 +0000 (12:35 -0600)]
Merge pull request #1885 from mthom/setof_bagof_fixes

Fix group_by_variants/4 and keysort in setof/3

2 years agocall write_read_term_options if read_term_from_chars/3 succeeds by unifying Term...
Mark [Tue, 18 Jul 2023 18:15:20 +0000 (12:15 -0600)]
call write_read_term_options if read_term_from_chars/3 succeeds by unifying Term to end_of_file (#1892)

2 years agocatch errors thrown from tabling Worker (#1526, #1888)
Mark [Tue, 18 Jul 2023 18:10:27 +0000 (12:10 -0600)]
catch errors thrown from tabling Worker (#1526, #1888)

2 years agoremove read/{1,2} as a builtin, write read options upon EOF, throw better domain...
Mark [Mon, 17 Jul 2023 22:45:03 +0000 (16:45 -0600)]
remove read/{1,2} as a builtin, write read options upon EOF, throw better domain errors in parse_read_term_options/2

2 years agoadd specialized EOF handling for user input (#1892)
Mark [Mon, 17 Jul 2023 19:53:08 +0000 (13:53 -0600)]
add specialized EOF handling for user input (#1892)

2 years agoMerge branch 'read_term_eof_changes'
Mark [Mon, 17 Jul 2023 19:22:51 +0000 (13:22 -0600)]
Merge branch 'read_term_eof_changes'

2 years agoomit anonymous variables from read_term variable_names and singletons lists
Mark [Mon, 17 Jul 2023 04:22:44 +0000 (22:22 -0600)]
omit anonymous variables from read_term variable_names and singletons lists

2 years agodo a better job handling EOF in read_term (#1887)
Mark [Mon, 17 Jul 2023 02:42:40 +0000 (20:42 -0600)]
do a better job handling EOF in read_term (#1887)

2 years agoprint strings in tails of lists (#1890)
Mark [Mon, 17 Jul 2023 17:38:50 +0000 (11:38 -0600)]
print strings in tails of lists (#1890)

2 years agoMerge pull request #1891 from triska/initialization_goals
Mark Thom [Sun, 16 Jul 2023 16:26:13 +0000 (10:26 -0600)]
Merge pull request #1891 from triska/initialization_goals

ENHANCED: use newly available read_term_from_chars/3 for better errors

2 years agoENHANCED: use newly available read_term_from_chars/3 for better errors
Markus Triska [Sun, 16 Jul 2023 07:14:02 +0000 (09:14 +0200)]
ENHANCED: use newly available read_term_from_chars/3 for better errors

Examples, previously:

    $ scryer-prolog -g "member(X,Ls"
    ?-
    $ scryer-prolog -g "member(X,Ls)"
    member(_542,_543) causes: error(existence_error(procedure,member/2),member/2)
    ?-

Now:

    $ scryer-prolog -g "member(X,Ls"
    "member(X,Ls" cannot be read: error(syntax_error(incomplete_reduction),read_term_from_chars/3:0)
    $ scryer-prolog -g "member(X,Ls)"
    member(X,Ls) causes: error(existence_error(procedure,member/2),member/2)
    ?-

This also addresses #1185.

2 years agore-factor options handling of read_term into read_term_body (#1887)
Mark [Sun, 16 Jul 2023 03:52:54 +0000 (21:52 -0600)]
re-factor options handling of read_term into read_term_body (#1887)

2 years agogeneralize simple goal detection to fix call/N test failures in logtalk test suite
Mark [Sun, 16 Jul 2023 01:29:06 +0000 (19:29 -0600)]
generalize simple goal detection to fix call/N test failures in logtalk test suite

2 years agoadd read_term_from_chars/3 (#637)
Mark [Sat, 15 Jul 2023 17:20:20 +0000 (11:20 -0600)]
add read_term_from_chars/3 (#637)

2 years agouse double_quotes in write_error (#1886)
Mark [Sat, 15 Jul 2023 16:58:25 +0000 (10:58 -0600)]
use double_quotes in write_error (#1886)

2 years agoadd is_inbuilt check to err_on_builtin_overwrite (#1872)
Mark [Sat, 15 Jul 2023 16:44:00 +0000 (10:44 -0600)]
add is_inbuilt check to err_on_builtin_overwrite (#1872)

2 years agoeliminate call_with_inference_limit/3 leaks (#1300)
Mark [Sat, 15 Jul 2023 16:22:23 +0000 (10:22 -0600)]
eliminate call_with_inference_limit/3 leaks (#1300)

2 years agoadd unknown flag to set_prolog_flag and current_prolog_flag setof_bagof_fixes origin/setof_bagof_fixes
Mark [Sat, 15 Jul 2023 01:10:10 +0000 (19:10 -0600)]
add unknown flag to set_prolog_flag and current_prolog_flag

2 years agofix group_by_variants/4 and keysort in setof/3 (#1440, #1856)
Mark [Fri, 14 Jul 2023 23:01:46 +0000 (17:01 -0600)]
fix group_by_variants/4 and keysort in setof/3 (#1440, #1856)

2 years agoadd (:-)/1 and (:-)/2 to ClauseType::is_inbuilt (#1872)
Mark [Fri, 14 Jul 2023 18:44:25 +0000 (12:44 -0600)]
add (:-)/1 and (:-)/2 to ClauseType::is_inbuilt (#1872)

2 years agofix assert(a|z)/1 errors
Mark [Thu, 13 Jul 2023 23:12:05 +0000 (17:12 -0600)]
fix assert(a|z)/1 errors

2 years agoMerge pull request #1884 from triska/countall
Mark Thom [Thu, 13 Jul 2023 22:09:29 +0000 (16:09 -0600)]
Merge pull request #1884 from triska/countall

ADDED: countall/2, for compatibility with GNU Prolog.

2 years agoADDED: countall/2, for compatibility with GNU Prolog.
Markus Triska [Thu, 13 Jul 2023 21:08:13 +0000 (23:08 +0200)]
ADDED: countall/2, for compatibility with GNU Prolog.

Example:

    ?- countall(member(X, "abc"), N).
       N = 3.

2 years agothrow permission_error in compile_assert when attempting to assert a built-in (#1872)
Mark [Thu, 13 Jul 2023 21:03:26 +0000 (15:03 -0600)]
throw permission_error in compile_assert when attempting to assert a built-in (#1872)

2 years agoarith_eval_by_metacall may receive a stack variable
Mark [Thu, 13 Jul 2023 19:58:51 +0000 (13:58 -0600)]
arith_eval_by_metacall may receive a stack variable

2 years agocorrect peek_code/2, don't set stream position in peek functions
Mark [Thu, 13 Jul 2023 19:37:34 +0000 (13:37 -0600)]
correct peek_code/2, don't set stream position in peek functions

2 years agocorrect peek_byte/2 bugs (#1882)
Mark [Thu, 13 Jul 2023 18:23:20 +0000 (12:23 -0600)]
correct peek_byte/2 bugs (#1882)

2 years agoimprove ground/1 performance (#1389)
Mark [Thu, 13 Jul 2023 00:11:56 +0000 (18:11 -0600)]
improve ground/1 performance (#1389)

2 years agofix peek_byte/2 crash (#1882)
Mark [Wed, 12 Jul 2023 22:34:11 +0000 (16:34 -0600)]
fix peek_byte/2 crash (#1882)

2 years agoMerge pull request #1878 from mthom/lookahead_indexing
Mark Thom [Wed, 12 Jul 2023 22:21:06 +0000 (16:21 -0600)]
Merge pull request #1878 from mthom/lookahead_indexing

use lookahead to skip inapplicable clauses (#1028, #1502)

2 years agoENHANCED: improved determinism of member/2 lookahead_indexing origin/lookahead_indexing
Markus Triska [Wed, 12 Jul 2023 05:26:52 +0000 (07:26 +0200)]
ENHANCED: improved determinism of member/2

Example:

    ?- member(X, "abc").
    %@    X = a
    %@ ;  X = b
    %@ ;  X = c.

This addresses #750.

2 years agouse lookahead to skip inapplicable clauses (#1028, #1502)
Mark [Tue, 11 Jul 2023 23:59:53 +0000 (17:59 -0600)]
use lookahead to skip inapplicable clauses (#1028, #1502)

2 years agoremove unsafe unwrap in put_char (#1881)
Mark [Wed, 12 Jul 2023 20:24:20 +0000 (14:24 -0600)]
remove unsafe unwrap in put_char (#1881)

2 years agoemit stream aliases as permission error culprits whenever possible
Mark [Wed, 12 Jul 2023 18:17:06 +0000 (12:17 -0600)]
emit stream aliases as permission error culprits whenever possible

2 years agoRevert "Allow comparisons with stream terms"
Mark [Wed, 12 Jul 2023 17:44:45 +0000 (11:44 -0600)]
Revert "Allow comparisons with stream terms"

This reverts commit 076a75d1381926f83dd77150fdbda43969c168bf.

2 years agoRevert "add stream alias check to atom/1 (#1855)"
Mark [Wed, 12 Jul 2023 17:44:44 +0000 (11:44 -0600)]
Revert "add stream alias check to atom/1 (#1855)"

This reverts commit b746a8f9ab191da151ba06e2dd5fbe41f23382b2.

2 years agoRevert "add stream alias processing to atom_chars/2, atom_codes/2"
Mark [Wed, 12 Jul 2023 17:44:41 +0000 (11:44 -0600)]
Revert "add stream alias processing to atom_chars/2, atom_codes/2"

This reverts commit 811ff652097849bbb05e0e6f51c186d65cd2e236.

2 years agouse indexing functions to set num_cells in allocate_and_frame/or_frame (#1877)
Mark [Tue, 11 Jul 2023 19:43:34 +0000 (13:43 -0600)]
use indexing functions to set num_cells in allocate_and_frame/or_frame (#1877)

2 years agoclean commented code from disjuncts.rs
Mark [Mon, 10 Jul 2023 16:32:15 +0000 (10:32 -0600)]
clean commented code from disjuncts.rs

2 years agoremove errant debug_hook from read_and_match
Mark [Sun, 9 Jul 2023 16:30:30 +0000 (10:30 -0600)]
remove errant debug_hook from read_and_match

2 years agoDOC: new section on applications of Scryer Prolog
Markus Triska [Sun, 9 Jul 2023 12:24:21 +0000 (14:24 +0200)]
DOC: new section on applications of Scryer Prolog

This addresses an important aspect of #1777.

2 years agocorrect \\ to \, addressing #1865
Markus Triska [Sun, 9 Jul 2023 11:36:36 +0000 (13:36 +0200)]
correct \\ to \, addressing #1865

2 years agorefine EOF handling more (#1873)
Mark [Sun, 9 Jul 2023 07:53:40 +0000 (01:53 -0600)]
refine EOF handling more (#1873)

2 years agorefine EOF handling
Mark [Sun, 9 Jul 2023 04:25:30 +0000 (22:25 -0600)]
refine EOF handling

2 years agofollow EOF action after open_parsing_stream in get_char if stream at EOF
Mark [Sun, 9 Jul 2023 01:27:32 +0000 (19:27 -0600)]
follow EOF action after open_parsing_stream in get_char if stream at EOF

2 years agoclarify EOF error across stream types and predicates (#1867, #1870)
Mark [Sat, 8 Jul 2023 19:38:32 +0000 (13:38 -0600)]
clarify EOF error across stream types and predicates (#1867, #1870)

2 years agoMerge pull request #1869 from triska/master
Mark Thom [Sat, 8 Jul 2023 07:24:04 +0000 (01:24 -0600)]
Merge pull request #1869 from triska/master

print version more readably, addressing #1868

2 years agoprint version more readably, addressing #1868
Markus Triska [Sat, 8 Jul 2023 06:19:05 +0000 (08:19 +0200)]
print version more readably, addressing #1868

2 years agotreat unexpected EOF as incomplete reduction in bracketed_comment
Mark [Fri, 7 Jul 2023 19:04:27 +0000 (13:04 -0600)]
treat unexpected EOF as incomplete reduction in bracketed_comment

2 years agointerpret '\u{0}' as end_of_file in get_char/1
Mark [Fri, 7 Jul 2023 17:05:44 +0000 (11:05 -0600)]
interpret '\u{0}' as end_of_file in get_char/1

2 years agoadd stream alias processing to atom_chars/2, atom_codes/2
Mark [Fri, 7 Jul 2023 16:38:05 +0000 (10:38 -0600)]
add stream alias processing to atom_chars/2, atom_codes/2

2 years agoMerge pull request #1832 from aarroyoc/http-fixes
Mark Thom [Thu, 6 Jul 2023 22:30:56 +0000 (16:30 -0600)]
Merge pull request #1832 from aarroyoc/http-fixes

Multiple fixes for http libraries

2 years agoadd stream alias check to atom/1 (#1855)
Mark [Thu, 6 Jul 2023 17:38:12 +0000 (11:38 -0600)]
add stream alias check to atom/1 (#1855)

2 years agoadd scc_block to MachineState to avoid SCC cleanup terms being deallocated too early...
Mark [Thu, 6 Jul 2023 17:20:49 +0000 (11:20 -0600)]
add scc_block to MachineState to avoid SCC cleanup terms being deallocated too early (#1427)

2 years agocorrect heap_print.rs tests
Mark [Thu, 6 Jul 2023 00:11:09 +0000 (18:11 -0600)]
correct heap_print.rs tests

2 years agoshrink scope of control_entry_point catch, add CutPoint tag to printer
Mark [Wed, 5 Jul 2023 20:50:38 +0000 (14:50 -0600)]
shrink scope of control_entry_point catch, add CutPoint tag to printer

2 years agoMerge pull request #1864 from triska/double_quotes
Mark Thom [Wed, 5 Jul 2023 19:49:29 +0000 (13:49 -0600)]
Merge pull request #1864 from triska/double_quotes

make double_quotes write option not dependent on double_quotes flag

2 years agomake double_quotes write option not dependent on double_quotes flag
Markus Triska [Wed, 5 Jul 2023 19:22:49 +0000 (21:22 +0200)]
make double_quotes write option not dependent on double_quotes flag

This gives consistent results without depending on another flag.

2 years agoMerge pull request #1862 from mthom/iso_conformity_tests
Mark Thom [Wed, 5 Jul 2023 16:49:51 +0000 (10:49 -0600)]
Merge pull request #1862 from mthom/iso_conformity_tests

Revise iso_conformity_tests.pl to remove unnecessary spaces

2 years agoadd missing self.pos to peek_char slices (#1726)
Mark [Tue, 4 Jul 2023 23:44:27 +0000 (17:44 -0600)]
add missing self.pos to peek_char slices (#1726)

2 years agorevise iso_conformity_tests.pl in response to new ambiguity check of #1860 iso_conformity_tests origin/iso_conformity_tests
Mark [Tue, 4 Jul 2023 18:13:43 +0000 (12:13 -0600)]
revise iso_conformity_tests.pl in response to new ambiguity check of #1860

2 years agothrow lexer errors from devour_whitespace (#1778)
Mark [Tue, 4 Jul 2023 22:09:54 +0000 (16:09 -0600)]
throw lexer errors from devour_whitespace (#1778)

2 years agoMerge pull request #1861 from aarroyoc/fix-1855
Mark Thom [Tue, 4 Jul 2023 21:11:59 +0000 (15:11 -0600)]
Merge pull request #1861 from aarroyoc/fix-1855

Allow comparisons with stream terms

2 years agowiden CharReader buffer (#1859)
Mark [Tue, 4 Jul 2023 17:22:07 +0000 (11:22 -0600)]
widen CharReader buffer (#1859)

2 years agoAllow comparisons with stream terms
Adrián Arroyo Calle [Tue, 4 Jul 2023 15:33:48 +0000 (17:33 +0200)]
Allow comparisons with stream terms

2 years agoMerge pull request #1857 from triska/master
Mark Thom [Mon, 3 Jul 2023 20:05:16 +0000 (14:05 -0600)]
Merge pull request #1857 from triska/master

advertise newly achieved strong syntactic conformance: all current tests pass

2 years agoadvertise newly achieved strong syntactic conformance: all current tests pass
Markus Triska [Mon, 3 Jul 2023 20:04:26 +0000 (22:04 +0200)]
advertise newly achieved strong syntactic conformance: all current tests pass

This addresses an important aspect of #1777.

2 years agoMerge pull request #1850 from mthom/iso-conformity-tests
Mark Thom [Mon, 3 Jul 2023 19:53:41 +0000 (13:53 -0600)]
Merge pull request #1850 from mthom/iso-conformity-tests

Automate ISO syntax conformity tests

2 years agoupdate tests iso-conformity-tests origin/iso-conformity-tests
Mark [Mon, 3 Jul 2023 19:18:53 +0000 (13:18 -0600)]
update tests

2 years agocorrect tests #171 and #300
Mark [Mon, 3 Jul 2023 18:09:26 +0000 (12:09 -0600)]
correct tests #171 and #300

2 years agoadd double_quotes write option for printing to strings, enable it at toplevel
Mark [Mon, 3 Jul 2023 17:35:07 +0000 (11:35 -0600)]
add double_quotes write option for printing to strings, enable it at toplevel

2 years agocorrect ISO conformity test #185
Mark [Mon, 3 Jul 2023 17:34:41 +0000 (11:34 -0600)]
correct ISO conformity test #185

2 years agoadd iso-conformity-tests.pl to test suite
Mark [Sat, 1 Jul 2023 21:38:05 +0000 (15:38 -0600)]
add iso-conformity-tests.pl to test suite

2 years agocorrect initialization_goals misnomer in iso-conformity-tests.pl
Mark [Fri, 30 Jun 2023 00:03:43 +0000 (18:03 -0600)]
correct initialization_goals misnomer in iso-conformity-tests.pl

2 years agomake setup of test_166_167 pass
Mark [Fri, 30 Jun 2023 00:01:09 +0000 (18:01 -0600)]
make setup of test_166_167 pass

2 years agocheck ambiguity of "'" against tail if atom token is about to be quoted
Mark [Thu, 29 Jun 2023 23:59:25 +0000 (17:59 -0600)]
check ambiguity of "'" against tail if atom token is about to be quoted

2 years agoalways print a space between prefix operator and its operand
Mark [Thu, 29 Jun 2023 23:35:27 +0000 (17:35 -0600)]
always print a space between prefix operator and its operand

2 years agocorrect tests 259 and 304 of tests-pl/iso-conformity-tests.pl
Mark [Thu, 29 Jun 2023 20:57:29 +0000 (14:57 -0600)]
correct tests 259 and 304 of tests-pl/iso-conformity-tests.pl

2 years agointroduce tests-pl/iso-conformity-tests.pl
Mark [Thu, 29 Jun 2023 18:18:14 +0000 (12:18 -0600)]
introduce tests-pl/iso-conformity-tests.pl

2 years agoremoving residual debugging comments from format.pl
Mark [Sun, 2 Jul 2023 17:10:25 +0000 (11:10 -0600)]
removing residual debugging comments from format.pl

2 years agouse lexer to detect remaining layout in parse_number_from_string (#1773)
Mark [Fri, 30 Jun 2023 23:13:38 +0000 (17:13 -0600)]
use lexer to detect remaining layout in parse_number_from_string (#1773)

2 years agoMerge pull request #1854 from triska/needs_bracketing
Mark Thom [Fri, 30 Jun 2023 21:43:45 +0000 (15:43 -0600)]
Merge pull request #1854 from triska/needs_bracketing

remove now unneeded check

2 years agoremove now unneeded check
Markus Triska [Fri, 30 Jun 2023 20:14:00 +0000 (22:14 +0200)]
remove now unneeded check

2 years agocheck that F in needs_bracketing/2 is an atom
Mark [Fri, 30 Jun 2023 19:45:45 +0000 (13:45 -0600)]
check that F in needs_bracketing/2 is an atom

2 years agodo not enclose '(' as atom in brackets (#1487)
Mark [Fri, 30 Jun 2023 18:06:07 +0000 (12:06 -0600)]
do not enclose '(' as atom in brackets (#1487)

2 years agoMerge pull request #1852 from triska/needs_bracketing
Mark Thom [Fri, 30 Jun 2023 17:13:24 +0000 (11:13 -0600)]
Merge pull request #1852 from triska/needs_bracketing

Improvements to needs_bracketing/2

2 years agoremove unneeded case: only operator definitions should count, not quoting
Markus Triska [Fri, 30 Jun 2023 16:03:21 +0000 (18:03 +0200)]
remove unneeded case: only operator definitions should count, not quoting

2 years agoremove subsumed case: F == Value means Arity =:= 0, now considered above
Markus Triska [Fri, 30 Jun 2023 16:02:43 +0000 (18:02 +0200)]
remove subsumed case: F == Value means Arity =:= 0, now considered above