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

SWI-Prolog Changelog from version 9.2.9 to 10.0.0

[Dec 3 2025]

  • CLEANUP: Remove traces of GNU readline

[Dec 2 2025]

  • BUILD: Include script to build gcc version on MacOS
  • PORT: Support older gcc and clang versions that do not provide __auto_type

[Nov 30 2025]

  • ENHANCED: On ELF systems that have objcopy, add the state as an ELF section. This makes the system a valid ELF executable on which all ELF tools work normally.
  • ADDED: qsave_program/2: option zip(true) to create a clean .zip file.
  • FIXED: #1414 crash in C_CUT due to reset clause pointer from undo/1.

[Nov 24 2025]

  • MODIFIED: PIP-0105: write_term/2 option max_text to exclude ellipsis. As we already exclude the quotes and escape sequences, excluding the ellipsis is more consistent. After remarks by Joachim Schimpf.
  • FIXED: #1411 Windows issue for handling max_text on UTF-16 pairs.
  • TEST: Relax thread queue timeout tests and provide more accurate failure feedback.

[Nov 23 2025]

  • FIXED: Save history for new directory using swipl-win
  • ENHANCED: On (Linux/Unix) systems with hot-pluggable CPU or running as virtual machines, the cpu_count Prolog flag should be set to the number of online processors (SC_NPROCESSORS_ONLN) instead of the configured maximum number (SC_NPROCESSORS_CONF). Using the online count avoids situations where cpu_count reflects offline or non-present CPUs. If SC_NPROCESSORS_ONLN is not defined by the system, we fall back to the old SWI-Prolog behaviour.

[Nov 21 2025]

  • BUILD: show options in generated file
  • MODIFIED: write_term/2: max_depth(+Depth) to use Unicode … If the encoding of the output supports Unicode. Otherwise the ASCII sequence ... is emitted.
  • ADDED: write_term/2: support max_text(+Length) for quoted output.

