Commit Graph
53 Commits
Author SHA1 Message Date
Skgland 8bc8171ec7 fix define_foreign_struct 2025-08-24 19:56:26 +02:00
Skgland 3b5b768f4a make ffi error structure not found point to the correct culprit 2025-08-24 19:56:26 +02:00
Skgland 176858ad42 fix map_ffi_arg 2025-08-24 19:56:26 +02:00
Skgland eba681786d make map_ffi_args a method and throw an instantiation error when encountering a variable 2025-08-24 19:56:25 +02:00
Skgland f4297e365f don't crash on empty list and differentiate list head not being string like 2025-08-24 19:56:25 +02:00
Skgland cd777294b9 use setup_call_cleanup/3 for with_locals
as suggested by triska
2025-08-24 19:56:25 +02:00
Skgland 3e929511bb add a test for with_locals 2025-08-24 19:56:24 +02:00
Skgland d1356db7e3 include a culprit in ffi_error 2025-08-24 19:56:24 +02:00
Skgland 7b2bf73ba1 fix with_locals 2025-08-24 19:56:24 +02:00
Skgland edd6d44bd6 require array_length to be > 0
C does not have 0-sized types
2025-08-24 19:56:24 +02:00
Skgland 4b5e4a2745 fix some things in ffi.pl
thanks triska for pointing out most of these
2025-08-24 19:56:23 +02:00
Skgland 3a4dfc46da add ffi helpers 2025-08-24 19:56:23 +02:00
Skgland d8346b1651 don't place allocate, read_ptr and deallocate between use_foreign_module and its helper predicates 2025-08-24 19:56:23 +02:00
Skgland 20d52c093a add ffi:{allocate,read_ptr,deallocate} 2025-08-24 19:56:23 +02:00
Skgland 35d34231f2 don't fail the build script if we couldn't parse a file
this way we get to the actual compilation in which rustc shouldl fail with a more helpfull error message
2025-08-24 19:56:17 +02:00
Skgland 633b86ddc4 make CI read msrv from Cargo.toml
instead of hardcoding it, so we have a single source of truth
2025-08-18 21:10:27 +02:00
Skgland 348c5029b3 reduce msrv back to 1.85 2025-08-18 20:52:15 +02:00
Skgland 6338a40eed fixup logtalk-test 2025-08-17 22:52:45 +02:00
Skgland 3aa272e44d explicitly pass the target to cargo-deb 2025-08-17 22:31:28 +02:00
Skgland 52f3ddd20d fix paths 2025-08-17 22:12:54 +02:00
Skgland f1171e2fb2 build debian packages on linux targets 2025-08-17 21:36:42 +02:00
Skgland e38ee14580 add tests for issue 3048 2025-08-17 14:50:15 +02:00
Skgland e1a52a4dde allow passing a null through a cstr arg/return 2025-08-08 22:45:24 +02:00
Skgland 7b960a7d63 fix clippy lint warning 2025-08-08 22:08:13 +02:00
Skgland 39bd520542 ignore pstr_iter_tests test in miri as it takes too long 2024-07-07 13:22:49 +02:00
Skgland 78b83ca1e1 simplify os:argv/1 fix 2024-01-04 19:26:10 +01:00
Skgland ea0130d114 use once to limit solutions instead of cut 2024-01-04 18:14:32 +01:00
Skgland e66e7c5034 add another test case for os:argv/1 2024-01-04 18:12:38 +01:00
Skgland 8bd0317e9c fix os:argv(V) not completing 2024-01-02 21:43:38 +01:00
Skgland 76b1167842 fix os:argv 2024-01-02 20:54:37 +01:00
Skgland 7537686d8f cover both args ending in -- and args not ending in -- for os:argv/1 test 2024-01-02 20:48:38 +01:00
Skgland 6fc340c4db remove unnecessary true 2024-01-02 20:27:14 +01:00
Skgland 38f25af47d cover trailing -- and os:argv([]) in os_argv test 2024-01-02 20:23:53 +01:00
Skgland 91df533834 fix os:argv/1 2024-01-02 19:55:27 +01:00
Skgland 9a05ca0667 add failing test for os:argv issue
See https://github.com/mthom/scryer-prolog/pull/2263#issuecomment-1874400820
2024-01-02 19:51:09 +01:00
Skgland 147e47c8eb fix missing .pl file for singleton test case and move .pl files under <testcase>.in/
follow up to #2205
2023-12-06 21:21:28 +01:00
Skgland 57b52fbe90 fix windows test by not disabling normalization
- this re-enables line ending and file path normalization
  - the latter might be unwanted, but there is only a shared flag
  - this might result in too loose matching of / and \ in stdout and stderr as prolog syntax may be mistaken for a path
2023-12-04 22:59:52 +01:00
Skgland b052b62b16 fix formatting 2023-12-04 22:41:25 +01:00
Skgland 4df7e94d56 rename to match toml file
- goals.pl is used by both compound_goal.toml and multiple_goals.toml therefor renamed the later to share a common prefix with goals.pl, to keep them together
2023-12-04 22:23:04 +01:00
Skgland fcf2e2db05 move .pl files from tests-pl next to the .toml of the test that uses them 2023-12-04 22:16:04 +01:00
Skgland 1c52de9ab1 File-oriented testing
inspired by #2191 but for the `run_top_level_test_with_args`s and  `run_top_level_test_no_args instead of the `load_module_test`s
2023-12-04 22:02:46 +01:00
Skgland d24e6100a7 fix rust_beta_channel feature 2023-09-05 19:12:23 +02:00
Skgland cd0e45b70e fix accidentally left in println!() 2023-09-05 19:12:23 +02:00
Skgland 0f0018abe4 raise msrv for OnceLock support 2023-09-05 19:12:23 +02:00
Skgland a95c5e26e6 add comment why blocking_write is not used 2023-09-05 19:12:23 +02:00
Skgland 70b6cc8e55 fix deadlock in load_library_as_stream 2023-09-05 19:12:22 +02:00
Skgland 86166dbf25 [WIP] make AtomTable concurrentcy ready 2023-09-05 19:12:22 +02:00
Skgland b2130c2a48 run cargo fmt 2023-09-05 19:12:17 +02:00
Skgland 9055370326 adjust rust-version declaration 2022-10-26 23:36:07 -06:00
Skgland 1479b5d38c add a .gitattributes file
- this should stop problems such as mthom/scryer-prolog#1491
  by specifying the line ending
  as this should take precedence over the global config
2022-06-12 15:39:55 +02:00
Skgland 232b66cfc3 adjust error message on failed formatting 2022-06-03 23:50:17 +02:00
Skgland 11ba7e47fd make rustfmt optional
- when rustfmt is not detected (by attempting to run ``rustfmt --version)
  no formatting will be attempted
- this should resolve issue mthom/scryer-prolog#1504
2022-06-03 23:35:55 +02:00
Bennet Bleßmann d89eb9ff0e change reposity url 2021-02-06 22:38:40 +01:00