Did you know ... Search Documentation:
Title for pldoc(default)
Branch: development (switch to stable),
version to version

SWI-Prolog Changelog from version 9.3.20 to 9.3.21

[Mar 11 2025]

  • WASM: Fixed abort handling.
  • WASM: Fixed yieldable using Prolog.call() running in engine.
  • ENHANCED: trap/1: stop trapping direct catch. Do not trap the debugger for catch(SytemPred, _, _). Such calls are very unlikely interesting to the debugger.

[Mar 10 2025]

  • ENHANCED: logic to trace a call to a system predicate Consider system with a stack user <- meta <- system as a debug frame. For example, trace char_code/2 in the code below.
    p1 :- catch(char_code(_,_), error(_,_), fail).
  • FIXED: finish command of GUI debugger. This fix adds skip(Frame) to the possible replies from prolog_trace_interception/4 and deletes prolog_skip_frame/1.

[Mar 7 2025]

  • FIXED: prompt1/1 called in mode (-) must fail if there is no "first" prompt.

[Mar 6 2025]

  • ADDED: Prolog.call(): allow passing the goal using Prolog.Compound()
  • FIXED: Prolog.Compound() constructor
  • ADDED: wasm_query/1, support running a single query interactively.

[Mar 4 2025]

  • BUILD: Avoid CMake generating paths with double "/"
  • BUILD: Updated cmake_minimum_required to 3.10 as adviced in CMake 3.31

[Mar 3 2025]

  • FIXED: Handling skip in the gui tracer. Incorrectly detected that an exit was from a skipped frame. We could also consider to move this into the exit port, e.g., present the port as exit(skip).

    The GUI tracer can be simplified as process_trace_action() is dealing with more details of handling the user continuation.

  • CLEANUP: Remove restoring REDO port from tracePort() This is dealt with in the VM backtracing code and (thus) never reached.

[Mar 2 2025]

[Mar 1 2025]

[Feb 28 2025]

  • WASM: Rename shell to "tinker". Tool will be named "SWI-Tinker"

[Feb 27 2025]

  • WASM: More URL handling.
  • FIXED: PL_put_chars(): unregister atom when using PL_ATOM.
  • WASM: Support single character input from the user (get_code/1, etc.)
  • ADDED: prompt1/1 can retrieve current prompt using a variable.
  • BUILD: #1350 Auto-include utf8proc if documentation is requested.
  • WASM: Support include/1 from files loaded using a URL

[Feb 26 2025]

  • FIXED: Sandbox: declare distinct/1,2 as safe (uses tries).
  • WASM: Allow reusing a query in the shell.
  • WASM: Added options to Prolog.consult() This allows for Prolog.consult(file1, file2, ..., {module:"project"})
  • WASM: Give proper warning on ?- [user].
  • WASM: Added decoding of ansi hyperlink sequence

[Feb 25 2025]

[Feb 24 2025]

  • WASM: Added upload and download buttons for WASM shell.

[Feb 23 2025]

  • WASM: Simple debugger for the browser shell.
  • WASM: Added decoding of ANSI escape sequences
  • WASM: Prolog.call() provides nodebug option. Also add Prolog.Term() class that allows for creating terms from term handles or strings.
  • WASM: Split shell demo into multiple files.
  • WASM: Reorganised directory

[Feb 24 2025]

  • WASM: Fixed dealing with heartbeat events.

[Feb 23 2025]

  • DEBUG: Use swipl-web.js rather than swipl-bundle.js for debugging

[Feb 21 2025]

  • WASM: Minimally working Prolog tracer in the browser

[Feb 22 2025]

  • WASM: Fixed standard I/O flushing. Notably writing to user_error was flushed on a newline.

[Feb 21 2025]

  • WASM: Fixed Prolog.write()
  • ENHANCED: Error message when using WASM await/2 in synchronous query.
  • FIXED: We must discard foreign environments While unwinding an exception, before we discard a frame, which may call the foreign cleanup handler, we must discard newer foreign environments.
  • FIXED: Extended query solutions from int to int64_t Otherwise, PL_new_solution() is limited to 2G solutions.

[Feb 20 2025]

  • FIXED: PL_yield_address(): preserve foreign environment
  • FIXED: State handling using PL_yield_address().
  • FIXED: library(block) (SICStus emulation) warns about append/3. Reported by Peter Ludemann.
  • FIXED: wrap_predicate/4: possible double free after unwrapping The copy of the predicate held in the closure should not copy the lingering list and we must avoid lingering the wrapped supervisor as it becomes owned by the closure.

[Feb 7 2025]

  • ADDED: Yield based debugger support This patch introduces a large number of changes to the VM as well as the debugger code. It allows interacting with the Prolog debugger using yield, i.e., instead of calling a hook when a Prolog port is passed it makes PL_next_solution() return. The environment can examine the state, make calls on this Prolog engine and finally set how the session must be continued and resume PL_next_solution().

    The interaction is similar to prolog_trace_interception/4, used to drive the GUI debugger using callbacks. Given this, it becomes possible to write a debugger for the WASM version for using in the browser. This can either be a traditional console debugger or a graphical debugger similar to the native debugger.

    This patch reorganises notably the backtracking and exception handling code in the VM, splitting these large pieces of code into many VM helper functions. It also reorganises several parts of the builtin debugger to facilitate code reuse between the callback and yield based debuggers.

    This is a squash commit of the trace-yield-state branch.

[Feb 17 2025]

[Feb 18 2025]

  • CLEANUP: Delete VMI profiling code. As we have VMI functions and much better profiling tools this merely complicates the sources.

[Feb 14 2025]

  • MODIFIED: abort/0: disable debug mode.

Package semweb

[Feb 13 2025]

Package xpce

[Mar 10 2025]

  • TRACER: Fixed "finish" to use new skip(Frame) reply.

[Feb 12 2025]

  • FIXED: X11 version: paste Unicode text