[Nov 20 2025]

  • ADDED: PIP-0105: write_term/2 support for max_text(+Length) Actually called text_max in the proposal. Considering all other options and flags are named `max_*`, I think this should change.

    This commit only implements this option for unquoted atoms and strings.

  • FIXED: with_tty_raw/1: kept lock on stream.
  • ADDED: PIP-0105: write_term/2 option truncated(-Bool). Bool is unified to true if the term has been truncated due to the max_depth option.
  • ADDED: PIP-0105 write_term/2 option portable(Bool)
  • DOC: Update CMAKE.md, section components
  • TEST: saved_states, disable timeout under MSYS2 (#1406) * TEST: saved_states, disable timeout under Windows

    On Windows, stream timeout only works for sockets. [Nov 19 2025]

  • DIST: Added packages/libedit/libedit to tar archive
  • ADDED: Using the option --home=dir, set SWI_HOME_DIR. This ensures that sub processes can access Prolog's home and, when calling Prolog, execute the same Prolog system.
  • TEST: Base saved-state tests on new prolog(Tool) option of process_create/3.
  • FIXED: Allow swipl -o exe -c input.pl to pass --home=dir option.

[Nov 18 2025]

  • PORT: Properly install runtime dependencies for MSVC build This now depends in CMake > 3.21 install() option RUNTIME_DEPENDENCY_SET

[Nov 17 2025]

  • PORT: Build swipl-win.exe under MSVC Now compiles cleanly. swipl.exe runs fine, including line editing. The GUI is unresponsive though.

[Nov 14 2025]

  • FIXED: format/1-3: reset last tab stop on a newline. Spotted by Joachim Schimpf with the PIP tests.
  • ADDED: ansi_format/4, formatting with colours to a stream.
  • PORT: MSVC
  • MODIFIED: format/2 handling of non-list arguments Now, the second argument is only considered a single argument if it is not [] or [_|_]. Notable partial lists or lists not ending in [] are now threaded as (invalid) argument list.
  • ENHANCED: Errors for arithmetic expression [Code] if list holds no single code.
  • PORT: MSVC compatibility.
  • TEST: Fixed test for format/2 `~6s`.
  • DOC: format and friends. Move documentation of deprecated writef/2 and friends to the library documentation. Updated the format/1-3 documentation.
  • PIP: PIP-0110: make `~<n>s` emit padding if text is too short.

[Nov 11 2025]

  • TEST: Use swipl.bat for testing saved states on Windows. 1. allows for "external" swipl.bat under Windows (see swipl.sh in l. 133)
    1. invokes saved state with -x if swipl.bat is used

[Nov 13 2025]

  • PORT: Work around broken MSVC
  • TEST: PIP-0110: added PIP format/2 tests.
  • COMPAT: Extended ECLiPSe test driver to accept should_output
  • MODIFIED: PIP-0110: format/2 using ~N to ignore the argument. Most implementations ignore the argument. Others interpret it inconsistently. New code should use ~N~2n as replacement for ~3N.
  • MODIFIED: PIP-0110: distributing extra spaces over ~t Used to distribute these spaces from the middle. Now distributes them from the right, compliant with SICStus and ECLiPSe.
  • ADDED: PIP-0110: format/2 format specifier F. This is like f, but using uppercase letters for non-normal floats.
  • PIP: PIP-0110: format/2: ~a to only accept atoms and compact strings.
  • PIP: PIP-0110 (format) compatibility: handle expressions for *
  • PIP: PIP-0110: format/2: ~a to only accept atoms and compact strings.
  • PIP: PIP-0110 (format) compatibility: handle expressions for *

[Nov 12 2025]

  • RELEASE: Merged development version
  • PORT: Better MacOS Homebrew support

[Nov 11 2025]

  • FIXED: Typo in updated history code. Caused !/0 to be redefined ...

[Nov 7 2025]

  • FIXED: !<num> history handling if command contains a . in the middle.

[Nov 5 2025]

[Nov 3 2025]

  • MODIFIED: Use bool types for profiling API Should have low impact. Used by xpce.
  • FIXED: Disable Epilog if threads in single threaded version.
  • MODIFIED: halt/1: forward to main thread. If halt/1 is initiated from a thread other than main, main is signalled to terminate the process. If the main thread does not do so within the time specified by the Prolog flag halt_grace_time (default 1 second), the process is forcefully terminated.

[Nov 2 2025]

  • MODIFIED: Commandline history handling. Comandline history handling used a double administration, both saving command as Prolog facts and in the commandline editor. Now the commandline editor is in charge. Visible changes to the user:
    • If library(editline) is not available, there is no history.
    • Without any settings, the history depth is 100. The fact that the history is enabled is shows using numbers in the prompt.
    • Substitution using e.g., `!!`, `!<num>`, etc. are always enabled.
    • Setting the Prolog flag history to 0 or false disables the history. An integer value sets the depth.

[Oct 27 2025]

  • COMPAT: Use new message_action/2
  • ADDED: message_action/2 hook. This separates side effects on messages from printing messages, allowing side effects to take place even if an earlier print hook suppresses the message.
  • FIXED: Use library broadcast to tell other components of modified break-points.
  • TEST: Do not run the "unprotected" tests if protect_static_code is set.
  • FIXED: '$clause_from_source'/4, used for setting break-points.

[Oct 26 2025]

  • DOC: Do not run test_installation twice
  • ENHANCED: xref_source/2: emit warning on late meta_predicate/1 This directive must appear before the predicate is being used (called).

[Oct 24 2025]

  • PPA: Added Ubuntu 25.10 (Questing Quokka)
  • FIXED: Install of non-qlf json compatibility wrappers.
  • ADDED: packages/json

[Oct 23 2025]

[Oct 21 2025]

  • DOC: term_size/2: cells are always 8 bit in recent versions.

[Oct 20 2025]

  • ENHANCED: Messages for managing spy points.

[Oct 14 2025]

  • ENHANCED: listing/0,1,2 to respect the terminal width. If the output is a terminal, tty_size/2 is used to determine the line width.

[Oct 12 2025]

[Oct 7 2025]

  • ADDED: Implement read_term/1: implement reading attributed and labeled terms. This patch supports Var{Attr: Value, ...} if the Prolog flag var_tag is set to attvar. This allows reading terms with attributes. It also supports labeled subterms that allows to read terms that are directed graphs rather than trees. This includes cyclic terms. For this we reserve the attributed =. For example
    ?- A = X{= : f(X)}.

    Binds A to a cyclic term equivalent to executing X = f(X). This is part of ongoing discussions in the PIP working group. It is currently implemented by ECLiPSe and SWI-Prolog.

[Oct 6 2025]

  • DOC: Updates documentation for using of # anonymous dicts.
  • TEST: Update tests for use of # anonymous dicts
  • MODIFIED: Dict.put(Path, Value): create new dicts as #{...}.
  • MODIFIED: select_dict/3 handling of # tag The # tag matches any tag at the other end and the dict holding the remainder has the # tag.

[Oct 3 2025]

  • MODIFIED: write_term/2 using attributes(write) This now writes Var{Att1: Value1, Att2: Value2, ...}, which is valid syntax for read_term/2 if the Prolog flag var_tag is attvar.

[Oct 2 2025]

  • ADDED: read_term/2 and friends to respect the new var_tag flag.
  • ADDED: Prolog flag var_tag Defines how Var{...} terms are interpreted. This commit only implements setting and getting the flag.

[Oct 1 2025]

  • MODIFIED: :</2 and >:</2: match # tag The tag # matches any tag on the other side without instantiating the tag.

[Oct 8 2025]

[Oct 2 2025]

  • FIXED: Exception details from '$tmp_file_stream'/4

[Oct 1 2025]

  • ERROR: Domain error: `encoding' expected, found `txt' The txt does not make sense * CLEANUP: Fixed more compilation warnings when using -O3

[Sep 30 2025]

  • BUILD: Fix PGO building for AppleClang
  • BUILD: Fix PGO build for Clang. This now does optimize.
  • BUILD: Changed default optimization for gcc to -O3 Earlier tests showed no noticeable difference, but using gcc-15 and setjmp()/longjmp out of the way we get about 15% improvement.
  • SANDBOX: Declare string quasi quotation syntax as safe.

[Sep 29 2025]

  • TEST: Fix format_time/3 tests by setting correct timezone.
  • WASM: Set defaults for best performant build.
  • ENHANCED: Move setjmp() out of the VM main function Using setjmp() harms register allocation, which slows down the VM. Some data points: Clang: 6% (Clang-17 on Apple M1 as well as Clang-20 on AMD3950X), GCC: 13% (GCC-15 on AMD3950X), WASM: 35% (Emscripten 4.0.15 on Node.js 22.19 on AMD3950X). MinGW-14: 18% (Windows binary running on AMD3950X under Wine).
  • TEST: Fixed ration number writing test to work regardless of flags. Test failed when run with rational_syntax set to natural.

[Sep 28 2025]

  • ENHANCED: Get rid of setjmp/longjmp() in PL_next_solutions() This improves performance by about 12%. It does make a couple of scenarios for stack overflow handling impossible though. This patch merely introduces O_THROW as C macro to enable/disable this.

[Sep 26 2025]

  • WASM: Make setting CFLAGS and LDFLAGS in BuildType.cmake work The if/elseif/... selection triggered on Clang.
  • WASM: Compile VM using -O2 This produces a smaller binary with slightly better performance.
  • WASM: When using a monolithic PL_next_solution(), use -O1 in Debug mode Otherwise local variables with non-overlapping scope are not merge, causing an Emscripten compiler error
  • WASM: Do not build swipl-win Also cleanup handling platform-dependent cmake options

[Sep 25 2025]

[Sep 24 2025]

  • FIXED: When a REPL loop receives the halt/0,1 exception, make it return. Before, if non-threaded or the REPL loop runs in the main thread, terminate the process. Otherwise halt/0 was ignored. The behaviour for the main thread is still the same, but prolog/0 succeeds in other threads if the thread calls halt/0.

    Possibly we should add a flag to control this behaviour, i.e. whether or not halt/0 inside prolog/0 terminates the process or merely the REPL loop.

[Sep 22 2025]

  • DOC: Update most links to swipl-win and related functionality
  • PORT: Replace incomplete function pointer types by void* C11 and later do not allow for foreign_t (*function)().

[Sep 21 2025]

  • CLEANUP: Delete obolete components - snap build instructions - packages/swipl-win (Qt console) - Various files supporting this.
  • CLEANUP: Deletes Qt console.
  • CLEANUP: Remove old swipl-win.exe code.
  • PORT: Carefully detect that git is the sane thing on MacOS. With help from @ridgeworks
  • FIXED: Update library(threadutil) for Epilog support.
  • STYLE: dark theme: avoid navy_blue color for global predicates.

[Sep 20 2025]

  • ENHANCED: Allow set_stream(S, alias(user_input)) without locking S.

[Sep 16 2025]

  • CLEANUP: Synchronise handling of the tty_control flag between Windows and Unix. Needs further cleanup, notably a separate definition of the indexes for the boolean flags.

[Sep 15 2025]

  • MODIFIED: Moved enabling ansi colors on the Windows console to be used only with tty control.
  • CLEANUP: Remove non-functioning PL_wait_for_console_input() This fixes Windows console input without the commandline editor.
  • FIXED: Handle command line argument --foreign=copy
  • FIXED: qsave_program/2 determinism.

[Sep 13 2025]

  • FIXED: Parse -<base>'<digits> Reported by Joachim Schimpf. Thanks.
  • MODIFIED: MacOS: change default working dir of the app to ~/Prolog ~/Documents is subject to TCC (Transparency, Consent, and Control), showing a confirm dialog on any file access until we get SWI-Prolog signed.

[Sep 10 2025]

[Sep 3 2025]

  • CLEANUP: Avoid unused function warning when compiling for Windows without thraeds.
  • FIXED: #1381 building single threaded version for Windows.
  • TEST: term_hash/2,4: WASM produces different results due to 32 bit limit.

[Sep 2 2025]

  • FIXED: Starting interactive mode failed if the history cannot be initialised. This prevents running Prolog interactively if there is no HOME directory or the config directories and files cannot be created.

[Sep 1 2025]

  • FIXED: translate_bindings/5 looped As CA1_LPROC arguments were resolved against the head module rather than the body context, this predicate called itself rather than the local defininion in toplevel.pl.

    This predicate is used by Pengines and SWISH.

[Aug 25 2025]

  • TEST: term_hash/2 for LibBF on little endian machines.
  • TEST: Update term_hash/2 tests for big endian results.
  • MODIFIED: Removed '$open_xterm'/5 This predicate allowed for using the xterm application to provide a console for a background thread. This is now covered by Epilog. Also, xterm is no longer widely supported.
  • TEST: term_hash/2: hash depends on GMP vs LibBF. Handle and document.
  • THEME: dark: darker colour for unused import background

[Aug 24 2025]

  • FIXED: WASM: Avoid leaning strings in Prolog.get_chars()
  • WASM: Added Prolog.__with_strack_strings() This interface allows for cleanup of temporary strings. It provides a WASM version of PL_STRINGS_MARK() ... PL_STRINGS_RELEASE()

[Aug 22 2025]

  • FIXED: edit/1 to merge all locations considered identical.

[Aug 20 2025]

  • TEST: Fixed test for simplified ansi_format/3.
  • FIXED: Inherit the Prolog flag max_integer_size in new threads.

[Aug 7 2025]

  • MODIFIED: term_hash/2: extended range As tagged integers now have the same range on all platforms, the range for term_hash/2 has been extended to the max tagged integer.

    You can get the old hash by masking the lower 24 bits.

  • BUG: The test values for big endian are not updated as I do not have access to big endian hardware right now. Please submit the corrected values. See tests/core/test_hash.pl.

[Aug 19 2025]

  • ADDED: set_thread/2 Generic interface for modifying thread properties. Currently controls the debug status of a thread. Will absorb most other properties.
  • DOC: thread_property/2 did not document the debug property.

[Aug 7 2025]

  • FIXED: swipl-win: print backtrace on uncaught exceptions in Epilog.
  • FIXED: Simplification in 057d69387e240ebf90af8f9c9d5783c5203887fa was wrong.
  • FIXED: #1384 message printing is disabled after an uncaught exception inside a transation Assert and erase listen inconsistently to P_TRANSACT, causing a clause for thread_message_hook/3 to remain.

[Aug 5 2025]

  • THEME: Support dark theme in selections in text objects.

[Aug 3 2025]

  • DOC: Cmake font options

[Aug 2 2025]

  • THEME: Redefine graphical.selected_foreground and graphical.selected_background

[Aug 1 2025]

  • THEME: dark: fixes for GUI tracer breakpoints and redo ports.
  • ENHANCED: ls/0,1: create hyperlinks for Prolog source files. File presentation style can be tweaked using the shell:file_style/2 hook.
  • THEME: dark theme to improve readability of => rule guards.

[Jul 31 2025]

  • BUILD: Avoid relying on environment variables for xpce steps Somehow, using cmake --env does not work correctly on all platforms. This patch adds and uses an -DSDL_VIDEO_DRIVER=dummy commandline option for the Prolog build steps.

[Jul 30 2025]

  • FIXED: incorrect inclusion of cluster data in default text profile data First attempt at new format incorrectly tried to merge callee data into predicate overall times
  • FIXED: predicate_label/2: support [] as functor name
  • ADDED: prolog_trace_interception/4: support halt Halting from the callback no longer works since halt/1 is implemented as an exception. This caused "Exit Prolog" from the GUI debugger to be ignored.
  • THEME: Make quasi-quotation syntax readable in dark theme [no ci]

[Jul 28 2025]

  • UNICODE: Updated library(unicode/blocks) Updated to version 16.0.0 of the Unicode standard.
  • THEME: dark theme to fix up cycle menus.

[Jul 25 2025]

  • ENHANCED: Update profile/1,2 text output Enhanced default version of show_profile/1
  • FIXED: Prevent building the pack.pl app when there is no library_pack The library is build conditionally starting from 2793ca547c3b185f50d2ce803c582874fc583b70.

    Signed-off-by: Nicola Vetrini <nicola.vetrini@bugseng.com>

[Jul 24 2025]

  • PPA: Fixed plucky version to include the GUI
  • THEME: dark: improve colour for option_name and SSU rule guard.
  • FIXED: prolog_read_source_term/4L respect :- encoding(+Enc)
  • FIXED: Avoid Unicode characters in otherwise ASCII files Files used Unicode variations on ' and -

[Jul 23 2025]

  • FIXED: swipl-win installation for MacOS when not creating a bundle.
  • PPA: Updated scripts/make-ppa to setup building without gui for older distros

[Jul 22 2025]

  • ADDED: Empty light theme file.

[Jul 21 2025]

  • FIXED: Code generation for unification moved to the head. Minimal test case: p(X, Y) :- X = f(Y), Y = a.. Issue occurs if a variable is accessed (Y) before its unification must be moved to the head.
  • FIXED: Building; typo in prolog_pack/http fix
  • BUILD: Avoid installing some libraries with missing dependencies - Do not install library(prolog_pack) if http support is missing.
    • Do not install SICStus timeout compatibility if multi-threading is not enabled.

[Jul 20 2025]

[Jul 19 2025]

  • THEME: Dark theme declarations for class list_browser and the profiler. Requires the SDL version of xpce.

[Jul 18 2025]

  • ENHANCED: Improve dark theme Only applies with new SDL based xpce

[Jul 17 2025]

  • PORT: Fixed MacOS installer to include transitive dependencies and fix the @rpath.

[Jul 16 2025]

  • BUILD: Fixed PGO build with -DEPILOG=ON
  • BUILD: Ensure proper GUI environment for building the manual.

[Jul 10 2025]

  • ADDED: Support -Dtheme=<theme>

[Jul 6 2025]

  • PORT: Update scripts/macos-deps.sh Update most ports, add SDL3, SDL3_image, cairo and pango.

[Jul 10 2025]

  • ADDED: Working directory handling for MacOS app.

[Jul 9 2025]

  • PORT: Create a MacOS bundle based on Epilog.

[Jul 7 2025]

  • ENHANCED: interactor/0,1: use epilog when available. In the long term we will drop xterm support as well as native win32 support.

[Jul 5 2025]

  • EPILOG: Deal with --win-app option in a way that also supports epilog.
  • ENHANCED: Remove thread context for threads running the REPL loop. This avoids the complicating [Thread xyz] note on messages in alternate consoles such as Epilog or SSH shells.
  • ADDED: Prolog flag toplevel_thread. This flag is true in a thread that is currently running a REPL loop.
  • FIXED: Edit from PceEmacs using popup could raise an error. E.g. ERROR: is_file_spec/1: No rule matches prolog_edit:is_file_spec(20_625_830)

[Jul 4 2025]

  • BUILD: Add CMake -DEPILOG option This option prepares the core for the upcoming Epilog configuration. It must be used with the sdl branch of packages/xpce. Effect:
    • Drop library(readline)
    • Drop swipl-win, either Windows version or Qt version.
    • Create a new swipl-win that is a copy of swipl that sets the epilog flag. Depending on the platform some more additions may be needed.

[Jul 3 2025]

  • PORT: Find MinGW DLL dependencies more dynamically This provides two CMake functions to find the direct and indirect MinGW DLLs that must be included into the distribution
  • ADDED: Allow storing the tty screen size with a stream. This is required for environments where we use a non-tty I/O device such as a pipe or socket while there is a notion of a tty size. Currently used for Epilog on Windows.

[Jul 1 2025]

  • MODIFIED: print_term/2: print dict tags and compound functors using the current write options. Both used to be printed hardwired using ~q (quoted).
  • FIXED: When rational_syntax is natural, write /(Int,Number) with spaces. This ensures such a term is not read as a rational number.

[Jun 30 2025]

[Jun 28 2025]

  • PORT: Avoid errors on sharing violations.

[Jun 26 2025]

  • FIXED: Windows: comparing string equality with surrogate pairs Comparing strings with surrogate pairs could signal inequality while the strings are equal.
  • FIXED: Unification to chars or codes of wchar_t text on Windows.

[Jun 25 2025]

  • PORT: Discontinue 32-bit windows builds.

[Jun 23 2025]

  • PORT: Support library(editline) (libedit) on Windows. This provides cross-platform commandline editing with Prolog-sensitive completion.

[Jun 25 2025]

  • ADDED: Windows: tty_size/2 to also work on Windows consoles.

[Jun 23 2025]

  • WASM: Deal with new PL_prompt_string() API

[Jun 22 2025]

  • MODIFIED: Signature for PL_promot_string() and PL_prompt_next() These API functions now use the Prolog stream as argument to facilitate better support for Windows.

[Jun 19 2025]

  • ADDED: IOSTREAM* control message to get the Windows HANDLE
  • FIXED: wait_for_input/3: use Swinsock() from pl-stream.c rather than a local macro This ensures proper error messages if the input is not a socket.
  • MODIFIED: PL_dispatch() and friends now use IOSTREAM* instead of int. This is a first step to merge simultaneous handling of console outout and GUI dispatching for POSIX systems and Windows to a common design.

[Jun 18 2025]

  • WINE: Waiting for windows console input now works for wine.
  • PORT: Make installing INDEX.pl files work on Windows. Concurrency may cause sharing violations. This patch retries renaming the index file several times.

[Jun 17 2025]

  • FIXED: Possible early reclaim of closure blob after unwrapping a predicate. PL_unregister_atom() was called twice.

[Jun 11 2025]

  • ADDED: Incorporate epilog into the toplevel. These patches prepare for the XPCE based swipl-win. May be started by using the sdl branch of xpce and run as
    swipl -Depilog [arg ...]

[Jun 7 2025]

  • ADDED: '$run_state'/1 to query the current run state Can be used to detect code is running as part of the cleanup hooks.

[May 28 2025]

  • BUILD: Use SDL_VIDEODRIVER=dummy for running Prolog steps This makes sure the new SDL based xpce does not try to open graphics and is harmless on other targets.

[May 27 2025]

  • FIXED: Move swipl-win history support to library(win_menu). This library is loaded as source and thus conditional compilation applies. library(prolog_history) is compiled to .qlf. Now the code is also where it belongs.
  • FIXED: When generating _X variable names, avoid query variable names. Consider the below example by Jan Burse. Using _A in the answer is at least confusing. We must not only skip variable names that appear in the projection, but also variable names from the query that are not in the projection.
    ?- length(L,2), f(L) = R, S = [_A].
    L = [_A, _B],
    R = f([_A, _B]),
    S = [_A].

[May 24 2025]

  • FIXED: Terminal REPL loop using thread_exit(io_error) on an io_error during read.
  • FIXED: Termination of a REPL loop due to error state of the streams This did not properly close the query, crashing the system in the thread cleanup.
  • FIXED: thread_join/2: could leave L_THREAD mutex locked on error.

[May 23 2025]

  • ADDED: Allow thread_signal/2 to raise native signals by number. This can be used to raise e.g. SIGINT in a thread to debug it.

[May 22 2025]

[May 17 2025]

  • FIXED: write/1,2 to take rational number syntax from module user. Before, only write_term/2,3 supported "natural" rational number syntax.

[May 16 2025]

  • FIXED: Make the stream macros Suser_input safe when called from a non-Prolog thread Called from a non-Prolog thread caused these macros to crash. They now return NULL. The main-thread I/O can be obtained using Sinput, Soutput or Serror.

[May 2 2025]

  • ADDED: Allow hooking into the terminal link generation.
  • FIXED: Various details for the sys app
  • ADDED: Prolog flag linux
  • FIXED: QLF format to store references to predicates in the current module by functor. Otherwise, if a predicate is imported the clause will point at the import location, bypassing the predicate resolution that happens when loading the source.

[May 1 2025]

  • BUILD: Avoid cmake warnings.

[Apr 30 2025]

  • ENHANCED: jiti_list/0,1 - Provide collision stats - Order predicates alphabetically - Use tty hyperlinks when supported to allow jumping to the definition
  • FIXED: ansi_hyperlink/3: Fix position logic Make sure the column admin is not updated when writing the escape sequences. This allows mixing with format/1-3 tag specifiers.

[May 1 2025]

  • ENHANCED: Make sure that small clause index tables have no collisions.
  • ENHANCED: Use Fibonacci hashing for clause indexes.

[Apr 30 2025]

  • ENHANCED: Index performance on common arguments. Given a predicate with many clauses that has one or more arguments with only a few possible values and (thus) many clauses in the hash buckets for each of these values force fast failure when using a query with a value that does not appear in that argument.

    For example, suppose we have a business database that records the legal status in one of the columns (arguments). A query with a non-existing lega status should fail quickly. In the old system, the small number of values could easily lead to a hash colission, causing the system to try all clauses with the legal status of the collision.

    This issue was reported by Abramo Bagnara

  • FIXED: #1364 nb_set_to_list/2 could skip elements.

[Apr 29 2025]

[Apr 28 2025]

[Apr 25 2025]

  • ENHANCED: Windows: use native fonts for bold and support bold+underlined.
  • ADDED: Freedesktop.org Desktop integration files. This patch adds a directory desktop with icons and desktop integration files. A particular version can be activated as desktop application using
    swipl sys desktop [--global] install

    The activation canbe removed using

    swipl sys desktop [--global] remove
  • ADDED: Windows swipl-win.exe: support underlined fonts Support \e[4m to print underlined text.

[Apr 23 2025]

  • ADDED: Windows: swipl-win.exe : support hyperlinks. This patch enables terminal escape sequences to embed hyperlinks. file:// links are then mapped to edit/1 and other links are opened in the browser.

    This patch also fixes several issues and provides cleanup to the swipl-win.exe console code.

  • FIXED: Report correct number of clauses when loading .qlf files Reported 0 (zero) clauses for all .qlf files.
  • FIXED: ?- edit(file('myname.pl')). to create a new file.
  • FIXED: Do not precompile several files This patch stops precompiling the libraries win_menu, threadutil and check_installation. The sources are full of conditional compilation that also depends whether or not swipl or swipl-win is started.

    Using runtime conditionals is possible, but would lead to many undefined predicate warnings.

  • FIXED: Create menu in Windows and Qt consoles. Broken due to conditional compilation that excluded the call to init_win_menus/0 from the .qlf file.
  • BUILD: prohibit building in the source directory.

[Apr 22 2025]

  • TEST: Include clpfd test with tabling.
  • DOC: Constraints and tabling

[Apr 21 2025]

  • TEST: Merge XSB attributed variable tests. This updates several of the tests, documents what tests cannot be executed due to incompatibilities and extends the XSB dialect emulation to deal with a later part of the attributed variable interface.

    The tests both deal with basic attribute handling and with (simple) tabling that involves attributes.

[Apr 22 2025]

  • FIXED: Support attributed variables in "fastheap" terms. These are used by tabling and delimited continuations.

[Apr 21 2025]

[Apr 18 2025]

  • XSB: Added basic attributed handling to emulation Library machine now exports get_attr/3, put_attr/3, del_attr/2 and install_verify_attribute_handler/4.
  • ADDED: library(prolog_profile): Prolog flags for defaults - profile_ports provides the default "mode", now true - profile_sample_rate provides the default sample rate (200)
  • DOC: clause/3: describe properties of clause references.
  • DOC: retractall/1 and logical update view section.
  • DOC: Moved some sections in the "Database" section of the manual.
  • BUILD: Better support for cmake < 3.20
  • PPA: Updated releases - Added Plucky Puffin (25.04) - Removed Focal Fossa (20.04) and Bionic Beaver (18.04)

    The latter two fail to build the Janus interface due to too old Python versions.

[Apr 14 2025]

[Apr 17 2025]

  • FIXED: Allow building with installed .QLF files when the VM changes. A VM mismatch raised a fatal error during boot. This is now relaxed to a normal exception.

[Apr 11 2025]

  • ADDED: Partial support for attributed variables in tries. This first step deals with inserting and generating. Trie compilation is not yet supported (crashes on unexpected key in the trie).

[Apr 17 2025]

  • FIXED: swipl qlf app: report incompatible .qlf files

[Apr 15 2025]

  • BUILD: Provide additional .qlf dependencies.
  • FIXED: swipl qlf app: dependency warnings and clean subcommand

[Apr 14 2025]

[Apr 10 2025]

  • INSTALL: Enable compiling .qlf files by default.
  • ENHANCED: swipl qlf app - info:
    • by default list all info - list:
    • add -u (--update) to only list out-of-data .qlf files
    • Produce machine format if output is not a terminal.
  • ENHANCED: Add macro expansion dependencies to .qlf files.
  • ADDED: swipl qlf info to accept multiple files.
  • ENHANCED: source_file_property/2 performance Speedup source_file_property(File, load_context(...)).
  • ENHANCED: Distinguish different file dependencies in .qlf files.

[Apr 9 2025]

  • ENHANCED: qlf file record included files These are also shown by
    swipl qlf info -s <file.qlf>
  • ENHANCED: Record included files in .qlf files with path translation.
  • FIXED: source_file_property/2 to work without sources.
  • FIXED: qlf_make/0 for out-of-date computation for aggregate .qlf files.
  • FIXED: Allow for discontiguous autoload/1 and autoload/2 directives.

[Apr 8 2025]

  • FIXED: dicts_to_compounds/4 if dicts have non-atom tags.
  • DOC: Singleton section was outdated. After comment by Jan Burse.

[Apr 7 2025]

  • PORT: Deal with dropped support for partial literals in phrase/2,3
  • MODIFIED: ISO: phrase/2,3: do not allow for partial lists as terminal
  • FIXED: WASM: Missing (chr) dependency caused build to fail.

[Apr 5 2025]

  • WASM: Added table for mapping HTML attribute names to DOM attributes.

[Apr 4 2025]

  • FIXED: prolog_load_context/2 for file to work correctly for .qlf.
  • FIXED: Only emit hyperlinks if hyperlink_term is true.

[Apr 3 2025]

  • ADDED: Start a new library(dom) based on html//1
  • MODIFIED: WASM: Move library(dom) to the dialect tau. We plan on an alternative library(dom). As a consequence, we move the Tau emulation library to the newly added Tau support in SWI-Prolog's dialect support.
  • FIXED: library(dom) set_attr/3: allow for atoms as values.

[Apr 2 2025]

  • BUILD: Support cmake < 3.20
  • FIXED: Using tabling when configured for debugging with autoloading disabled.
  • WASM: Enhanced error message when evaluating :=/2
  • FIXED: Clear FR_SKIPPED after skip/up in yield-based debugger.
  • FIXED: continue in trace mode after hitting a spy point. This was broken when using Prolog defined tracing in recent rewrites.
  • FIXED: Retrieving source info for Head --> "terminal", ...

[Apr 1 2025]

  • DEBUG: Attempt to improve visible trace points in the debugger.

[Mar 31 2025]

[Mar 30 2025]

  • ADDED: WASM: Prolog.promise_event()
  • WASM: bind/4 can now handling JavaScript objects without using the database
  • WASM: Updated bind.html demo.

[Mar 29 2025]

  • ADDED: Complete the Tau-Prolog compatibility library(dom).

[Mar 30 2025]

  • ADDED: WASM: Allow for nested #(Value)

[Mar 29 2025]

  • WASM: Prolog.bind(): added options.
  • BUILD: Install pldoc/hooks.pl instead of the .qlf file This is an include file that is used by the web server to customise PlDoc.

[Mar 27 2025]

[Mar 26 2025]

  • ADDED: Support access to public predicates for library indexes
  • ADDED: xref_public_list/2: get information from library INDEX.pl Using the INDEX.pl file provides a fast and simple way to get the library exports and meta-predicate information. Still need to deal with public predicates.
  • MODIFIED: INDEX.pl files. Thes files used to contain
    • index(Name, Arity, Module, File)

    This is now modified to

    • index(Head, Module, File)

    Where Head contains (where known) the mode and/or meta-predicate indicators. The index files now also contain the op(Pri,Type,Name) terms from the export list.

    This provides faster and simpler access to meta-predicate and operator relations between modules.

  • FIXED: edit/1 using edit(file(File)).
  • FIXED: edit/1: find e.g. library(lists) if only qlf files are

installed.

[Mar 25 2025]

  • ADDED: prolog_colourise_term/4: option current_variable(Name) This causes the marking to mark the named variable with the class current_variable.
  • WASM: Prolog.consult(): added engine:true option. This allows loading files to proceed asynchronously.

[Mar 24 2025]

  • ADDED: xref_source/2: stream(In) option This allows processing arbitrary data.
  • WASM: Do not install the package build tools.
  • ADDED: qlf app swipl qlf info -e file.qlf Show exports of the .qlf file.
  • ENHANCED: library(prolog_xref) without sources Get exports from .qlf files.

[Mar 23 2025]

  • MODIFIED: edit/1: use dicts for representing (partial) locations. As a result, hooks info the editing infrastructure need to be updated.
  • ENHANCED: edit/1 - Feedback on locations - Code simplification and modernizing

[Mar 22 2025]

[Mar 21 2025]

  • DOC: Update CMAKE.md to include instructions on Python installation Added a list of the options useful for installing Janus

[Mar 20 2025]

  • DOC: install with symlinks

[Mar 21 2025]

  • WASM: Use lz4 compression for data file.
  • WASM: Demo server to serve library sources.
  • WASM: Support library(chr). The package was compiled, but only partially installed and thus non-functional.
  • WASM: Enable adding packages in the node version This was disabled due to issues with Emscripten opendir(), but these seem resolved.
  • WASM: Support INSTALL_QLF and INSTALL_PROLOG_SRC CMake flags
  • WASM: Remove several libraries that cannot be supported
  • BUILD: Allow qlf builds without PlDoc and xpce

[Mar 20 2025]

  • DOC: WASM function Prolog.query() Documented nodebug and string options.
  • WASM: Prolog.query(): add option {string:"atom"}
  • ENHANCED: Generalise user interaction on answer Allow reusing the toplevel answer user interaction by using an alternative input.
  • ENHANCED: qlf app to report .qlf files without sources. Used to report these as out of data.
  • FIXED: We must insert I_CONTEXT in multifile predicates Multifile predicates are typically installed in modules using target:head :- body, where body is executed in the containing module. This is achieved using an I_CONTEXT VM instruction. Before, when the predicate contains one such clause, it set P_MFCONTEXT and inserted a I_CONTEXT for each subsequent clause. When using .qlf files though, the files may be loaded in different order than when creating the .qlf files, leading to clauses without an I_CONTEXT instruction to follow clauses with this.

[Mar 19 2025]

  • ENHANCED: library(prolog_xref): cleaner exception handling.
  • ENHANCED: Allow cross-referencer to deal with .qlf files
  • BUILD: Added CMake option -DINSTALL_PROLOG_SRC=OFF This can be used together with -DINSTALL_QLF to ship the Prolog libraries as .qlf files without including the sources.

[Mar 18 2025]

  • FIXED: Handle autoload/1,2 declarations in aggregate .qlf files
  • FIXED: load_files/2: resolve to files loaded from .qlf Some qlf files may load multiple source files. When looking for a file in e.g. use_module/1,2, first try the file system, but on failure ee whether we loaded a .qlf file that registered the required file.
  • FIXED: Use canonical .pl files for all admin purposes. Despite the fact that code is loaded from .qlf files, use the .pl file from which the .qlf file is compiled for admin purposes.
  • ADDED: '$qlf_module'(+File, -Dict) This predicate extracts properties for a module without loading it. This is required to make autoload/1,2 work if we remove the source files.

[Mar 17 2025]

  • MODIFIED: absolute_file_name/3: distinguish file types prolog and source These used to be synonyms. Now prolog includes .qlf and source does not.
  • INSTALL: Install .qlf files if these have been build.
  • ADDED: library(prolog_qlfmake) This library allows for compiling the entire library to .QLF files.
  • ADDED: Prolog flag source. This flag can be used to ignore the .qlf files in the library and load the .pl (source) files instead.
  • ADDED: library(prolog_qlfmake) This library allows for compiling the entire library to .QLF files.
  • FIXED: Do not keep an erased clause when doing an incremental compilation

[Mar 16 2025]

  • ENHANCED: qcompile/1: preserve predicate properties When compiling clauses for another module as commonly done as a return of term_expansion/2, preserve the multifile and dynamic properties, such that the module can be loaded as qlf and later loading of the module into which the clauses are added does not wipe the predicate.

[Mar 15 2025]

  • FIXED: Debugging the fail port of Prolog defined built-in predicates.

[Mar 13 2025]

  • FIXED: If engines are enabled without threads, call the main engine main.

[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.

[Feb 6 2025]

  • ADDED: WASM: options parameter to Prolog.query() and Prolog.forEach() to control running in a dedicated engine.

[Feb 5 2025]

  • DOC: Class Engine
  • WASM: Improve Query and Engine interaction and benchmark suite

[Feb 4 2025]

  • DOC: Docuemnt scripts/configure in CMAKE.md
  • MODIFIED: By default enable engines in single threaded version. The impact on performance and size is minimal.

[Jan 31 2025]

  • ADDED: Support Prolog engines in the WASM JavaScript interface
  • ADDED: PL_current_engine() Although we can also fetch the current engine using PL_set_engine(), this API is simpler and faster and notably easier to handle for e.g., the WASM version.
  • WASM: Use (hard) links to populate the wasm-preload directory. This makes incremental builds work correctly if Prolog files are changed.
  • ENHANCED: No longer trigger AGC from CGC We used to trigger this if there are a fair amount of clauses that have been erased for which we have a clause reference. As we remove these clauses anyway from the indexes, they only cost memory and thus leaving the decision to normal AGC seems fine.

    In due time we should probably consider atom sizes when considering AGC.

  • ADDED: PL_set_query_data() and PL_query_data() These allows attaching user data to a Prolog query. This allows for efficiently tracking the role and status of a query in an application.
  • ADDED: Better engine corouting support from C using PL_WITH_ENGINE()

[Jan 30 2025]

  • WASM: Missing build dependency
  • CLEANUP: conditional dead code when using engines without threads.
  • WASM: Associate await/2 state with the engine This is part of supporting multiple engines in the WASM version.
  • ADDED: PL_query_arguments() This finds the arguments of the primary goal of a query.
  • ADDED: Support engines in single-threaded version This patch revives an old proof-of-concept option to include engines in the single threaded version. The code compiles and tests again. Added Prolog flag engines to indicate the system has engine support.
  • DOC: Extended state values for PL_next_solution()
  • ADDED: Provide SWIPL_HOME macro from swipl-ld

[Jan 29 2025]

  • TEST: Move tests from src/Tests to tests This simplifies navifating the source tree. It notably allows us running git grep in the src directory for C code without false hits from the Prolog tests.

[Jan 27 2025]

  • BUILD: Support multiple Emscripten environments in scripts/configure
  • PORT: WASM: Silence unused main warning. Main is a tiny function that pulls in no extra dependencies, so keeping it in is easier than leaving it out.
  • PORT: Support Emscripten 4 - All source must be in --pre-js as the --post-js is loaded after the module is initialized and thus we cannot initialize Prolog there. - Bug in Query constructor, passing an integer rather than a string.

[Jan 24 2025]

  • FIXED: Compilation on single-threaded systems.
  • FIXED: debugging/0 fails to report spy points. Because debugging/0 runs the implementation in nodebug mode it never reports that debug mode is on and the set spy points.

[Jan 23 2025]

  • PORT: Avoid C23 static_assert() without message
  • MODIFIED: Only include <windows.h if SWIPL_WINDOWS_NATIVE_ACCESS is defined This provides the types and prototypes for the Swin* functions that provide access to underlying HANDLE and SOCKET objects.

[Jan 22 2025]

  • ADDED: swipl-win console ^Y bound to paste_quoted.

[Jan 20 2025]

  • ENHANCED: Simplify shallow backtracking code
  • ADDED: jiti_suggest_modes/0,1 Inspect the created JIT indexes, looking for arguments for which we could create an index, but the predicate is never called with the argument instantiated.

[Jan 15 2025]

  • ENHANCED: Handling of candidate deep indexes.

[Jan 13 2025]

  • MODIFIED: predicate_property/2 indexed(-Indexes) property Now returns the indexes as a list of dicts. This supports new features and is easier to extend as indexing is further refined.

[Jan 8 2025]

  • ADDED: Low level support to compute all useful hash indexes and their properties. Accessible from Prolog as '$candidate_indexes'/3

[Jan 22 2025]

  • DOC: Clarified PL_get_arg() and _PL_get_arg().

[Jan 20 2025]

  • FIXED: indexableCompound() This function is used to see whether a deep index is possible. It could generate wrong results, both missing indexes and making useless indexes.
  • TEST: Cleanup reload test Layout and use assertion/1 such that we can more useful feedback

[Jan 17 2025]

  • ENHANCED: explain/1 Several enhancements, notably list predicates with certain properties and provides some more detail on various objects.

[Jan 15 2025]

  • FIXED: Cleanly destroy claused indexes on free.
  • FIXED: Detection whether a compound can be used for deep indexes. This incorrectly considered H_VOID/H_VOID_N to be indexable. Also documents and uses bool.

[Jan 14 2025]

  • FIXED: addClauseToListIndexes() could skip indexes

[Jan 13 2025]

  • ENHANCED: Inserting new clause indexes

[Jan 15 2025]

  • FIXED: Crash in clear_frame_vars() when compiled for debugging

[Jan 14 2025]

  • ADDED: library(prolog_colour): colour mode/1 directives. Coloured as meta_predicate and therefore still accepts the non-mode specifiers.
  • ADDED: check/0: print dummy mode declarations.

[Jan 13 2025]

  • FIXED: Control-C + abort while printing output may exit REPL. If the abort is handled by PL_handle_signals() called from flushing the output, the stream is set in error state. If releasing the stream re-raises the exception it should clear the error state from the stream.
  • CLEANUP: Remove unused supervisor instructions S_ALLCLAUSES and S_NEXTCLAUSE
  • DOC: JIT indexing for [] vs [_|_] and "primary" index
  • ADDED: mode/1 and predicate_property/2 property mode(-Head)

[Jan 12 2025]

  • ENHANCED: Generalize S_LIST supervisor for any argument. The S_LIST supervisor is now used to select between an [] and [_|_] clause regardless of the argument.

[Jan 13 2025]

  • FIXED: Clause analysis that involves multiple calls to skipArgs() In this case we need to keep context for dealing with H_VOID_N, skipping N void arguments.

[Jan 12 2025]

  • FIXED: reexport/2: allow for op(Priority,Associativity,Name) Consistent with use_module/2 as (now explicitly) claimed. Reported by Rick Workmann.

[Jan 8 2025]

  • FIXED: alloc_assessment(): check for malloc() failure

[Jan 6 2025]

  • ENHANCED: bypass most indexing code for non-indexable predicates
  • ENHANCED: Change default index argument

[Jan 3 2025]

  • ADDED: Prolog flags to query and change the JIT clause indexing. Experimental. The meaning and names of the flags are likely to change.

[Jan 5 2025]

  • FIXED: library(prolog_colour): misleading colouring of Dict.field Field was flagged as an error (no_function).
  • DOC: sort/4 stable sort example. Suggested by Pierpaolo Bernardi.

[Jan 4 2025]

  • ASAN: Avoid runtime errors on field[1]
  • PORT: More C99 unspecified array at end of struct issues.
  • PORT: Use portable definition of struct clause
  • PORT: Use C99 constructs for a portable version of struct functor Structs may use type name[] as last field for a dynamic array.

[Jan 3 2025]

  • ENHANCED: Simplify generating a joined key for multiple arguments.
  • ENHANCED: app splfr to use new argv_options/4 ability to pass unknown options.
  • ADDED: argv_options/4: option unknown_option(pass) This passes unknown options to the positional argument list without warning. This is intended for processing some options while some downstream component processes the remaining options.

[Jan 2 2025]

  • MODIFIED: Turn SICStus splfr script into a SWI-Prolog app Allows for swipl splfr [option..] input ...

    Patch also fixes typing in sicstus.h, check the return of PL_put_term() and adds SP_cons_functor().

  • DOC: spellchecked documentation

[Jan 1 2025]

  • CLEANUP: Clause indexing code. Split into smaller functions, use bool type, avoid goto, add more comments, etc. This is a preparation before improvements.

[Dec 30 2024]

  • ADDED: foldall/4. Suggested by Boris Vassilev.
  • DOC: clarified (new) destructive assignment complexity.
  • ENHANCED: Use improved sharing in nb_set_dict/3. This patch makes nb_set_dict/3 call the low-level code for nb_setarg/3, providing better code reuse.

[Dec 29 2024]

  • ENHANCED: nb_setval/2: avoid quadradic complexity.
  • ENHANCED: nb_setarg/3: avoid copying the old value. If the new value contains the old, the old value is not copied, making many applications linear instead of having quadratic cost.
  • CLEANUP: Pack context for copy_term/2 and friends into a struct Also type and declaration cleanup

[Dec 23 2024]

  • ADDED: swipl pack remove: --dir=DIR option
  • ADDED: swipl pack info: --dir=DIR option Give info on packs installed below DIR

[Dec 21 2024]

  • ADDED: swipl pack rebuild [--dir=dir] [pack ...]
  • ADDED: swipl pack list --dir=DIR option to list packs installed in DIR.

[Dec 19 2024]

  • FIXED: dict_same_keys/2 could overflow the global stack.
  • ADDED: trap/1: aliases for e.g. type_error -> type_error(_,_) So one does not need to remember the number of arguments.

[Dec 18 2024]

  • FIXED: Preserve incremental property when creating a saved state.

[Dec 13 2024]

  • BUILD: Add CMake option -DSWIPL_SO_VERSIONS to remove SOVERSION properties.

[Dec 12 2024]

  • DOC: statistics/2 lost the keys globallimit, locallimit and traillimit. Reported by Jelmer Jellema.

[Dec 10 2024]

  • FIXED: print_term/2: proper handling of operators(Ops) Needs to be kept consistent with write_options([... ignore_ops(IgnOps)]). Implemented consistency and deprecated the option. Reported by Mike Elston.

[Dec 9 2024]

  • FIXED: merge_options(+Dict, +List, Merged) Resulted in no matching rule exception.
  • ADDED: library(prolog_colour): track CHR declaration locations

[Dec 8 2024]

  • FIXED: Handling of home during boot session.

[Dec 4 2024]

  • ENHANCED: pack_info/1: use colours and indicate autoload status.
  • MODIFIED: pack_install/2 option autoload(true) If present, the pack is installed as autoload pack regardless of autoload option in the meta-data. If the option is not present, the system asks the user to install as autoload library if the meta-data contains autoload(true).

    If autoloading is not enabled, the INDEX.pl file that may appear in the pack is removed.

    This patch also adds swipl pack install --autoload ...

  • FIXED: Make packs that provide an autoload library work again.

[Dec 3 2024]

  • FIXED: cmake/TestSignalType.c for C++
  • PORT: Make cmake test for signal handler compatible with c23

[Dec 2 2024]

  • ENHANCED: gui tracer support for Head ==> Body rules.
  • ENHANCED: Set non_terminal property for clauses for Head ==> Body

[Nov 29 2024]

  • WASM: Include ABI file to make the home search work.
  • FIXED: New home search to actually try the compiled in value.

[Nov 28 2024]

  • ENHANCED: Verify sanity of the Prolog home directory This patch validates that the home directory contains a file ABI holding the ABI information and compares this. On failure, it reports a detailed report on why Prolog could not find its home directory.

[Nov 27 2024]

  • FIXED: explain/1 to report the same predicate multiple times. This happens if the predicate is imported into multiple modules.
  • ADDED: library(exceptions) This library provides catch/4 and error/2 to define error types and catch based on types rather than unification. Experimental.

[Nov 25 2024]

[Nov 24 2024]

  • FIXED: Pass command line arguments in class Prolog.

[Nov 22 2024]

  • DOC: gcd/2 and lcm/2 are not operators.
  • ADDED: Prolog flag unknown_option with values {ignore,warning,error}. As a result of PIP-105. May change, but unlikely as their was clear agreement.

    This flag disables the iso flag from reporting errors on unknown options because this breaks large parts of SWI-Prolog's libraries. The user can now explicitly enable this as well as make the system pring warnings to investigate possible issues.

[Nov 21 2024]

  • FIXED: Use of undefined options in the toplevel. This makes the toplevel unusable if the Prolog flag iso is set to true.
  • PORT: WASM: Get rid of deprecated allocate, ALLOC_NORMAL and ALLOC_STACK
  • FIXED: WASM: Query.next() to set done to true on last answer. This must be false when used as iterator.
  • ENHANCED: Allow suppressing autoload warnings.
  • TEST: Move test_rwlocks.pl from library to thread test dir. This test should not run in the single threaded version.

[Nov 20 2024]

  • FIXED: WASM: for(x of prolog.query(...)) lost last answer

[Nov 18 2024]

  • FIXED: Handling return values in stack expansion. Introduce more bool to correctly distinguish functions returning true/false/*_OVERFLOW from those raising exceptions and only returning true/false.
  • FIXED: prolog_trace_interception/4: setting up the hook good crash.

[Nov 17 2024]

[Nov 16 2024]

  • ADDED: format/2: support ~:D The colon modifier for D forces the use of Prolog digit grouping using _.
  • FIXED: format/2 handling of Unicode characters Regression from a49fe8cb40fc15b7325a4e4836304cbe6d9ccef0

[Nov 15 2024]

  • ADDED: library(prolog_locale) to setup grouped printing of integers.
  • ADDED: write_term/2 options format_float(+Format) and format_integer(+Format) Using a format seems a more sensible way to control writing numbers from write_term/2. This patch removes the previously introduced radix(+Radix) option. If we want this back we will implement it on top of format_integer(+Format).

    This patch also contains a lot of small code cleanup and some optimization to low-level I/O.

  • ADDED: write_term/2: option radix(Radix). Experimental. Under discussion as PIP-105. The current implementation writes, unlike XSB, the radix prefix. We either need more options or we should consider another alternative such as integer_format(+Format)

    As this patch cleans up a lot of the code regarding numeric output and most will be needed anyway, it is merged despite the fact that the radix option may vanish eventually.

[Nov 14 2024]

  • ADDED: format/2 specifier ~h This provides compatibility to SICStus. It also makes write/1 output for floats compatible to SICStus for deciding between fixed point and exponential notation.
  • FIXED: ISO compatible parsing for `fy 2 yf` and similar cases.

[Nov 13 2024]

  • TEST: Added ISO ambiguous operator tests. Marked two tests as blocked as these currently fail.

[Nov 8 2024]

  • FIXED: #1331 Module issue in SICStus block/1 emulation. This patch also reformats the file, removes some dead code and remove the outdated restriction that it does not work on dynamic or foreign predicates.

[Nov 6 2024]

  • ENHANCED: Avoid spurious tracing in push_msg/2.
  • DEBUG: First print the Prolog stack "safe" on a crash. This guarantees that the stack is printed, including details on the clauses involved and progress in each clause. Next, the stacks are printed with arguments. This however may crash if the crash is caused by corrupt data on the stacks.

[Nov 5 2024]

  • ADDED: Support SSU DCG rules as Head[, Guard] ==> DCGBody.
  • FIXED: libary(prolog_pack): detection of valid download URLs.
  • FIXED: Build order planning. This reverts 1cf4acbe722604857a2627ecc161f80e16f330ed. That patch was broken. The reported failure probably had some other cause.

[Nov 4 2024]

  • FIXED: Installing a pack should attach the pack itself. This incorrectly registered the directory of the pack as a directory that provides packs instead.
  • ENHANCED: explain/1 to enumerate all instances of a non-qualified predicate.
  • TEST: rwlocks unit tests for safety and reliability

[Nov 3 2024]

  • BUILD: plunit requires clib package.

[Nov 1 2024]

  • ENHANCED: Implement distinct/1,2 and reduced/1,3 using tries. This reduces the overhead over 5 times.

[Oct 31 2024]

[Oct 29 2024]

  • ENHANCED: Re-implement library(nb_set) using closed hash tables. This provides better performance at lower memory usage. It comes with a few modifications:
    • The term representation is different. This only affects applications that access the internals.
    • gen_nb_set/2 enumerates the elements in hash order rather than in standard order of terms.
    • Invalid usage now traps nu matching rule errors due to the usage of => rules. Used to fail or succeed incorrectly.

[Oct 24 2024]

  • BUILD: Make sure to clear DISPLAY when running xpce steps (one more)

[Oct 23 2024]

  • BUILD: Make sure to clear DISPLAY when running xpce steps While the build works without a DISPLAY variable, an invalid variable causes the build to fail.
  • TEST: Disable collation_key/2 test for MacOS Macos Sequoia (15) wcsxfrm() returns garbage.

[Oct 22 2024]

  • FIXED: Avoid corruption in setjmp()/longjmp() Clang demands using a volatile variable for protecting the throw environment's parent. This is probably correct, although it seems weird to place this variable in a register.

[Oct 19 2024]

  • ENHANCED: Add Prolog navigator to theme/dark.pl

[Oct 18 2024]

  • FIXED: build order for dependencies in packs. Based on #1326, but fixing build_order/2 rather than reversing afterwards.
  • FIXED: expand_term/2 to succeed twice when expanding a toplevel list. Results in duplicate clauses when compiling [f(1), f(2)].. Reported by Uwe Neumerkel.
  • FIXED: pack management: find available versions from wildcard URL. Patch by Nicos Angelopoulos

[Oct 17 2024]

  • PORT: Added FreeBSD signal names to the name/number map. Contributed by Dewayne Geraghty

[Oct 15 2024]

[Oct 11 2024]

[Oct 10 2024]

  • FIXED: select_dict/3: possible crash. Could crash if the first argument dict did not have unbound keys. The new implementation is also faster, building the new dict opportunistically rather than in a second scan.

[Oct 9 2024]

  • FIXED: Build failure on systems without sem_timedwait()
  • FIXED: Avoid message when assertion/1 is interrupted by abort

[Oct 8 2024]

  • ADDED: Prolog flag halt_grace_time: graceful timeout limit
  • CLEANUP: Getting Prolog flags from C
  • ADDED: PL_print_message() for calling print_message/2 from C
  • FIXED: print_term/2: indentation of right argument of infix term.
  • FIXED: Allow breakpoints in arg(C,T,F) I.e., arg/3 calls with a known argument and the 3th index being a first var. These map to the B_ARG_CF VM instruction.

[Oct 7 2024]

  • FIXED: Possible memory leak in various C API functions using BUF_MALLOC These functions could "stack" intermediate results, overflowing the string stack when used excessively inside a single foreign predicate or outside calls from Prolog (i.e., using "main" in foreign code).

[Oct 6 2024]

  • ADDED: PL_get_stream(): SIO_TRYLOCK flag to allow failure if the stream is locked.

[Oct 5 2024]

  • ADDED: catch/3: support constraints on the Ball.
  • FIXED: Bail out with fatal error if we cannot allocate a foreign frame for an exception.

[Oct 4 2024]

  • FIXED: Generate a fatal error if there is no local stack emergency space
  • FIXED: Partial unification while searching for a matching catch/3. As the partial unification is not undone, we may fail to find the right catch frame.

[Oct 3 2024]

  • FIXED: Memory leak in PL_get_wchars() when using BUF_MALLOC.
  • FIXED: Avoid error message when calling halt/0,1 from -g goals. Reported by Jos de Roo
  • MODIFIED: cancel threads using unwind(halt(Status)) Older versions used '$aborted'
  • MODIFIED: PL_halt() return status and new flag. If the flag PL_HALT_WITH_EXCEPTION is used, PL_halt() tries to raise an exception and returns false. If the halt was cancelled, the return is now true (was false). Otherwise, the function does not return.

[Oct 2 2024]

  • ENHANCED: halt/1: use the unwind(halt(Status)) if possible.
  • CLEANUP: Removed '$aborted'
  • DOC: Status of unwind(...) exceptions.
  • MODIFIED: Re-implement thread_exit/1 based on unwind(thread_exit(Term)).
  • ADDED: Allow unwind(halt(Status)) to halt from an exception.
  • MODIFIED: Introduced unwind(Term) exceptions.
  • ADDED: parse_time/3: support RFC1036 and ASCTIME formats These formats are old HTTP timestamp formats.

[Sep 30 2024]

  • DOC: Added documentation for PL_for_dict()
  • FIXED: Windows format_time/3 implementation for time stamps > 32 bits. While the Windows time_t is 64 bits, it doesn't seem to localtime() seems broken handling large time offsets.

[Sep 29 2024]

  • MODIFIED: parse_time/2,3: interpret missing timezone as local time. This patch fixes parsing YYYY-MM, which used to be a day too early.

[Sep 30 2024]

[Sep 27 2024]

  • DOC: #1323 Wrong claim on default for prefer_rationals flag.

[Sep 26 2024]

[Sep 25 2024]

  • ADDED: with_stopped_threads/2 to run a goal while other threads are stopped. This is a utility for supporting the debugger.
  • MODIFIED: interactor/0,1 to run thread in normal mode.

[Sep 24 2024]

  • FIXED: pack_publish/2 reporting (claimed failure)
  • ADDED: swipl pack publish --server=URL ... Allows publishing at an alternative server.
  • ENHANCED: argv_usage/1 to put a newline before the footer section.
  • FIXED: Package manager, swipl pack publish . Broken detection of git directory and failure do deal with
    requires(prolog:flag(_Value)).

    to test for existence of a Prolog flag.

[Sep 23 2024]

  • FIXED: Possibly memory leak in LibBF arithmetic A thread race condition may lead to loosing cache values from get_trig(). Fixed using C11 atomics.

[Sep 22 2024]

  • FIXED: Use stack variable after return for LibBF bignums This leads to incorrect results and crashes when using really big bignums. The LibBF bignum implementation is by default used for the WASM version and the MacOS binaries.

[Sep 21 2024]

  • ENHANCED: install_pack/1,2 to prefer https over http for downloading. Unless insecure(true) or swipl pack install -k <pack> is given, possible HTTP links are automatically rewritten to HTTPS.
  • FIX: missing dot that one had interesting side effects :-)

[Sep 20 2024]

[Sep 19 2024]

  • MODIFIED: argv_options/3: with type (bool|sometype) We now consider the option boolean unless written as --opt=value Before, the option was considered boolean if it was the last argument or the next argument started with a -.

[Sep 18 2024]

[Sep 17 2024]

  • PORT: Add gettid() detection
  • PORT: Call gettid via its glibc wrapper if possible

[Sep 16 2024]

  • ENHANCED: Arithmetic performance. This patch reverts 18d5d539af0807808ba6fee6ec66394aaec589f1 except for clang as it does cause a significant slowdown on some systems.

[Sep 11 2024]

  • LEGAL: Resolved license issues for dialect/xsb/basics.pl Hi Jan, As the coder of a number of (but by no means all) the predicates in XSB's basics.P, I'm perfectly fine with you releasing under the BSD-2 license. Regarding the issues with XSB's licenses, we'll have to consider it and come to some decision. Best, -David

[Sep 8 2024]

  • DOC: Updated limits section

[Sep 5 2024]

  • DOC: Update 32/64 bit notes
  • FIXED: #1317 thread_exit/1 can crash after changes to thread_signal/2.
  • APPLE: Add code signing for creating the .dmg image The image is signed if $CODESIGN_ID is set to the certificate id to be used with codesign -s. Unfortunately, this is not the whole story. As a result, we can no longer load shared object that are not part of the disk image, which means we cannot use Xquartz, Python or Java.

[Sep 4 2024]

  • MODIFIED: Apple: better support MacOS bundle hierarchy Make the binary bundle match the MacOS guidelines. In particular
    • Move the Prolog "home" to Contents/Resources/swipl
    • Move modules (*.so files) to Contents/Plugins/swipl
    • Remove the need for swipl.home by using compiled-in relative path to find the home.
    • Added a flag bundle to make the system aware it is using the bundle hierarchy.
    • Moved foreign path definitions from init.pl to the library(shlib), where we now use conditional compilation to get the paths right for the target platform.
  • FIX: include stdbool

[Sep 3 2024]

  • DOC: Explain issues and features of the C-API Boolean functions.
  • DOC: Fix bool types for PL_* functions
  • MODIFIED: Return type of most C API functions is now bool This should have very few consequences to applications, even preserving binary compatibility. The change adopts the upcoming C23 standard and makes it easier to understand the API.

[Sep 2 2024]

  • CLEANUP: Use true and false throughout the core C code.
  • COMPAT: Adopt stdbool.h This patch avoids conflicts the type bool and its values true and false as defined in <stdbool.h> while these will be promoted to C keywords in the upcoming C23 standard.

[Aug 31 2024]

[Aug 30 2024]

  • TEST: Avoid interference between thread_wait tests. Tests send concurrent signals using a detached thread that could still be running, affecting subsequent tests.
  • TEST: Test for getting an I/O error on a broken pipe may succeed. Turns out the pipe size on Asahi/Fedoare 40 is 256K. Now writing a max of 1.2Mb rather than 100K.

[Aug 29 2024]

  • ADDED: Prolog flag dir_sep Complements path_sep and path_max to get properties on the file naming conventions and limits.

[Aug 28 2024]

  • FIXED: #1311 Possible stack corruption in PL_unify_text() Cause of this crash is a failure to verify return from PL_new_term_ref(). There were more issues with the code though. Lack of local space could corrupt a string living on the stack. We can discard the term reference.

[Aug 27 2024]

  • INSTALL: modify cmake ilink to install symlink in CMAKE_INSTALL_PREFIX This ensures that when installing package selections to different install prefixes, the links end up in the right location. This is used by package maintainers to generate multiple packages from the same build.

[Aug 26 2024]

  • FIXED: swipl-win.exe: Run/New thread menu

[Aug 24 2024]

  • SNAP: added libxinerama1

[Aug 23 2024]

  • DEPRECATED: file search from a source file relative to CWD Searching relative to CWD when loading a source file was supported up to version 9.3.8. 9.3.9 disabled this, but the implications appear too severe. This patch re-enables the old behaviour with a warning. The Prolog flag source_search_working_directory can be set to false to disable searching the working directory.

[Aug 17 2024]

  • FIXED: possibly early GC of arguments for call_cleanup/2 Also affects '$bags':cleanup_bag/2. The early GC can happen if a signal arrives when these predicates are being called and the signal handler calls GC.

[Aug 15 2024]

  • FIXED: use_module(M, [Pred as Alias]) for meta-predicates

[Aug 14 2024]

[Aug 6 2024]

  • FIXED: print_term/2 to add a space behind : when printing dicts vertically. This avoids syntax error due to symbol glueing and looks prettier.

[Aug 1 2024]

  • FIXED: Handle "apps" from packs

[Jul 25 2024]

  • FIXED: Handling of indirect data types in delimited continuations.

[Jul 24 2024]

  • BUILD: Added CMake options SWIPL_CC and SWIPL_CXX This selects the defaults for the c_cc and c_cxx flags. Distributions should normally set these to the common C and C++ compiler of the platform. Local builds typically leave them default, setting these flags to the same as used to build SWI-Prolog.

[Jul 23 2024]

  • FIXED: #1300 Modify prefix block operator to plain term if there is no argument.

[Jul 22 2024]

[Jul 19 2024]

  • FIXED: qlf app to not import the compiled library into user. This leads to conflicts.

[Jul 18 2024]

  • MODIFIED: drop library(checkselect) and library(checklast). These modules help debugging reordered arguments for select/3 and last/2 from old non-(de-facto)-standard to common practice long ago.
  • DOC: Improved docs for prolog_alert_signal/2.

[Jul 12 2024]

  • FIXED: swipl pack install . to install using a symlink.

[Jul 11 2024]

  • MODIFIED: absolute_file_name/3 relative to source Up to this patch, predicates that used absolute_file_name/3 (including load_files/2, use_module/1, etc) interpreted plain non-absolute names relative to the source and on failure, relative to the working directory. As of this patch we only consider files relative to the source.
  • PORT: Another iteration trying to tame MacOS.
  • PORT: Deal with wcsxfrm() nor immediately returning required size

[Jul 10 2024]

  • FIXED: Type for PL_get_intptr_ex(). Breaks on Win32

[Jul 9 2024]

  • CLEANUP: Make all code clean for clang-18 -fsanitize=undefined

[Jul 5 2024]

  • ENHANCED: Added 'c_cxx' flag and env SWIPL_CXX for packs

[Jul 8 2024]

  • FIXED: #1292: possible stack corruption in exception handling. Probably can only be triggered if SECURE_GC is enabled which wipes the unused parts of the stacks in trimStacks().
  • SANDBOX: Allow for term_singletons/2

[Jul 1 2024]

  • FIXED: #1292 Possible stack corruption after exception.

[Jun 14 2024]

  • FIXED: unification of zero-arity compounds

[Jun 8 2024]

  • FIXED: Possible assertion error due to unify refactoring.

[Jun 7 2024]

[Jun 4 2024]

  • CLEANUP: Refactor unify() Split into a function that deals with everything except compounds and one that does the whole thing. This makes the function a lot easier to understand. This rewrite has no measurable performance implication and should make it a bit easier to optimize it further.
  • ENHANCED: Simplify H_VAR
  • ENHANCED: Low-level unification to constants Speeds up unification from foreign code to atoms and small integers.

[Jun 3 2024]

  • ENHANCED: make/0: no longer try to update the indices of system libraries. These libraries are properly maintained by the build and installation process while the time stamps are often wrong after the installation process.

[Jun 1 2024]

  • FIXED: Do not wait longer than 30 seconds after a crash. This deals with situations where error reporting and cleanup hangs due to a deadlock.

    Normally, after a fatal crash report and if the system is connected to a terminal, it waits for user input such that the user can attach a debugger to analyse the state. We now wait at max 30 seconds to avoid indefinite waiting if there is no human in the loop after all.

  • DOC: time/1: we do support per thread CPU time on MacOS.

[May 31 2024]

  • FIXED: Properly export environment_frame in foreign predicate redo. The incorrect setting causes problems in the new consistency checks for term_t as well as confusing backtraces.
  • PORT: Possibly collapsing VM instructions on 64 bit Visible using gcc 14 on arm64 (Asahi Linux)
  • WASM: SWIPL() initialization changed in Emscripten Where SWIPL(Module) used to return a Promise that would complete returning the same Module, it now returns a new module object that is independent from the agument passed.

[May 30 2024]

  • ADDED: PL_free_term_ref() In addition, this patch distinguishes term_t originating from predicate arguments (which cannot be freed and to which we cannot "write" (PL_put_*())) from user allocated term references.

[May 29 2024]

  • ADDED: Validate arguments to the C API PL_*() functions. This commit validates term_t, atom_t and functor_t parameters to the PL_*() functions that terminates the process if it finds invalid data.

    These tests may be disabled using cmake -DVALIDATE_API=OFF. The validation has very little impact on the raw Prolog performance as most internal use of the C api bypass the public API function. It may have measurable impact on packages that use the C interface in a very time critical way.

  • ADDED: PL_api_error() to signal invalid use of the API

[May 30 2024]

  • FIXED: =@=/2: attributed variables must be handled as normal variables.

[May 28 2024]

  • FIXED: Determine file exports under conditional conditional compilation.
  • FIXED: Process multiple predicates from export/1 directives. To determine file exports, we considered only a single predicate for export/1.
  • FIXED: Stops repeated crash reports While recursive crashes where dedected, no appropriate action was taken, leading to endless error reports.
  • FIXED: '$open_xterm'/5: raise exeption if we cannot run xterm. Used to hang, waiting for output from the xterm process.
  • MODIFIED: Renamed open_xterm/5 as private '$open_xterm'/5. open_xterm/5 was not documented. This patch removes the implementation completely if the OS lacks the required POSIX pty support and renames the predicate to '$open_xterm'/5 if xterm consoles can be supported. In addition, this patch adds conditional compilation to console support in library(threadutil) if neither the Windows support nor the xterm support can be provided.

[May 27 2024]

  • FIXED: Build dependency of documentation on utf8proc package
  • ENHANCED: call_in_thread/2 error handling.

[May 24 2024]

  • TEST: test_interrupt: skip test if alert signals are required but they are disabled.

[May 25 2024]

  • DOC: fix typo and improve cmake instructions

[May 24 2024]

  • FIXED: thread_create/3: handling of c_stack option. While the size was documented to be in K-bytes, it actually is in bytes. Updated the docs for that. Allow for c_stack(0) to use the mininum.

[May 22 2024]

  • ADDED: thread_get_message/3 and thread_send_message/3: signals(BoolOrTime) option.
  • MODIFIED: Change default for the Prolog flag toplevel_print_anon. This flag is now by default false, hiding toplevel variables that start with an underscore.

[May 20 2024]

  • FIXED: Generating variable names may conflict with user variables.
  • FIXED: Links to FAQ pages.

[May 16 2024]

  • FIXED: Trie handling of floats on 32-bit hardware
  • CMAKE: Fixed -DCMAKE_BUILD_TYPE=Sanitize Defaults to -fsanitize=address.

[May 15 2024]

  • FIXED: Enabled pre-check for left-shift of large integers This both avoids possible GMP exceptions and allocating huge amounts of memory.
  • ENHANCED: Clarify shifting negative integers This patch also avoids relying on undefined C behavior.
  • FIXED: shift (<< and >>) of zero.
  • FIXED: Handle source files with epoch time stamp Flatpak seems to set the modification time of all times in the sandbox to the epoch (0). This was used as a special value to indicate the source file was not a file. We now keep a seperate flag and use the integer 0 to indicate something is not a source file in the Prolog world. It is probably better to use something else, but this avoids type issues in possibly unknown dependent code.

[May 14 2024]

  • ENHANCED: Crash reports Avoid recursive crash reports and only print the GC and shift stacks if the environment variable SWIPL_DEBUG_GC_STACK is set.
  • DOC: Add `--sigalert=NUM to swipl --help`.

[May 13 2024]

[May 12 2024]

[May 5 2024]

  • CLEANUP: Avoid to undefined sanitizer warnings.

[May 4 2024]

  • CLEANUP: Avoid UBSAN error Test for arity > 0

[May 3 2024]

  • CLEANUP: workaround for an UBSAN error UBSAN complained about a left shift of -1
  • CLEANUP: avoid UBSAN error in mkvmi.c The error is raised because we have e5 -= 0 for e5 == NULL

    else-branch of if ( !e4 || (is_vmh && !e5) ) <=> e4 && !(is_vmh && !e5) <=> e4 && (!is_vmh || e5)

    Consequence is e4-- (which is fine) and e5 -= is_vmh which is either a noop* for is_vmh == 0 or fine for is_vmh != 0 && e5 != NULL.

    The noop case raises the error if e5 == NULL. * CLEANUP: Use unsigned int for variable table bitmap. This avoids an officially undefined shift in C.

  • FIXED: Possibly undefined too large shift
  • FIXED: bf_set_si for -INT_MIN avoid undefined behavior raised by UBSAN

[May 2 2024]

  • PORT: !1269 Deal with the type z_crc_t used by minizip zlib This works around a type conflict over get_crc_table(). Some headers define this as returning `z_crc_t*` without defining this type while others (Fedora 40) defines the function as `uint32_t*` and defines z_crc_t. This patch makes CMake check for the z_crc_t type and, if defined, use this definition.

[May 1 2024]

[Apr 30 2024]

  • ENHANCED: Added toplevel options +, - to modify max_depth This option also changes 'w' to merely drop portrayed(true) and p to add it.
  • DOC: write_term/2: document interaction between portrayed and numbervars
  • FIXED: Do not name binding variables if the answer options to not handle '$VAR'(N)
  • RELEASE: update-macports: verify we can download the source file This avoids forgetting to update the source file as well as the CDN delay.
  • DEBUG: Save C backtraces at GC and SHIFT start
  • DEBUG: Improve crash context printing Make all fatal errors (sysError(), assertion failure and fatal signal) call new function printCrashContext() that prints more extensive information about the crash
  • FIXED: notrace/1 could raise a representation_error(size_t) exception This exception is raised if the trace skip level = SKIP_REDO_IN_SKIP.

[Apr 28 2024]

  • FIXED: call/1 (I_USERVALL0) GC issue call/1 did not correctly make the goal available to GC if stack expansion is required.

[Apr 27 2024]

[Apr 26 2024]

  • PORT: Fix case conversion for Unicode characters on Windows.
  • TEST: Disable case test for u00ff on Windows. towupper(0xff) returns 0x9f on Windows.
  • FIXED: prolog_walk_code/1: no matching rule from goals reached from a :- initialization.
  • BUILD: Extended scripts/configure to include termux

[Apr 25 2024]

  • FIXED: Stack shifter Foreign frames may hold references to the local stack in addition to global stack references.
  • PORT: Include Ubuntu 24.04 (Noble Nombat) in PPA builds
  • PORT: Use -funwind-tables on ARM systems with glibc, also for clang

[Apr 23 2024]

  • CLEANUP: Remove various unused macros and join macros that are now the same Also document the current state of the Prolog data representation.

[Apr 10 2024]

  • ENHANCED: Removed accessing Prolog data using relative addresses This patch removes accessing Prolog data using relative addresses to the stack bases. This was long ago introduced to facilitating access to all memory on 32-bit systems using multiple threads.

    Now all prolog data is 64 bits, also on 32-bit systems and hence we can access all memory using a tagged pointer.

[Apr 24 2024]

  • PORT: Deal with Android android-execinfo library.

[Apr 17 2024]

  • FIXED: generation of swipl.pc pkg-config file Now uses LIBSWIPL_DIR to get the correct -L flag when the system is installed as global library.

[Apr 16 2024]

  • FIXED: Reconsult when the loaded code sets the trace flag on a predicate. This was due to a conflict over the predicate flags. As the flags field was widened, we can avoid these problems.

[Apr 12 2024]

  • PORT: #1265 Deal with static_assert() after label

[Apr 10 2024]

  • FIXED: WASM: fix fid arg position in this.query call in __call_yieldable
  • FIXED: #1262 upcase_atom/2 and friends on ISO -> wide If input is ISO-Latin-1 and the converted character requires wide characters the system trapped an assertion error. Now correctly converts to wide characters.
  • FIXED: Clang handling of max_integer_size Clang cannot handle setjmp()/longjmp in PL_next_solution(), but it can in the simple evalExpression() function. This does not have measurable impact on performance, so we enabled this as default. This fixes limiting the integer size for WASM and Clang builds on Linux. This problem did not surface on the MacOS version.

[Apr 9 2024]

  • FIXED: Compute new stack size when we reach the limit. Suffered from integer overflow on 32-bit machines and got several edge cases wrong.

[Apr 8 2024]

  • CLEANUP: Allow for gcc -Wconversion With 64 bit word it is easy to get conversion errors. Compiling with -Wconversion helps tracking these.
  • FIXED: comparison of MPZ and MPQ with 64 bit integers if long is 4 bytes
  • FIXED: Push string when stack > 128Mb on 32-bit hardware
  • DEBUG: Added scripts/gdbinit Share gdb script with useful debugging commands. [no ci]
  • FIXED: Normalize LibBF numbers created from 64 bit integers on VS2022 VS2022 does not support 128-bit integers and therefore we must use 32-bit "limbs"

[Apr 5 2024]

  • PORT: VS2022: void* arithmetic, wrong order for SIZEOF_WORD

[Apr 3 2024]

  • FIXED: forAtomsInClause() handling of B_*_?C instructions These called PL_unregister_atom() on the atom, rather than the argument function.

[Mar 28 2024]

  • FIXED: DEBUG(CHK_SECURE) clean of memory (wrong size)

[Mar 27 2024]

  • FIXED: Type handling in copy_term/2 and friends.
  • ADDED: PL_atom_index() and PL_atom_from_index() Turn atoms into small objects that can be combined with other pointer sized objects with space for a tag.
  • BUILD: Respect $CFLAGS and $CXXFLAGS in a CMake build types

[Mar 18 2024]

  • CLEANUP: Get rid two definitions for trail entries

[Feb 1 2024]

  • CLEANUP: Prepare hash tables for the M64 data model This huge commit changes pl-table.c to be word -> word rather than void* -> void* as we plan to make words 64 bit, also on 32 bit systems. This patch also introduces 4 table types, TableWW, TableWP, TablePW and TablePP. These tables map between words and pointers in all 4 possible ways.

    This patch also involves small cleanups and fixes encountered while reading the code and use FOR_TABLE() everywhere, removing the old for_table() macro.

[Mar 29 2024]

  • FIXED: prototype for get_string_text()
  • FIXED: make markAtomsOnGlobalStack() safe This could crash on all platforms. It is notably dangerous using the experimental O_M64 model.

[Apr 5 2024]

  • TEST: Disable max_integer_size test for emscripten Doesn't handle longjmp() correctly in release mode. Works in debug mode, but that is not useful.

[Mar 31 2024]

  • FIXED: write clauses holding > 0xffff Unicode chars in strings to QLF on Windows.

[Apr 3 2024]

  • FIXED: forAtomsInClause() handling of B_*_?C instructions These called PL_unregister_atom() on the atom, rather than the argument function.

[Mar 29 2024]

  • FIXED: Temp buffer handling when stack is close to top of address range

[Mar 28 2024]

  • DEBUG: Fixed chk_secure report on invalid term due to PushPtr()/PopPtr() This construct to turn raw pointers into term references to preserve them during GC can create referenc pointers to the local stack. Another possible fix is to turn such references into direct term references. That avoids local stack references, but as this is only used around GC and GC itself uses local stack reference pointers, there is little to gain.

[Mar 27 2024]

  • FIXED: unifiable/3 internal consistency Unifiable did not correctly handle stack resizing. This is detected when running using chk_secure. Not sure whether it can also cause real issues, but the new code is simpler and safe.

[Mar 26 2024]

  • FIXED: powm/3 function: wrong type check on 3rd argument.
  • FIXED: Declaration of term stack for evaluating expressions
  • FIXED: Write bignums when inside arithmetic. Should normally not be needed, but debugging is much easier if we can.

[Mar 25 2024]

  • PORT: Avoid spurious warnings from spoiling pthread_setname_np() test This used to use -Werror to ensure a compiler failure if the number of arguments do not match the prototype, but this is already enforced in todays compilers.
  • FIXED: use_module/2 with except and reexport/2 with except to print warning These predicates failed if the source did not export the excluded predicate. Now it prints a warning and ignores the non-existent predicate.

[Mar 24 2024]

  • DEPRECATED: Sseek(), Stell()
  • FIXED: Another fileno issue.
  • ADDED: library(sandbox): allow for Dict.get(key,Default)
  • FIXED: Stream initialization for swipl-win.exe Was broken since recent changes keeping track of fileno. Reported by Jan Burse.

[Mar 23 2024]

  • ADDED: PL_system_error() This patch also adds documetation for PL_fatal_error().
  • ADDED: Prolog flag max_integer_size This flag limits the allocations on behalve of bignum and rational number processing, DoS attacks by exhausting memory using huge numbers as well as poor interrupt handling due to lack of signal handling inside the bignum libraries.
  • ENHANCED: Use temprary malloc API for bignum arithemetic
  • ENHANCED: Keep small bignums on the stack
  • CLEANUP: Simplify arithmetic context This is no longer nested and can (thus) be simplified.
  • FIXED: format/3: Ensure balanced AR_BEGIN()/AR_END() On errors it was possible that AR_END() was not called. This may lead to memory leaking and errornous operation when linked in a process that also uses gmp.

[Mar 21 2024]

  • ENHANCED: Improve memory reuse after writing huge integers.

[Mar 18 2024]

  • FIXED: #1254 crash in PL_get_mpq()

[Mar 15 2024]

  • FIXED: tell/1: properly manage standard stream references.
  • FIXED: Stream reference counting and reset when closing a standard stream.
  • FIXED: Memory leak in string_bytes/3.
  • FIXED: Properly close temporary redirect to a string tellString()/toldString() could fail to reclaim the temporary stream object.

[Mar 14 2024]

  • ENHANCED: Use a segmented stack for dealing with findall/3. This avoids memory fragmentatation when findall/3 is deeply nested. Although that is a rare occasion, deeply nested findall/3 leads to poor memory reuse. As activating and deactivating is stacked anyway, a segstack avoids the fragmentation.
  • ADDED: help(Name/Arity): handle user predicates.
  • FIXED: xref_source/2: keep processing PlDoc commants after including a file.

[Mar 13 2024]

  • ADDED: help/1: give help on a specific user predicate using Module:PI.
  • ENHANCED: help/1: filter user predicates on the module class. This use to filter on whether they are documented in the manual, making it impossible to show documentation for loaded predicates that conflict with something defined in the manual.
  • FIXED: Thread I/O streams may be invalid If a thread is created using thread_create/3 with the inherit_from(Thread) option or using PL_thread_attach_engine() (which inherits from main), we may copy current_input or current_output from a temporary redirect.

    The reference counting when copying the streams was broken, possibly causing memory corruption. This is improved, but not 100% safe. However, we now set the current_input and current_output to user_input and user_output, which typically never change.

[Mar 12 2024]

  • FIXED: help/1 to deal with help on public predicates in included files. help/1 finds the predicate and, if necessary, reloads the file in which it is defined to get the documentation. If the predicate is defined in an include file it should reload the main file to get the module context right.

[Mar 11 2024]

  • ENHANCED: trace/1,2 and friends. - Code cleanup - Support conditional trace using trace(Head, Port(Condition))

[Mar 12 2024]

  • FIXED: Ensure correct setting file handle for std streams. This was broken after adding the fileno field to the IOSTREAM struct.

[Mar 11 2024]

  • MODIFIED: Discontinue thread_exit/1 on Windows The implementation was broken for some time. The reason is not entirely clear, but possibly related to issues in pthread-win32. As the predicate is unsafe and deprecated anyway, it has now been removed from the Windows version.

[Mar 10 2024]

  • FIXED: pack metadata checking for prolog:Feature requirements.

[Mar 7 2024]

  • FIXED: make stream_property(S, file_no(N)) safe. This used to be subject to race conditions between the enumerating thread and threads that close the underlying stream. We now copy the file handle as it was found when creating the stream to the main stream structure.

[Mar 6 2024]

  • CLARIFIED: PL_free_blob() can be called multiple times. This patch changes subsequent calls to a no-op that returns FALSE and document this is valid. After comment by Peter Ludemann.

[Mar 5 2024]

  • CLEANUP: Do not call blob release() on GC or cleanup after PL_free_blob()

[Mar 4 2024]

  • ENHANCED: Answer/query expansion. Toplevel variable ($Var) handing is now always handled, regardless of the expand_query/4 or expand_answer/2 hooks. The expand_answer/2 hook is superseded by expand_answer/3.
  • DOC: Deprecate format/3 with a non-list 3th argument.

[Mar 3 2024]

  • FIXED: Setting the C-stack limit to values not a multiple of the page size Causes problems on some platforms.

[Mar 2 2024]

  • DOC: Use ASCII LaTeX ``word''
  • FIXED: Preserve atributes set on foreign functions for saved states. This bug causes http_stream:stream_range_open/3 not be to transparent when reloaded from a saved state. This in turn raises an error with http_open/3 on HTTPS and chunked streams.

[Mar 1 2024]

  • ENHANCED: coverage/2: analyze and annotate included files. The coverage analyzer now deals with files that are included. Files that are included multiple times in different modules get their numbers aggregated.
  • FIXED: Crash when using '$cov_data'/3 if there is no coverage data.

Package bench

[Jan 18 2025]

  • ENHANCED: Benchmark comparison suite. Be more relaxed on missing systems and allow adding new systems without changing the sources. See README.md

Package debian

[Nov 12 2025]

  • RELEASE: Merge development version

[Jul 22 2025]

  • PPA: Updated to support xpce based GUI This deletes the Qt console (swi-prolog-win package) and replaces the X11 dependencies with SDL+cairo+pango.

[Sep 7 2024]

  • PORT: Added qtbase5-dev as alternative to support teh Qt compole for focal and bionic

[Aug 29 2024]

  • ADDED: Debian/PPA package swi-prolog-win This package provides the Qt console.

[Aug 7 2023]

  • ADDED: dependency on Python itself. Although a dependency on libpython3-dev is good enough, cmake cannot find the Python conponents without Python.

[Aug 2 2023]

  • ADDED: Python3-dev dependency

[May 24 2021]

  • PORT: use PGO for the Ubuntu PPA build.

[Mar 12 2019]

  • INSTALL: Use -DJNIDIR=$(JNIDIR), leaving installation of libjpl.so to CMake.

Package archive

[Sep 30 2025]

  • CLEANUP: Avoid undefined warnings for gcc -O3

Package bdb

[Nov 12 2025]

  • PORT: Honour LIBBDB_ROOT_DIR cmake variable

[Sep 30 2025]

  • CLEANUP: Avoid undefined warnings for gcc -O3

Package chr

[Oct 27 2025]

[Jan 22 2025]

  • MODIFIED: Only perform CHR expansion when loaded in the context. Restrict CHR term expansion to modules into which library(chr) has been imported.

Package clib

[Nov 19 2025]

  • ADDED: process_create/3: specify program as prolog(Tool) This allows Prolog running one of its tools, with the guarantee that we use the tools from the same version. This provides a hook prolog:prolog_tool/4 that allows embedded systems to redefine how the Prolog tools should be executed.

[Nov 6 2025]

  • FIXED: Make library(uuid) work properly if autoloading is disabled.

[Oct 20 2025]

  • DOC: Document some types for lirary(uri).

[Oct 10 2025]

  • FIXED: crypt/2 on Windows using bsd-crypt.c: possible memory corruption.

[Oct 9 2025]

  • FIXED: urn-schema URIs can have a query and fragment field.

[Oct 8 2025]

  • MODIFIED: library(uri) to raise more exceptions and support URNs.

[Jun 9 2023]

[Sep 30 2025]

  • CLEANUP: Avoid undefined warnings for gcc -O3

[Jun 19 2025]

  • COMPAT: Use new PL_dispatch() API.

[May 23 2025]

[Jan 23 2025]

  • PORT: Provide SWIPL_WINDOWS_NATIVE_ACCESS for 9.3.19

[Jan 13 2025]

  • TEST: Fixed broken test for Prolog streams.

[Dec 28 2024]

  • PORT: Support inet6 on NetBSD

[Oct 2 2024]

  • COMPAT: Support both old and new abort exception

Package cpp

[Nov 24 2025]

  • FIXED: compiler warnings for print formats

[Jun 22 2025]

  • PORT: Deal with new PL_prompt_string() and PL_prompt_next() API.

[Jun 19 2025]

  • COMPAT: Use new PL_dispatch() API.

[Apr 11 2025]

  • FIX: pointer to local stack

[Apr 3 2025]

  • ENHANCED: improved C++ exception hierarchy Changed the exceptions thrown by PlEngine and PlFrame so that they're safe to use outside the try...catch context; and provided a way to make all other exceptions safe outside a Prolog frame.

Package http

[Nov 23 2025]

[Oct 27 2025]

[Oct 24 2025]

  • PACKAGE: Remove JSON files from this package The JSON support is moved into a new package json

[Oct 17 2025]

  • ADDED: Support HttpOnly and Secure cookie properties in http_session.pl http_set_session_options/1 now supports the http_only(true) and secure(true) options, adding these properties to the session cookie. Both default to false for compatibility reasons.

    Suggested by Mohammed Almutawah to mitigate XSS scripting in SWISH.

[Sep 30 2025]

  • FIXED: Possible uninitialized variable (in error case)
  • SANDBOX: Declare Quasi Quotations for json, html and javascript as safe.

[Sep 28 2025]

  • ADDED: json quasiquotation syntax This allows for embedding JSON documents represented as a Prolog dict using e.g.
    ?- X = 10, D = {|json(X)||{"x": X}|}
    D = _{x:10}.

[Jun 15 2025]

  • ENHANCED: Use url(URL) for HTTP startup message.

[Jun 13 2025]

[May 2 2025]

  • FIXED: json_skip_ws/3: Pass exception.
  • FIXED: http_open/3: when applying a transfer filter, do not close the output Instead, create a new stream pair from the transfer filter stream and the output stream.

[Apr 29 2025]

  • SECURITY: Make http handlers read remaining request data for Keep-alive When using a Keep-alive connection the core HTTP infrastructure now ensures that, if the request has a request body (Content-length) exactly this number of bytes is read from the input before returning the stream to the Keep-alive mechanism.

    This prevents crafted content to generate additional HTTP requests.

  • FIXED: http_open/3: only catch error(Formal, Context).
  • FIXED: Multipart reader to update stream position data of parent stream. This is a tentative fix, lacking a test case. It still looses the line count/pos. That could be fixed by calling S__fupdatefilepos_getc() on all processed data.

    See https://swi-prolog.discourse.group/t/multipart-open-does-not-advance-the-streams-pointer/8965/3

[Apr 7 2025]

  • PORT: Avoid partial lists in DCG rules (ISO compliance)

[Apr 3 2025]

[Apr 2 2025]

  • FIXED: term//1: possible exception on compound_name_arity/3. This happened when spacing around operators need to be computed and the left or right hand of the operator is a blob.

[Mar 29 2025]

  • FIXED: Running out of file descriptors if device for log files is full. This patch is a serious cleanup of error handling in the HTTP log library.

[Mar 27 2025]

  • ADDED: Provide cross-referencing hooks for :- html_meta(+Decls)

[Mar 20 2025]

  • FIXED: #168 http_daemon/0,1: exit with status 0 The startup was translating all exceptions into halt(1). That is wrong after halt is implemented as throw(unwind(halt)).

[Mar 17 2025]

  • FIXED: library(http/jquery): support Qlf compilation ensure_jquery/1 cannot use conditional compilation. We must use a runtime conditional instead.
  • CLEANUP: Avoid demo dependency on xpce.

[Mar 14 2025]

  • FIXED: term//2: make operators a trigger.
  • FIXED: term//2: portray(true) implies numbervars(true).

[Jan 26 2025]

  • ENHANCED: Ensure the HTTP worker disables tracing before starting the next request. This avoids what seems spurious activation of the debugger because the user finished debugging some request and the debugger is started immediately on a possibly unrelated request.

[Jan 17 2025]

  • FIXED: Handle HTML error replies that contain non-ASCII. HTML error replies are now sent using UTF-8 encoding. This patch also includes more careful computation of the length of replies, resulting in exceptions rather than claiming the wrong length on invalid input.

[Jan 3 2025]

  • DOC: spellchecked documentation

Package libedit

[Nov 17 2025]

  • PORT: Clean compilation on MSVC

[Nov 16 2025]

  • PORT: Allow using bundled libedit This is the default. The system version can be selected using cmake -DSYSTEM_LIBEDIT=ON. This should simplify building

[Nov 12 2025]

  • ADDED: el_set/2 to set the word characters This replies on el_wset() using EL_WORDCHARS that is provided in some recent copies of libedit. When available, it is used to set the word chars to only "_" (in addition to iswalnum()).

[Nov 11 2025]

  • FIXED: Avoid full refresh in Epilog windows on each action. Failed to reset the refresh request. Refreshing causes issues with wrapped lines.
  • FIXED: Synchronise Epilog window size changes with libedit.

[Nov 3 2025]

  • FIXED: Signal handling Detecting this is the main stdin we are reading from failed since we use dup() on the file handles to avoid closing them. We now add this fact to the context, initiated before the dup().

[Nov 2 2025]

[Nov 1 2025]

  • ADDED: Extended el_history/2 with more actions. This allows for querying individual events, setting the notion of current, and searching the history.

[Oct 31 2025]

  • ENHANCED: Read old swipl-win.exe history data in current version.
  • MODIFIED: el_read_history/2 to raise an error if the history file is invalid.

[Oct 29 2025]

  • PORT: Compile if H_SAVE_FP is lacking

[Oct 28 2025]

[Oct 23 2025]

  • ENHANCED: Support thread signal processing while reading from Epilog. This is required to prevent the Debug menu of Epilog from deadlocking the application. It also allows e.g., timers to function in Epilog consoles. Note that signal processing already worked in non-Windows environments.

[Oct 17 2025]

  • ADDED: el_version/1 to get the version of the editline library used.

[Sep 30 2025]

  • CLEANUP: Avoid undefined warnings for gcc -O3

[Jul 3 2025]

  • ADDED: Support winlibedit hook to get the terminal size. This allows fetching the terminal size for Epilog on Windows.

[Jul 2 2025]

[Jun 30 2025]

  • ENHANCED: Use autoload_call/1 to avoid undefined errors.
  • FIXED: Read multi-byte characters on non-Windows.

[Jun 28 2025]

  • ADDED: Support Windows pipe handles for I/O This is work in progress to support Epilog on Windows. It consists of changes to our winlibedit port of libedit. These changes do not use Console mode setting and read using ReadFile() rather than ReadConsoleInput().

[Jun 22 2025]

  • PORT: Support Windows

[Jun 23 2025]

  • COMPAT: Update for new signature for PL_prompt_string() and PL_prompt_next()

[Jun 19 2025]

  • COMPAT: Use new PL_dispatch() API.

[Jun 17 2025]

  • ENHANCED: el_wrap/4 to raise an error if the stream is already wrapped.
  • FIXED: Avoid memory leak on FILE structs created by fdopen()
  • FIXED: el_history/2: handling of setsize() was undefined.

[May 28 2025]

  • ADDED: Allow using the (integer) fd to specify the editline instance This allows accessing the history of other threads.

[May 26 2025]

  • ENHANCED: Sync the positions of the terminal streams.

[Jan 22 2025]

  • ADDED: ^Y to paste as quoted.

[Oct 6 2024]

  • FIXED: Avoid deadlock when trying to save history from a background thread.

Package ltx2htm

[Jan 14 2025]

  • ADDED: \keyitem{Key}{Value} for describing keys of a dict

Package mqi

[Sep 27 2025]

  • PORT: Search for python3 executable to try python3 and then python. Modern systems are beginning to install only python, which is Python3.

    There isn't any support for python2 anymore, since 2020, and the windows installer does not install a python3.exe.

Package odbc

[Sep 30 2025]

  • CLEANUP: Avoid undefined warnings for gcc -O3 Also replaces local error functions with calls to PL_*_error()

[Jan 23 2025]

  • PORT: Incude windows.h, needed for SWI-Prolog 9.3.19 and up This is required as SWI-Stream.h no longer includes the windows header.

Package pengines

[Jan 15 2025]

  • ADDED: add HTTP path alias pengine. This allows for modifying the location on a pengine server.

[Oct 2 2024]

  • COMPAT: Support both old and new abort exception

Package pldoc

[Nov 19 2025]

  • FIXED: Emit LaTeX for markdown code text that holds % in tables.

[Nov 3 2025]

  • FIXED: Load when threads are disabled.

[Oct 27 2025]

[Apr 21 2025]

[Mar 31 2025]

  • ADDED: PlDoc to LaTeX converter: file_synopsis(Text) option Allows for overwriting the default synopsis. Used to document some not-installed libraries.

[Mar 29 2025]

  • ADDED: Support "=" mode. This is a proposal in the PIP meetings to deal with "Output" arguments.

[Jan 22 2025]

  • ADDED: Allow copying the predicate name or mode from the manual.
  • ENHANCED: Allow copy of the synopsis text :- use_module(...). Also improve _(can be autoloaded)_ message.

Package plunit

[Oct 27 2025]

Package semweb

[Sep 30 2025]

  • CLEANUP: Avoid undefined warnings for gcc -O3

[Feb 13 2025]

[Jan 4 2025]

  • ASAN: Avoid runtime errors. All "fixed" issues are benign

[Jan 2 2025]

  • DOC: spellchecked documentation

Package sgml

[Sep 30 2025]

  • CLEANUP: Avoid undefined warnings for gcc -O3

Package ssl

[Sep 30 2025]

  • CLEANUP: Avoid undefined warnings for gcc -O3

Package swipy

[Feb 2 2025]

  • DOC: #16 Document usage on MacOS using SWI-Prolog.app.

[Jan 11 2025]

  • TEST: Added tests for pytest of the Python module.
  • FIXED: Import janus_swi explicitly as janus This is needed when Prolog is embedded into Python.

Package table

[Sep 30 2025]

  • CLEANUP: Avoid undefined warnings for gcc -O3

Package tipc

[Sep 30 2025]

  • CLEANUP: Avoid undefined warnings for gcc -O3

[Oct 2 2024]

  • COMPAT: Support both old and new abort exception

Package utf8proc

[Nov 14 2025]

  • PORT: Compile using MSVC

Package xpce

[Dec 2 2025]

  • ADDED: PceEmacs C-mode: declaration of keywords.
  • ADDED: syntax_table->keywords to register known keywords for a syntax

[Dec 1 2025]

  • MODIFIED: Generalised text_buffer->for_all_comments Replaced by text_buffer->for_all_syntax, which qualifies additional syntax types. Currently only quoted material.
  • ADDED: Support for multi-character line comment lead-in (e.g. // comment)
  • MODIFIED: syntax_table->prolog: bool replaced by syntax_table->language
  • ADDED: `text_buffer<-lsp_offset(line,character) --> offset Translate position in LSP notation to an offset.
  • ADDED: text_buffer<-lsp_column Produces the character field of an LSP range start/end. This is the position inside the line in UTF-16 code points.

[Nov 29 2025]

  • ENHANCED: editor->align_line to avoid modifications if alignment is already satisfied.
  • FIXED: text_buffer->insert not to set modified if we insert 0 times.
  • ADDED: PceEmacs: M-x idle-timeout seconds Sets the time we wait before re-running semantic highlighting.

[Nov 28 2025]

  • ADDED: PceEmacs: hooks to allow syncing to an LSP server

[Nov 24 2025]

  • ADDED: Class text_buffer to allow forwarding changes incrementally This implements methods to generate LSP (Language Server Protocol) compatible incremental change events. The basic method is text_buffer<-lsp_changes, which returns a chain of text_change objects that provide the changed range and replacement text.

[Nov 17 2025]

  • PORT: Fixed emulation of C11 atomic_compare_exchange_strong()

[Nov 14 2025]

  • PORT: Compilation in MSVC This is only a partial port to MSVC. It does fix several issues though.
  • FIXED: If there is no gui, do not setup xpce for lazy loading.

[Nov 12 2025]

  • PORT: Hack around MacOS oddities to get SIGWINCH
  • PORT: Make compilation succeed if SIGWINCH is not defined.
  • FIXED: Message handling. Broke emacs/0. Reported by @mike.elston

[Nov 11 2025]

  • FIXED: swipl-win to handle interrupt in the console that started swipl-win. What should we do if there is no terminal, i.e., if swipl-win is started as app directly from the GUI? It should not get interrupt signals in that case, but what if it gets one anyway?
  • ADDED: Epilog: use pthread_kill() to update client thread of window size change. This fixes resizing Epilog windows cooperation with libedit. To work correctly, the libedit package must be updated as well.

[Nov 9 2025]

  • ENHANCED: Detection of when to load library(pce).

[Nov 7 2025]

  • ADDED: Epilog: Shift-Ctrl-M to inject make/0.
  • MODIFIED: Removed all PostScript related support This was non-functional anyway. The Cairo graphics is used to implement graphical->pdf for generating PDF. This functionality is still rather minimal. It will be extended in the future.
  • FIXED: Colour for class int_item up/down arrows. And some code cleanup.

[Nov 6 2025]

  • ENHANCED: class font_item to reflect current possibilities better.
  • ENHANCED: Updated PceDraw - Use native file dialog for save, load and export - Remove windows metafile support - Replace Postscript output with PDF - Disable printing. Not supported by SDL and not very important.

[Nov 5 2025]

  • DOC: Revive the XPCE User Guide This commit re-adds the Makefile, updates the Prolog helpers and minimal updates to reflect some aspects of XPCE version 7 in the documentation.

    Eventually the build process must be migrated to CMake, most images should be regenerated and the text reviewed and updated where needed.

  • ADDED: graphical->pdf to write PDF to a file
  • FIXED: Always enable color on the Epilog consoles.

[Nov 4 2025]

  • ENHANCED: Start Epilog file dialog in working directory.
  • ENHANCED: Make Quit Prolog the default button for confirming close with open windows.
  • ADDED: Allow inspecting the GUI hierarchy from Epilog.
  • ADDED: pce_show_visual_tool/0 to library(man/v_visual). This allows showing the GUI inspector stand-alone.
  • FIXED: Block other Prolog threads while a window is being redrawn. Modifying graphics while a redraw is in progress may result in inconsistent graphics or crashes.

[Nov 3 2025]

  • FIXED: Thread specific module and context object. These two global variables are used in the xpce interface predicates to keep track of the context. As xpce allows access from multiple threads they must be thread specific.
  • FIXED: Exclude files that require threads for single threaded version.

[Nov 2 2025]

  • FIXED: Ensure Prolog exceptions are propagated through xpce.
  • FIXED: Epilog: save history in all scenarios This covers closing the main window using the menu, window close button, Ctrl-D, Shift-Ctrl-W.

[Oct 31 2025]

  • ENHANCED: Epilog: use native file dialog

[Oct 30 2025]

  • ADDED: frame<-open_file and frame<-save_file: use OS dialog to prompt for a file. These new methods use SDL3's interface to file dialog windows to ask for a file for reading or writing. Tested to work on MacOS, Windows and Fedora using Gnome.

[Oct 28 2025]

  • ENHANCED: Do not load theme based on display<-theme if a theme was already loaded.
  • FIXED: Use-after-free in frame<-confirm Also allows this method to run from any thread.

[Oct 27 2025]

  • ENHANCED: Show fragment icons vertically aligned in the line.
  • COMPAT: Use new message_action/2
  • FIXED: Show breakpoints in PceEmacs and GUI tracer No longer rely on messages. There is a problem with the message system where user:message_hook/3 is both used to redirect messages and to act on messages. The latter are hooks that fail, the first are hooks that succeed. It might be better to have two hooks.
  • FIXED: Possible use-after-free

[Oct 26 2025]

  • MODIFIED: Epilog terminal to follow links on Ctrl-click Used to be simple click. This causes too much unintended actions. Using Ctrl-click is consistent with other terminal emulators.

[Oct 24 2025]

  • FIXED: Use-after-free graphical->unlink destroys its `<-layout_interface`, i.e., the table_cell. Using a code reference delays the actual deallocation.

[Oct 23 2025]

  • ENHANCED: Avoid deadlocking Epilog if thread is not sensitive to signals.
  • MODIFIED: Windows: open Epilog pipe in client using FILE_FLAG_OVERLAPPED This patch must be combined with updating the libedit package.
  • FIXED: Thread-safety for passing raw Prolog terms through xpce

[Oct 22 2025]

  • FIXED: Erroneous transfer for xpce references.
  • FIXED: Allow frame->wait to be called from any thread.
  • FIXED: Make the AnswerStack thread local.

[Oct 21 2025]

  • FIXED: Invalidate source location cache after reloading a file. Broken after introduction of atomic reconsult that preserves clauses as much as possible.
  • FIXED: Memory management for frame<-confirm and friends.
  • ADDED: GUI Tracer to show details and copy constraints Cycles and constraints displayed in the Bindings sub-window now support the Details and Copy functionality.

[Oct 20 2025]

  • ENHANCED: do not trace switching the GUI tracer on/off.
  • ADDED: Epilog: Debug menu.
  • ENHANCED: Epilog message capturing. swipl-win: make sure all messages printed to the main thread end up in an Epilog window.
  • FIXED: Possible use-after-free
  • FIXED: Possible use-after-free

[Oct 16 2025]

  • FIXED: Read beyond the end of local array. May lead to invalid UTF-8 sequences and corrupted terminal output.
  • FIXED: Possible memory corruption.

[Oct 12 2025]

  • FIXED: Epilog: correctly handle \e[@. This escape sequence is used for inserting into the commandline. Its default should be 1 rather than 0. This fixes inserting into the commandline, notably on Windows.
  • FIXED: Various encoding issues in class file.

[Oct 7 2025]

  • FIXED: Lazy binding of Prolog methods was not thread-safe.

[Oct 1 2025]

  • FIXED: Make double and triple click in Epilog copy the selection properly. This set the selection twice from an event, which apparently causes SDL3 to reset the selection.
  • FIXED: Incremental search backspace handling

[Sep 30 2025]

  • CLEANUP: Avoid undefined warnings for gcc -O3

[Sep 26 2025]

  • FIXED: Emacs mark+move cursor to maintain an active selection.

[Sep 24 2025]

  • FIXED: Correctly handle UTF-8 console output if the buffer ends with an incomplete UTF-8 character.

[Sep 23 2025]

  • FIXED: PceEmacs: make shift-caret movement extend the selection. Selection is now deactivated without shift.
  • FIXED: Resizing the thread monitor too small leads to a type error. Reported by @mike.elston

[Sep 22 2025]

  • MODIFIED: Control the Prolog consoles using a single predictate set_epilog/1.

[Sep 21 2025]

[Sep 9 2025]

  • FIXED: Windows: Avoid that a popup causes loss of focus. Popups no longer grab the system focus, but instead use xpce's focus notion to forward events to the popup.

[Sep 3 2025]

  • FIXED: More careful display handling.
  • ADDED: Epilog console: make DEL key send \e[3~. This provides forward delete on Linux, but not on Windows. Probably the libedit port needs additional patching.
  • FIXED: Bind any key >= 128 to `->insert_self`
  • FIXED: Allow entering [] on Italian keyboards using Alt-gr. PceEmacs interpreted these as Alt-[], moving over a clause.

[Aug 27 2025]

  • FIXED: Gracefully handle failures to inspect changes to the attached displays.

[Aug 26 2025]

  • ADDED: Cursor home/end key support on all editable text.

[Aug 25 2025]

  • FIXED: frame->label: Allow using from any thread.
  • ENHANCED: Make a subwindow only get the input focus if ->_wants_keyboard_focus succeeds. This notably prevents loosing PceEmacs focus after a click in the menu.
  • FIXED: Use a method rather than a function call if a window looses focus. This allows the Prolog tabbed_window class to forward this event.
  • ADDED: PceEmacs: Shift-left-click extends the selection.

[Aug 24 2025]

  • ADDED: Class terminal_image event handling to extend the selection on SHIFT-click
  • FIXED: Make sure modifier buttons are set for mouse up/down events.

[Aug 23 2025]

  • FIXED: PceEmacs: make shift/control-cursor-keys work again. E.g. Ctrl-<cursor_right> moves by word and cursor movement with SHIFT enabled extends the selection.

[Aug 22 2025]

  • CLEANUP: Remove various tools from the manpce/0 window.
  • CLEANUP: PceEmacs: Remove Pce popup from Prolog mode
  • ADDED: epilog_insert_menu/2 and epilog_insert_menu_item/4. Compatible with old win_insert_menu/2 and win_insert_menu_item/4. These predicates let an application control the menus.
  • ADDED: menu_bar->append: before argument.
  • ADDED: Implement app config hook to set the window title. This sets the title when running swipl-win file.pl ...
  • ADDED: Epilog: Allow loading a file from the window popup.
  • ADDED: terminal_image<-url to get the link url from a location.

[Aug 20 2025]

  • FIXED: Use PceEmacs *Documentation* for help.
  • FIXED: PceEmacs popup for Documentation Run in Epilog window. Actually, we should use xpce to display the HTML.
  • FIXED: Class list_browser binding for backspace.
  • FIXED: Keyboard focus handling for completer windows. If there is a grabbing window, redirect all keyboard input to the grabbing window.
  • FIXED: class list_browser to handle arrow keys.
  • FIXED: Avoid destroying the completion browser. This is now a transient frame

[Aug 19 2025]

  • FIXED: When running as epilog, disable debugging the main thread.

[Aug 7 2025]

  • FIXED: Establish platform dependent resource defaults. This notably makes Apple keybindings default on MacOS.
  • ENHANCED: class terminal_image to use methods for copying This allows for redefining terminal_image->copy.
  • FIXED: UTF8ToString() created a name for ASCII strings.

[Aug 6 2025]

  • FIXED: Locking for Windows.
  • CLEANUP: Simplify and share locking code between Windows and POSIX
  • FIXED: Make all xpce stack related variables thread specific.

[Aug 5 2025]

  • FIXED: Support multiple threads in xpce variable handling This patch makes @arg1, etc. supporting multiple Prolog threads making progress.
  • FIXED: Possible variable block corruption in expression evaluation.
  • ADDED: Implement selection for class text.
  • FIXED: Feedback for class path selection when using dark theme.
  • FIXED: re-colour bitmaps to fore and background. Accessed @nil as colour.
  • FIXED: Releasing and reacquire the xpce global lock. Caused incorrect lock counts if the lock was held by another thread when called.
  • FIXED: Deadlock after new/2 fails due to module error.
  • BUG: Temporarily disabled library(pce_unclip). Getting this to work requires changes due to modern restrictions of event grabbing.

[Aug 4 2025]

  • CLEANUP: Track frame position relative to its display.
  • ADDED: Process keypad command keys when not in numlock mode.
  • ENHANCED: Draw window initial content before showing the window.
  • ENHANCED: When hovering a menu bar, first open the next popup before closing the old. This avoids flickering the main window due to regaining/loosing focus.
  • FIXED: Honour frame->input_focus if there is a subwindow that has defined a keyboard_focus.
  • FIXED: Windows handling multiple epilog windows.
  • MODIFIED: Handle Alt-right (Alt-Gr) as possible text input.
  • FIXED: Possible crash in click detection.

[Aug 3 2025]

  • ENHANCED: Better font defaults and allow controlling the fonts via CMake.
  • DOC: Updated Defaults.user with information on how to map fonts.
  • FIXED: Font viewer (swapped arguments)

[Aug 2 2025]

  • FIXED: Deal with distinguishing text input from other keyboard events.
  • FIXED: Allow or Unicode strings in resource files.
  • FIXED: Start fontviewer from scratch
  • FIXED: PceDraw attribute editor failed to open.
  • FIXED: Dark theme: draw selection handles using the foreground colour. Used to be fixed to black. Also fixed class bezier that has its own code.

[Aug 1 2025]

  • FIXED: Windows pipe size for epilog threads. This seems to fix two issues: much faster console output and no more pending output.
  • FIXED: Thread monitor called between/3 using a float. This is due to fonts that now have float sizes.
  • FIXED: Only reset xpce on aborts in the xpce thread.
  • FIXED: Invoking display->confirm with non-visual for argument.
  • ENHANCED: Allow frame->expose to be called from any thread.
  • ADDED: class(epilog) as application managing all epilog frames. The object @epilog can be used to find and act on existing epilog windows.

[Jul 31 2025]

  • ENHANCED: Debug message browser. Use close for closing the window, make help open the web page on library(debug) and provide a class variable for styling.
  • FIXED: frame->open_centered on systems that respect position hints.
  • ENHANCED: PceEmacs sgml mode to avoid dark blue. Makes it more usable with a dark theme.
  • FIXED: Avoid accessing SDL main functions for creating a window. This ensures no SDL restrictions are violated when creating an xpce window in a thread.
  • DEBUG: Add debugging code to verify we do not call any SDL function from the wrong thread.
  • ENHANCED: Ask the user what to do if the main console is closed.
  • ADDED: library(pce_openframes) Checks still open frames and allow the user to act on them.
  • ADDED: Set the SDL_VIDEO_DRIVER from a Prolog flag. This allows controlling the video driver without using the environment.

[Jul 30 2025]

  • ADDED: Type num. This is the next step in migrating the non-object type Int to support floating point numbers. As yet, the type may be used but int and num behave the same except for conversion from class real and from a string.
  • FIXED: Cmd-+ to enlarge font on MacOS (set to default)
  • ADDED: Epilog support for rescaling the font.
  • FIXED: terminal_image->font to rescale the terminal.
  • ADDED: font<-rescale Also fixes the generated object reference to allow for sub-pixel sizes.
  • ADDED: Support frame->set when the window is visible. This allows for progamatic changes to the size and position of already open windows.
  • ADDED: Support updating the displays if a display is moved by the user.
  • FIXED: Exploit new prolog_trace_interception/4 halt This fixes halting from the GUI tracer.
  • PORT: Fixed building on Windows.

[Jul 29 2025]

  • FIXED: Removed normalise argument to ->open
  • ENHANCED: Capture xpce messages in the epilog console. This patch redirects direct console output and Prolog print_message/2 that would print to the Prolog console to an Epilog window. If the message is associated to a thread with an epilog window, use that. Else use the last used Epilog window or just any of them as last resort.
  • ENHANCED: Do exception handling for xpce's main loop.
  • ADDED: Change selection on cycle menus based on the mouse wheel.
  • FIXED: Placement of popup menus on secondary display on MacOS SDL's normalization of the window position on secondary displays is broken. This patch works around this issue.

[Jul 28 2025]

  • FIXED: Make Window creation display aware. On Wayland, new window positions are ignored, but Wayland creates new windows on the "active" display. On MacOS, windows are always created on the primary display unless we place them in the area of a specific display. Our code now tracks the "active" display and opens new windows on this display.
  • MODIFIED: Signatures for opening windows and frames. All these methods now have the signature
    ->open: [position], [display], [grab].

    We need to pass this display if we want to controll the display on which the window is opened.

[Jul 29 2025]

  • ENHANCED: Always enable hyperlinks in Epilog terminals.

[Jul 27 2025]

  • MODIFIED: Font handling This commit removes all outdated X11 oddities from class font and adds modern Pango based naming and behaviour. This adds support for explicit font weight manipulation. This commit also completely rewrites the FontViewer demo program, providing good insight in the available fonts and mapping to xpce.

    Applications using font aliases (fixed, normal, bold, etc.) should work as before. Applications that use explicit font/3 or font/4 terms must be updated in most cases. They keep working, but will often show the default normal font.

  • MODIFIED: Deleted normalised argument for ->open. SDL does not provide the required information and normalises itself.
  • THEME: Control the text colour of cycle menus.
  • FIXED: Type char now accepts the whole unicode range
  • FIXED: Release XPCE lock on method callback to Prolog.
  • FIXED: Avoid deadlock Release XPCE lock when doing I/O through Cprintf() and friends. When output is redirected to an Epilog window this causes a deadlock.

[Jul 26 2025]

  • ADDED: Allow specifying the Pango name and retrieving it.
  • FIXED: Tab handling Now using floats and using font<-avg_char_width rather than `<-ex` which is a height rather than a width.
  • ADDED: class(font)->list_fonts
  • MODIFIED: Migrated font resources from class display to class font.
  • MODIFIED: Removed font alias table from display. There is now a global table `@font_aliases`.

[Jul 25 2025]

  • FIXED: Avoid failure building manual index if methods are deleted.
  • CLEANUP: Deleted class monitor. Monitors are represented by instances of class display.
  • CLEANUP: Remove unsupported X11 selection interface details.
  • CLEANUP: Manu X11 specific details.
  • CLEANUP: Remove display->draw_in. Non-portable.

[Jul 24 2025]

  • FIXED: Support MacOS natural scrolling.
  • MODIFIED: Move theme setup from epilog to xpce initialization. As a result, not only swipl-win or epilog/0 listen to the theme, but any xpce application.
  • BUILD: Support older CMake versions Building xpce fails by not finding SDL3::SDL3 when doing compile configuration tests.

[Jul 22 2025]

  • ADDED: Allow user specified theme using display.theme resource. Add this to the GUI Preferences to force a theme. Use default to stop loading a theme file.

    display.theme: dark

  • FIXED: XPCE locking

[Jul 21 2025]

  • MODIFIED: The default image <-> kind is now pixmap.
  • ADDED: image->pixel support.
  • ADDED: Interpret monochrome images as bitmaps.
  • ADDED: Use syntax_table to describe word chars for the terminal.
  • ADDED: Terminal support for select_all.
  • ADDED: Epilog console support for triple-click
  • CLEANUP: Locking types
  • MODIFIED: display->{inform,confirm} Changed signature to Visual, Title, Format, ...
  • ENHANCED: Use system message box for display->{inform,confirm,report} Exploit SDL_ShowMessageBox(). Need to handle the title and window.
  • FIXED: Destroy SDL renderers for subwindows when unmapping a frame.

[Jul 20 2025]

  • ENHANCED: xpce cross referencer GUI Added class variables to support dark theme and show directory names more informative.
  • ENHANCED: Make size of cursor in open_look style a resource.
  • FIXED: Correct layout for text with leading or trailing spaces
  • ENHANCED: xpce demo for HSV colours Show the 3 closest matching named colours and show both the colour box and text in the target colour using the default background.
  • ADDED: colour<-distance to compute Ī”E₀₀ distance.
  • ADDED: @colour_list, providing the colour names in logical colour ordering.

[Jul 19 2025]

  • THEME: Make xpce profiler support dark theme. This also requires updating Prolog as there is the dark theme itself defined. This patch only adds class variables to the various colours rather than using hard coded values.
  • FIXED: Class list_browser: incremental search. Failed to grab keyboard
  • FIXED: Access NIL table cell.

[Jul 18 2025]

  • ENHANCED: Fixed dark mode for inspector.
  • ADDED: Resource text_colour for class text_item Allow for different colours for the label and text field.
  • FIXED: Overruling class-variables Failed if the class variable already appeared in the hash table.
  • ENHANCED: Image and text alignment of class toc_image
  • MODIFIED: Allow images of kind bitmap. If such an image is displayed, its black pixels are translated to the current foreground and its white pixels to the current background.
  • ADDED: Provide support for alpha channal to colours.
  • MODIFIED: Simplify the colour model. Remove all legacy X11 support and simply represent colours internally as uint32_t. RGB values are now communicated as integers in the range 0..255 (was 16 bits).
  • CLEANUP: Remove empty RAY backend
  • CLEANUP: Deleted class colour_map

[Jul 16 2025]

  • FIXED: insert key binding set handling of RET, TAB, etc.

[Jul 15 2025]

  • ADDED: Set the colour of accelerators in popup menus.
  • ADDED: Bind copy/cut/paste to Shift-Ctrl-{C,X,V}
  • ADDED: key_binding <-accelerator_label Moved from PceEmacs to extensions to library(pce_keybinding).
  • MODIFIED: Key-names for named function keys are now between angle brackets. This is consistent with Emacs, although some keys still have different names.
  • ADDED: Function key (F1..F12) mapping. These used to be called key_top_<n>. They are now called more conventionally `f1..f12`.
  • MODIFIED: key_binding<-binding to return a chain Old implementation just returned the first match. Now we return all key events for some function. This allows for rendering the preferred one, such as the one bound to an Apple command key.

[Jul 14 2025]

  • PORT: Use Apple Command key for save/copy/cut/paste.
  • MODIFIED: Sync common function keys with Emacs naming.
  • ADDED: Distinguish accelerator @nil from @default. Using @nil explicitly disables.

[Jul 13 2025]

  • ADDED: gui modifier, supporting Windows key or Apple command key.

[Jul 12 2025]

  • FIXED: possible crash in getRootGraphical()

[Jul 10 2025]

  • ADDED: Setup epilog theme from system preferences
  • CLEANUP: Remove a lot of duplicate declarations. Ongoing work.
  • ADDED: display<-system_theme Get the user theme preference

[Jul 9 2025]

  • FIXED: Init TERM when needed.

[Jul 8 2025]

  • FIXED: Ensure the "mouse tracking window" is not reclaimed.

[Jul 7 2025]

  • FIXED: MacOS sometimes reports a mouse-up associated to no window. As a work-around, we implicitly associate it with the window that got the last down event.
  • FIXED: Draw resize line correct on hires displays.
  • FIXED: Conversion of UTF-8 to xpce objects Converted always to UTF-16 rather than only on Windows.

[Jul 5 2025]

  • FIXED: Do not keep swipl-win open if there are only hidden or unmapped frames.
  • FIXED: window->redraw must invalidate rather than draw.
  • ENHANCED: gxref/0: do the heavy work in a background thread. This keeps the GUI responsive.
  • FIXED: Position logic for windows using a decorator displayed on other windows. Notably the cross-referencer uses this.
  • ADDED: Support cursors created from images.
  • FIXED: Colour browser interpretation of hash values. The current version adds the alpha channel.

[Jul 3 2025]

  • PORT: Fixed wide pce string <-> UTF-8 conversion. PceString is for now UTF-16 on Windows. We might change that, but for now we do UTF-16 <-> UTF-8 conversion that deals with surrogates.
  • ADDED: Add a line between resizable windows.

[Jul 2 2025]

  • FIXED: Avoid deadlock in Epilog paste on Windows. It appears WriteFile() blocks if there is no read in progress on Windows. As this must happen in the same thread, this does not work. We now use the sdlinput.c async I/O to also handle asynchronous writes.
  • FIXED: EOF and error handling on Windows pipes.
  • ADDED: display->list_fonts Temporary work-around. Eventually should return an xpce data structure.

[Jul 1 2025]

  • PORT: Make Epilog work somewhat on Windows. Requires git version of Prolog and latest version of winlibedit.

[Jun 28 2025]

  • ADDED: pce_open_terminal_image/4 to get access to the terminal client streams Using terminal_image<-pty_name does not work on Windows and we cannot safely transfer Windows HANDLE or Prolog IOSTREAM* over the xpce method API, so we need an additional predicate.

[Jun 26 2025]

  • PORT: Connect Windows PseudoConsoles to class terminal_image. This also adds terminal_image->launch, which allows running processes in the terminal.

[Jun 27 2025]

  • ADDED: Implement OSC 0 (window title) terminal escape

[Jun 19 2025]

  • COMPAT: Changed dispatch handling to pass an IOSTREAM that must be watched.

[Jun 17 2025]

  • PORT: Working on Windows port.
  • BUILD: Make -DSDL=ON the only option. This version of xpce no longer supports X11 and Win32
  • ADDED: Epilog Clear screen in popup.

[Jun 16 2025]

[Jun 15 2025]

  • FIXED: Get image file path

[Jun 14 2025]

  • FIXED: Input lag on stdin.

[May 24 2025]

  • ADDED: library(terminal): provide embedded terminal.

[May 23 2025]

  • FIXED: Removing watched streams

[May 22 2025]

  • ADDED: pce->open_url to use SDLs primitives for opening a URL.

[May 20 2025]

  • FIXED: Images may not be opaque even if they do not have a mask.
  • FIXED: Compute offset of graphicals to the frame when using nested window. This fixes the popup offset in PceEmacs.

[May 19 2025]

  • MODIFIED: Using @nil for an image background sets the background to transparent
  • FIXED: Avoid extra space around popup menus.
  • FIXED: Redraw after change of window size.

[May 18 2025]

  • ADDED: sdl_send() to execute messages on the SDL main thread

[May 10 2025]

  • MODIFIED: Removed several built-in bitmaps. Use colours for filling.

[May 5 2025]

  • TMP: This should be undone at some point.

[May 4 2025]

  • BUILD: Introduce src/namedb.txt to get smooth rebuilding if NAME_ changed

[May 3 2025]

  • PORT: Added SDL binding as stubs
  • ADDED: src/sdl dir for future SDL2 binding
  • PORT: Added empty new low-level binding. This binding aims at binding to raylib, but that is only refected in the name of the binding directory (src/ray). Otherwise it merely implements a completely empty binding based on stubs generated by ChatGPT.

[Apr 25 2025]

  • MODIFIED: WM_CLASS handling Recent desktop environments such as Gnome 46 and later ignore the _NET_WM_ICON property to set an icon for a frame (toplevel window). We can set the icon through a .desktop file using StartupWMClass where all windows of a process are bundled under the same icon. But, xpce set WM_CLASS from the xpce class name.

    This patch adds `display<->wm_class` to set the WM_CLASS for all toplevel windows. The default is SWI-Prolog. By setting this to @default, the old behavior is restored.

[Apr 23 2025]

  • FIXED: emacs/1: allow non-existing file. This also fixes ?- edit(file(File)) to create a new file as advertised.

[Apr 18 2025]

  • FIXED: Profiler IDE: link to website. Renamed "exit" to "quit", removed "statistics" (is shown anyway) and "about" (useless).

[Apr 11 2025]

  • PORT: Do not install Xserver.pl on Windows versions.

[Apr 10 2025]

  • COMPAT: Handle changes to '$qlf_sources'/2

[Apr 9 2025]

[Apr 7 2025]

  • PORT: Avoid partial lists in DCGs

[Mar 27 2025]

  • ENHANCED: PceEmacs: reload styles if new style facts are added. This is necessary if Prolog files that hold highlight declarations are loaded after creating the editor.

[Mar 26 2025]

  • BUILD: Build xpce library index before running qlf_make/0

[Mar 24 2025]

  • ENHANCED: PceEmacs: deal with possibly not-installed sources.

[Mar 22 2025]

  • FIXED: Add dependencies to make qlf compile work qlf_make/0 now reorders based on file dependencies. This means we can add the dependencies here and avoid hacks.

[Mar 19 2025]

  • FIXED: Load library(emacs_extend) explicitly in mode files This is required to ensure that the term expansion is applied when generating the .qlf files.

[Mar 18 2025]

  • CLEANUP: Remove pce_boot search path. Now using hard paths to resolve references between the various boot files.

[Mar 17 2025]

  • BUILD: Better support building .qlf files without an X11 display
  • CLEANUP: Removed forgotten HTTP implementation

[Mar 15 2025]

[Mar 10 2025]

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

[Feb 12 2025]

  • FIXED: X11 version: paste Unicode text

[Jan 22 2025]

  • FIXED: Avoid deadlock in display<-selection.

[Jan 4 2025]

  • PORT: Avoid -Wstringop-truncation warning.
  • PORT: Silence address sanitizer errors.

[Jan 3 2025]

  • MODIFIED: PceEmacs: sync comment commands with (my)GNU Emacs. - \C-c\C-h (insert_section_comment) Insert code section comment from prompted title - \C-c\C-q (insert_long_comment) Insert /* - - - .... - - - */ comment