bug#78650: Guile 3.0.10: regexp-compile not exported by (ice-9 regex) module

2025-06-01 Thread Tomas Volf
ocedure ever available? Looking into git history gives nothing useful. Why do you believe it should exist? There is `make-regexp', maybe you want to use that one. Tomas -- There are only two hard things in Computer Science: cache invalidation, naming things and off-by-one errors.

bug#78333: [PATCH] texinfo: Use `arguments' instead of `attributes' for deftp, deftpx.

2025-05-09 Thread Tomas Volf
* module/texinfo.scm (texi-command-specs)[deftp, deftpx]: Use `arguments'. --- module/texinfo.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/module/texinfo.scm b/module/texinfo.scm index ff95f182d..9f6eba096 100644 --- a/module/texinfo.scm +++ b/module/texinfo.scm @@ -

bug#77762: [PATCH] web: Add JSON module.

2025-05-02 Thread Tomas Volf
"Thompson, David" writes: > On Sat, Apr 12, 2025 at 12:01 PM Tomas Volf <~@wolfsden.cz> wrote: >> >> > - null is the symbol 'null >> >> Out of curiosity, what are your thoughts about using #nil instead? > > My original patch from 10 ye

bug#78164: Home Page and IRC

2025-05-01 Thread Tomas Volf
>> We couldn't connect to that server :frowning: >> Unknown error > > Do Guile still have an IRC channel on libera.chat ? The #guile channel on libera.chat is still in use. I think the problem is with the kiwi hosted client, I have not been able to use it for few months now.

bug#77762: [PATCH] web: Add JSON module.

2025-04-12 Thread Tomas Volf
> - null is the symbol 'null Out of curiosity, what are your thoughts about using #nil instead? Tomas -- There are only two hard things in Computer Science: cache invalidation, naming things and off-by-one errors.

bug#75860: Somewhat confusing exception message with append

2025-03-19 Thread Tomas Nordin
Hello Rob Rob Browning writes: > Tomas Nordin writes: > >> But, in both cases the faulty argument is reported to be in position 1. >> I would expect maybe position 2 to be complained about from the second >> call. > > ...and it appears to be correct when run vi

bug#75997: (ice-9 match): warning: unused variable `failure'

2025-02-27 Thread Tomas Volf
Ludovic Courtès writes: > Tomas Volf <~@wolfsden.cz> skribis: > >> (lambda (expr) >> (let* ((v expr) >> (failure >>(lambda () >> ((@@ (ice-9 match) throw) >> 'match-error >>

bug#76624: [PATCH] filesys.c: Trim trailing white-space.

2025-02-27 Thread Tomas Volf
* libguile/filesys.c: Trim trailing white-space. --- libguile/filesys.c | 122 ++--- 1 file changed, 61 insertions(+), 61 deletions(-) diff --git a/libguile/filesys.c b/libguile/filesys.c index 0e7078cf0..3bfa5eb91 100644 --- a/libguile/filesys.c +++ b/libg

bug#76623: [PATCH] filesys.c: Use scm_sendfile to copy files.

2025-02-27 Thread Tomas Volf
Devos - Copyright 2024 Tomas Volf <~@wolfsden.cz> + Copyright 2024, 2025 Tomas Volf <~@wolfsden.cz> This file is part of Guile. @@ -1354,13 +1354,18 @@ SCM_DEFINE (scm_copy_file2, "copy-file", 2, 0, 1, scm_syserror ("copy-file: copy-on-write failed");

bug#76621: [PATCH] sxml: Fix typo in a comment.

2025-02-27 Thread Tomas Volf
* module/sxml/xpath.scm: Fix typo in a comment. * module/sxml/upstream/SXPath-old.scm: Same. * doc/ref/sxml.texi (SXPath): Reflect in the documentation. --- doc/ref/sxml.texi | 2 +- module/sxml/upstream/SXPath-old.scm | 2 +- module/sxml/xpath.scm | 2 +- 3 files c

bug#75998: [guile-lib] html->sxml does not decode entities in attributes

2025-02-09 Thread Tomas Volf
Hi, Maxim Cournoyer writes: > Tomas, is it a fix you'd be interested in contributing? Otherwise, I'll > get to it but my hands are rather full at the moment :-). To quote myself from the other thread: > Probably not. I have spent 20 minutes staring into the file and d

bug#75998: [guile-lib] html->sxml does not decode entities in attributes

2025-02-04 Thread Tomas Volf
Maxim Cournoyer writes: > Hi Tomas, > > Thank you for reporting this issue. > > Tomas Volf <~@wolfsden.cz> writes: > >> writes: >> >>> On Sat, Feb 01, 2025 at 09:10:04PM +0100, Tomas Volf wrote: >>>> >>>> Hello, >&g

bug#75998: [guile-lib] html->sxml does not decode entities in attributes

2025-02-04 Thread Tomas Volf
; and > repost on guile-devel. Ah, I see. I admit I was checking only the website, and then I asked on IRC. Will re-post on guile-devel as instructed. Tomas -- There are only two hard things in Computer Science: cache invalidation, naming things and off-by-one errors. signature.asc Description: PGP signature

bug#75998: [guile-lib] html->sxml does not decode entities in attributes

2025-02-02 Thread Tomas Volf
writes: > On Sat, Feb 01, 2025 at 09:10:04PM +0100, Tomas Volf wrote: >> >> Hello, >> >> I think I found a bug in the htmlprag module in guile-lib. When parsing >> attributes, the values are not properly decoded: >> >> --8<--

bug#75998: [guile-lib] html->sxml does not decode entities in attributes

2025-02-01 Thread tomas
On Sat, Feb 01, 2025 at 09:10:04PM +0100, Tomas Volf wrote: > > Hello, > > I think I found a bug in the htmlprag module in guile-lib. When parsing > attributes, the values are not properly decoded: > > --8<---cut here---start-&g

bug#75998: [guile-lib] html->sxml does not decode entities in attributes

2025-02-01 Thread Tomas Volf
it is. 2. Add argument #:decode-attributes, defaulting to #f, to the relevant procedures, so that people can opt into the fixed behavior. 3. Introduce parameter %decode-attributes, so that people can opt into the fixed behavior. I am sure there are also other approaches possible. Have a nice d

bug#75997: (ice-9 match): warning: unused variable `failure'

2025-02-01 Thread Tomas Volf
#f))) #f)) --8<---cut here---end--->8--- the `failure' is indeed unused. I took a look at the source code but it is bit beyond my current abilities, so I am not sure how to fix it. Tomas -- There are only two hard things in Computer Scien

bug#75860: Somewhat confusing exception message with append

2025-01-26 Thread Tomas Nordin
ervations, if it's a bug or not, I don't know. (version) => "3.0.9.140-d8df3-dirty" Have a great Sunday -- Tomas

bug#74841: [PATCH] srfi-19: Fix ~V converter in date->string.

2025-01-24 Thread Tomas Volf
Ludovic Courtès writes: > Hi, > > Tomas Volf <~@wolfsden.cz> skribis: > >> The ~V is supposed to print ISO week number, not a week number. This >> commit fixes that. >> >> * module/srfi/srfi-19.scm (date-week-number-iso): New procedure taken >> f

bug#74841: [PATCH v2] srfi-19: Fix ~V converter in date->string.

2025-01-24 Thread Tomas Volf
The ~V is supposed to print ISO week number, not a week number. This commit fixes that. * module/srfi/srfi-19.scm (date-week-number-iso): New procedure taken from the reference implementation. (directives)<#\V>: Use it. * test-suite/tests/srfi-19.test ("date->string ~V"): Add tests taken from the

bug#74385: [PATCH 3/4] srfi-64: Export define-equality-test.

2024-12-13 Thread Tomas Volf
Ludovic Courtès writes: > Hi Tomas, > > Tomas Volf <~@wolfsden.cz> skribis: > >> +(define-syntax define-equality-test >>(syntax-rules () >> ((_ name test-proc) >> (define-syntax name >> (λ (x) >> (syntax-cas

bug#74385: [PATCH 4/4] srfi-64: Report failed tests in (standards)Errors format.

2024-12-13 Thread Tomas Volf
Ludovic Courtès writes: > Tomas Volf <~@wolfsden.cz> skribis: > >> There is a page in the GNU Standards document regarding the format of error >> messages. Both GNU Emacs and Vim are able to parse it and support jumping to >> next/previous error. My version

bug#74841: [PATCH] srfi-19: Fix ~V converter in date->string.

2024-12-12 Thread Tomas Volf
The ~V is supposed to print ISO week number, not a week number. This commit fixes that. * module/srfi/srfi-19.scm (date-week-number-iso): New procedure taken from the reference implementation. (directives)<#\V>: Use it. * test-suite/tests/srfi-19.test ("date->string ~V"): Add tests taken from the

bug#74840: [PATCH] doc: srfi-19: Use `day' instead of `date' for `make-date'.

2024-12-12 Thread Tomas Volf
Looking at the SRFI-19 specification, the argument is called `day', not `date'. Even the accessor is called `date-day'. So adjust the documentation to match. Also adjust the (web http) module, which was using `date' as well. * doc/ref/srfi-modules.texi (SRFI-19 Date): Use `day' instead of `date

bug#74385: [PATCH 1/4] srfi-64: Fix maybe-print-prop.

2024-11-16 Thread Tomas Volf
Previously it always printed the property, regardless of whether it was set or not. * module/srfi/srfi-64.scm (test-on-test-end-simple)[maybe-print-prop]: Print only set properties. --- module/srfi/srfi-64.scm | 19 ++- 1 file changed, 10 insertions(+), 9 deletions(-) diff --git

bug#74385: [PATCH 3/4] srfi-64: Export define-equality-test.

2024-11-16 Thread Tomas Volf
Interest was expressed on the mailing list to have %test-2 as a part of the public API. So rename it and export from the module. * module/srfi/srfi-64.scm (define-equality-test): Rename from %test-2. (%test-2): Rename from %%test-2. (test-eq, test-eqv, test-equal): Adjust. (define-module)<#:expor

bug#74385: [PATCH 4/4] srfi-64: Report failed tests in (standards)Errors format.

2024-11-16 Thread Tomas Volf
There is a page in the GNU Standards document regarding the format of error messages. Both GNU Emacs and Vim are able to parse it and support jumping to next/previous error. My version did not produce a line in this format for failed tests and this commit rectifies that. * module/srfi/srfi-64.sc

bug#74385: [PATCH 2/4] srfi-64: Use ~s when printing some properties.

2024-11-16 Thread Tomas Volf
This will help to properly debug failing tests like: (test-equal "some failing test" "a b " "a b") Before there was no way to tell that one "a b" as extra trailing space, now there is. * module/srfi/srfi-64.scm (test-on-test-end-simple)['expected-value] ['expected-error, 'actual-value, 'actu

bug#74385: [PATCH 0/4] Patches for SRFI-64

2024-11-16 Thread Tomas Volf
Few patches resolving either problems I have noticed or that were reported on the mailing list. Tomas Volf (4): srfi-64: Fix maybe-print-prop. srfi-64: Use ~s when printing some properties. srfi-64: Export define-equality-test. srfi-64: Report failed tests in (standards)Errors format

bug#74348: Wrongly issued warning regarding format arguments for "~65c"

2024-11-13 Thread Tomas Volf
: > This looks like a bug in the compiler to me. > For example, check the `format-analysis' procedure in > language/tree-il/analyze.scm So I am reporting it to the bug tracker. Have a nice day, Tomas -- There are only two hard things in Computer Science: cache invalidation, naming things and off-by-one errors.

bug#74031: [PATCH v3] srfi-64: Accept complex numbers in test-approximate.

2024-10-26 Thread Tomas Volf
The specification mandates reals, but the reference implementation supports complex numbers. So as implementation extension, support them as well. * module/srfi/srfi-64.scm (within-epsilon): Support complex arguments. --- v2: Use the same test logic as the reference implementation. v3: Also adjus

bug#74031: [PATCH] srfi-64: Accept complex numbers in test-approximate.

2024-10-26 Thread Tomas Volf
Hello, lloda writes: >> On 26 Oct 2024, at 19:22, Ludovic Courtès wrote: >> >> Hi, >> >> (Cc: lloda.) >> >> Tomas Volf <~@wolfsden.cz> skribis: >> >>> The specification mandates reals, but the reference implementation >>

bug#74031: [PATCH v2] srfi-64: Accept complex numbers in test-approximate.

2024-10-26 Thread Tomas Volf
The specification mandates reals, but the reference implementation supports complex numbers. So as implementation extension, support them as well. * module/srfi/srfi-64.scm (within-epsilon): Support complex arguments. --- Require error to be real number and check using (checks notes) Chebyshev di

bug#74031: [PATCH] srfi-64: Accept complex numbers in test-approximate.

2024-10-26 Thread Tomas Volf
The specification mandates reals, but the reference implementation supports complex numbers. So as implementation extension, support them as well. * module/srfi/srfi-64.scm (within-epsilon): Support complex arguments. --- Proposal for how to extend test-approximate to handle complex arguments. Ho

bug#74030: [PATCH] srfi-64: Accept symbols as test group names.

2024-10-26 Thread Tomas Volf
The specification mandates a string, but with rationale suggesting symbols would be a more natural fit. > In some ways using symbols would be preferable. However, we want > human-readable names, and standard Scheme does not provide a way to include > spaces or mixed-case text in literal symbols.

bug#73605: [PATCH] Replace SRFI-64 with a new implementation.

2024-10-26 Thread Tomas Volf
t used to just litter your file system with random test log files created in whatever the current working directory is. I do not consider that to be a good behavior. > > As discussed on IRC, I think we should consider restoring support for > these idioms, whether or not they conform to

bug#71300: [PATCH v3] doc: Document SRFI 64.

2024-10-22 Thread Tomas Volf
d possibly be of use as well. 0: https://files.wolfsden.cz/manuals/guile-wolfsden/guile-wolfsden-0.0.4.html#SRFI_002d64-implementation-choices Have a nice day, Tomas signature.asc Description: PGP signature

bug#72547: [PATCH 3/9] tests: Skip hole-related port tests on Darwin.

2024-10-21 Thread Tomas Volf
Ludovic Courtès writes: > Tomas Volf <~@wolfsden.cz> skribis: > >> +(define (skip-on-darwin) >> + (when (string-ci=? "darwin" (vector-ref (uname) 0)) >> +(throw 'untested))) > > I changed (vector-ref (uname) 0) to (utsname:sysname (uname)

bug#71262: Status: [PATCH] Try to install C.UTF-8 locale before falling back to C.

2024-10-21 Thread Tomas Volf
"Dr. Arne Babenhauserheide" writes: > Tomas Volf <~@wolfsden.cz> writes: > >> Does anyone has any opinion regarding this? I think it is sensible >> default in the year 2024. > > I like the idea — I just don’t know enough of the platforms where Gui

bug#32841: assoc-set fails with dot notation association list

2024-10-21 Thread Tomas Volf
(assoc-remove! capitals "Oregon")) capitals ⇓ (("South Dakota" . > "Pierre") ("New York" . "Albany") ("Florida" . "Tallahassee")) > > > > > > >

bug#73605: [PATCH] Replace SRFI-64 with a new implementation.

2024-10-21 Thread Tomas Volf
Ludovic Courtès writes: > Tomas, I leave you the satisfaction of closing all the SRFI-64 bugs. > :-) Thank you for merging the patch, I am off to close the bug reports :) Tomas -- There are only two hard things in Computer Science: cache invalidation, naming things and off-by-one

bug#73707: Missing functions for R7RS small

2024-10-08 Thread Tomas Volf
tring (v) | (v start #:optional end)> --8<---cut here---end--->8--- Could you please expand on what the problem seems to be? Have a nice day, Tomas -- There are only two hard things in Computer Science: cache invalidation, naming things and off-by-one errors. signature.asc Description: PGP signature

bug#72365: srfi-64: test-on-bad-end-name-simple is not allowed to raise an exception

2024-10-02 Thread Tomas Volf
eas disabling it would be difficult / impossible if > `test-end` > were to be hardcoded to raise an error. But if a SRFI-64 implementation made > its > `test-end` always raise an error, it probably wouldn't anyone in practice, so > I > wouldn't see it as a real problem. I still think test-end itself raising is what specification mandates (whether it *should* mandate it is a different question :) ), however I agree, I also am skeptical anyone's code actually cares either way. Tomas -- There are only two hard things in Computer Science: cache invalidation, naming things and off-by-one errors.

bug#72369: srfi-64: test-end fails to signal an error with null runner

2024-10-02 Thread Tomas Volf
Taylan Kammer writes: Hi, > On 30.07.2024 21:51, Tomas Volf wrote: >> Hello, >> >> I think I found a bug in (srfi srfi-64) module shipped with GNU Guile. >> >> The specification says the following about the test-end: >> >>> An error is reported i

bug#73605: [PATCH] Replace SRFI-64 with a new implementation.

2024-10-02 Thread Tomas Volf
\ diff --git a/module/srfi/srfi-64.scm b/module/srfi/srfi-64.scm index 925726f5c..1f60a72e5 100644 --- a/module/srfi/srfi-64.scm +++ b/module/srfi/srfi-64.scm @@ -1,6 +1,5 @@ -;;; srfi-64.scm -- SRFI 64 - A Scheme API for test suites. +;;; Copyright (C) 2024 Tomas Volf <~@wolfsden.cz> -;;

bug#72365: srfi-64: test-on-bad-end-name-simple is not allowed to raise an exception

2024-10-02 Thread Tomas Volf
Taylan Kammer writes: Hi, sorry for taking so long to respond to your comments, work has been bit busy lately. I really appreciate you looking at them and validating and/or challenging my conclusions. > On 30.07.2024 21:51, Tomas Volf wrote: >> Hello, >> >> I think I foun

bug#71300: [PATCH v4] doc: Document SRFI 64.

2024-09-22 Thread Tomas Volf
+@c HTML document using the 'snarfi' script. Based on this I believe it describes the specification. I think either of those is fine (albeit describing the Guile's flavor would be preferred), but is should be stated (that the behavior described by the manual does not match the i

bug#71262: Status: [PATCH] Try to install C.UTF-8 locale before falling back to C.

2024-09-07 Thread Tomas Volf
Does anyone has any opinion regarding this? I think it is sensible default in the year 2024. Tomas signature.asc Description: PGP signature

bug#72612: (set! display #f) infinite loop

2024-08-13 Thread tomas
On Tue, Aug 13, 2024 at 07:06:09PM -0400, Bryce Moore wrote: > I know it's nonsensical, but (set! display #f) in a fresh interpreter > causes an infinite loop. > > Interrupting with Ctrl+C exits guile. > > scheme@(guile-user)> (set! display #f) > While reading expression: > Wrong type to apply: E

bug#72547: [PATCH 5/9] tests: Skip mkdtemp test for invalid template on Darwin.

2024-08-09 Thread Tomas Volf
Darwin accepts any template, as demonstrated here: #include #include int main(void) { char template[] = {'T', '-', 'A', 'A', 'A', 'A', 'A', 'A', '\0'}; char *res = mkdtemp(template); puts(res ? res : "(null)"); perror("mkdtemp"); } Output

bug#72547: [PATCH 4/9] filesys.c: Fix readlink for ports on Darwin.

2024-08-09 Thread Tomas Volf
When passed a port, `readlink' relies on the Linux specific behavior of empty c_path meaning "the fd itself". That does not work on Darwin. Since there is no branch that would yield both fd and c_path, fallback to freadlink when __APPLE__ is defined. * libguile/filesys.c (do_readlink): Call fread

bug#72547: [PATCH 8/9] Do not depend on tmpnam in posix.test.

2024-08-09 Thread Tomas Volf
`tmpnam' is a deprecated procedure that can be excluded during a configure (`--disable-tmpnam'). There currently was a single test relying on it, and therefore failing is such configuration. This commit switches to mkstemp instead. * test-suite/tests/posix.test ("system*"): Use mkstemp instead o

bug#72547: [PATCH 9/9] posix.c: Set errno when pipe2 is not available and flags provided.

2024-08-09 Thread Tomas Volf
If pipe2 is not available (e.g. on MacOS) and flags are set, SCM_SYSERROR was correctly signaled, however errno was not set, so it reported as: Undefined error: 0 That sucks both in tests (the test is not skipped) and in actual usage (user has no idea what went wrong). So set errno to ENOSYS

bug#72547: [PATCH 7/9] tests: Fix spawn if file not found with Gnulib.

2024-08-09 Thread Tomas Volf
On Darwin posix_spawnp is not considered secured and therefore we fallback to Gnulib's version. That one however does not return ENOENT when the file does not exist, but PID of the child process. This seems to be allowed by the standard. * test-suite/tests/posix.test (skip-on-darwin): New proced

bug#72547: [PATCH 1/9] tests: Check TCP_NODELAY for non-zero instead of 1.

2024-08-09 Thread Tomas Volf
POSIX does not explicitly say that stored value using setsockopt will be returned by getsockopt. At least for TCP_NODELAY on Darwin they do differ. Darwin returns internal define TF_NODELAY (4) instead of 1 the test expected. Since for boolean flags "non-zero is true", rewrite the test to check

bug#72547: [PATCH 6/9] tests: Fix spawn with #:environment on MacOS.

2024-08-09 Thread Tomas Volf
MacOS adds __CF_USER_TEXT_ENCODING to every program, in similar way GNU Hurd prepends LD_ORIGIN_PATH (based on the comment). So extend the logic to do similar stripping on MacOS. * test-suite/tests/posix.test ("spawn") ["env with #:environment and #:output"]: Strip trailing __CF_USER_TEXT_ENCODIN

bug#72547: [PATCH 3/9] tests: Skip hole-related port tests on Darwin.

2024-08-09 Thread Tomas Volf
Hole are itself a file-system specific feature and they are not mandated. While APFS does support sparse files, they do not behave like on Linux. I did not discover exact rules, but the file needs to be large (100s of kB at least) and the holes are not aligned as the test code expects. So just d

bug#72547: [PATCH 2/9] tests: Skip tests of abstract Unix sockets on Darwin.

2024-08-09 Thread Tomas Volf
Darwin does not support abstract Unix sockets, so mark the tests as skipped. * test-suite/tests/00-socket.test (skip-on-darwin): New procedure. ("bind abstract", "listen abstract", "connect abstract") ("accept abstract"): Skip on Darwin. --- test-suite/tests/00-socket.test | 8 1 file ch

bug#72547: [PATCH 0/9] Make test suite pass on macOS.

2024-08-09 Thread Tomas Volf
test suite does fully pass (well, minus the skips ^_^) on 14.6 macOS. I am not sure if the project cares about non-free system, but since I had to write the patches anyway, I might as well share them. Tomas Volf (9): tests: Check TCP_NODELAY for non-zero instead of 1. tests: Skip tests of

bug#72380: srfi-64: test-end does not uninstall runner if on-final was modified

2024-07-30 Thread Tomas Volf
nt))) Resulting in: ;;; (#t) Starting test x (Writing full log to "x.log") ;;; (#f) I see no provision in the specification that would justify this. Have a nice day Tomas Volf

bug#72381: srfi-64: test-result-remove fails to remove property

2024-07-30 Thread Tomas Volf
.scm:548:47: In procedure loop: In procedure car: Wrong type argument in position 1 (expecting pair): () >From cursory look at the `test-result-remove' source, is seems that the named let `loop' is missing a stop condition? Have a nice day Tomas Volf

bug#72373: srfi-64: test-assert evaluates test-name multiple times

2024-07-30 Thread Tomas Volf
luated multiple times: (use-modules (srfi srfi-64)) (test-begin "x") (test-assert (pk "t") #t) Leading to: ;;; ("t") ;;; ("t") Have a nice day Tomas Volf

bug#72376: srfi-64: test-equal evaluates test-name multiple times

2024-07-30 Thread Tomas Volf
-name is evaluated multiple times: (use-modules (srfi srfi-64)) (test-begin "x") (test-equal (pk "t") #t #t) Leading to: ;;; ("t") ;;; ("t") Have a nice day Tomas Volf

bug#72370: srfi-64: test-apply requires at least one specifier

2024-07-30 Thread Tomas Volf
nknown file: 0 (reverse #t) ERROR: In procedure reverse: In procedure reverse: Wrong type argument in position 1: #t Have a nice day Tomas Volf

bug#72374: srfi-64: test-apply does not accept convenience specifiers

2024-07-30 Thread Tomas Volf
st-apply "t-a" (λ () (test-assert #t))) Resulting in: [..] srfi/srfi-64/testing.scm:257:17: In procedure %test-any-specifier-matches: Wrong type to apply: "t-a" Have a nice day Tomas Volf

bug#72378: srfi-64: top-level test-group does not work

2024-07-30 Thread Tomas Volf
-64/test-group-top-level.srfi64test: 8:0 0 (_) /home/wolf/src/guile-wolfsden/tests/srfi-64/test-group-top-level.srfi64test:8:0: In procedure struct-vtable: Wrong type argument in position 1 (expecting struct): #f Have a nice day Tomas Volf

bug#72377: srfi-64: test-eq evaluates test-name multiple times

2024-07-30 Thread Tomas Volf
-name is evaluated multiple times: (use-modules (srfi srfi-64)) (test-begin "x") (test-eq (pk "t") #t #t) Leading to: ;;; ("t") ;;; ("t") Have a nice day Tomas Volf

bug#72369: srfi-64: test-end fails to signal an error with null runner

2024-07-30 Thread Tomas Volf
i srfi-64)) (let ((r (test-runner-null))) (test-runner-current r) (test-begin "x") (test-end "y")) However it does not. Have a nice day Tomas Volf

bug#72371: srfi-64: test marked for skip and as expected failure has wrong result-kind in on-test-begin-function

2024-07-30 Thread Tomas Volf
))) (test-skip 1) (test-expect-fail 1) (test-assert #t) (test-end) However it does not: ;;; (skip) Have a nice day Tomas Volf

bug#72367: srfi-64: nested group not counted as one test

2024-07-30 Thread Tomas Volf
ever as we can see it does: ;;; (("x")) ;;; (3 1) Have a nice day Tomas Volf

bug#72382: srfi-64: test-with-runner requires some decl-or-expr

2024-07-30 Thread Tomas Volf
syntax-violation: Syntax error: unknown location: lambda: bad lambda in form (lambda ()) Have a nice day Tomas Volf

bug#72375: srfi-64: test-eqv evaluates test-name multiple times

2024-07-30 Thread Tomas Volf
-name is evaluated multiple times: (use-modules (srfi srfi-64)) (test-begin "x") (test-eqv (pk "t") #t #t) Leading to: ;;; ("t") ;;; ("t") Have a nice day Tomas Volf

bug#72383: srfi-64: test-runner-reset clobbers the run list

2024-07-30 Thread Tomas Volf
ting full log to "x.log") ;;; (t-a) ;;; (t-b) Notice that in the second part, t-b is executed despite not supposed to be on the run list. Have a nice day Tomas Volf

bug#72372: srfi-64: test-approximate evaluates test-name multiple times

2024-07-30 Thread Tomas Volf
(- expected error)) >(<= test-expr (+ expected error However the test-name is evaluated multiple times: (use-modules (srfi srfi-64)) (test-begin "x") (test-approximate (pk "t") 1 1 0) Leading to: ;;; ("t") ;;; ("t") Have a nice day Tomas Volf

bug#72366: srfi-64: on-bad-end-name-function has swapped arguments

2024-07-30 Thread Tomas Volf
(test-runner-null))) (test-runner-current r) (test-runner-on-bad-end-name! r (λ (runner begin-name end-name) (pk begin-name))) (test-begin "x") (test-assert #t) (test-end "y")) But it does not: ;;; ("y") Have a nice day Tomas Volf

bug#72379: srfi-64: test-approximate does not handle exceptions

2024-07-30 Thread Tomas Volf
olfsden/tests/srfi-64/test-approximate-throw.srfi64test: 7:0 2 (_) In srfi/srfi-64/testing.scm: 677:16 1 (_ _ #f) In unknown file: 0 (real-part #f) ERROR: In procedure real-part: In procedure real-part: Wrong type argument in position 1: #f Have a nice day Tomas Volf

bug#72368: srfi-64: test-begin does not set test-runner-test-name

2024-07-30 Thread Tomas Volf
x")) However it does not: ;;; ("") Have a nice day Tomas Volf

bug#72365: srfi-64: test-on-bad-end-name-simple is not allowed to raise an exception

2024-07-30 Thread Tomas Volf
4388:12 1 (_) In srfi/srfi-64/testing.scm: 375:14 0 (test-on-bad-end-name-simple _ _ _) srfi/srfi-64/testing.scm:375:14: In procedure test-on-bad-end-name-simple: test-end x does not match test-begin y Have a nice day Tomas Volf

bug#72384: srfi-64: test-end should not clear fail list

2024-07-30 Thread Tomas Volf
#t) (pk (test-result-kind)) (test-end) Leading to: ;;; (xpass) ;;; (pass) Have a nice day Tomas Volf

bug#72347: Mismatch between documentation and real implementation of list-index

2024-07-29 Thread Tomas Volf
= # Notice that by importing srfi-1 the list-index changes to the documented one. You are right that the "default" list-index indeed does not seem to be documented. It also uses `eq?' for comparisons and does not allow changing that. I hope this sheds some light on the problem. Tomas -- There are only two hard things in Computer Science: cache invalidation, naming things and off-by-one errors. signature.asc Description: PGP signature

bug#72154: test-error does not work

2024-07-17 Thread Tomas Volf
pected-error: + foo actual-error: + (bar) result: PASS According to feedback from mastodon it is not really implemented. That does not seem to be documented. Maybe it would be better to just not export it? Or it should throw 'not-implemented instead of just passing? Have a nice day

bug#72153: Test name is evaluated twice

2024-07-17 Thread Tomas Volf
ASS That does not seem to be allowed by SRFI-64. I do not believe this is limited to test-assert, I managed to reproduce with test-equal as well. Have a nice day, Tomas Volf -- There are only two hard things in Computer Science: cache invalidation, naming things and off-by-one errors. signature.asc Description: PGP signature

bug#71980: [3.0.10] posix.test uses depcrecated tmpnam

2024-07-07 Thread Tomas Volf
(lambda () > -(with-error-to-port port > - (lambda () > -(system* "sh" "-c" "echo bong >&2" > + (system* "sh" "-c" "echo bong >&2&quo

bug#71800: [PATCH 1/2] doc: Document #:hide.

2024-06-27 Thread Tomas Volf
* doc/ref/api-modules.texi (Using Guile Modules): Document #:hide. --- doc/ref/api-modules.texi | 29 ++--- 1 file changed, 18 insertions(+), 11 deletions(-) diff --git a/doc/ref/api-modules.texi b/doc/ref/api-modules.texi index 9f2bba02d..efe739a25 100644 --- a/doc/ref/ap

bug#71800: [PATCH 2/2] doc: Fix implication of omitting optional arguments.

2024-06-27 Thread Tomas Volf
According to the previous wording, omitting all optional arguments led to empty interface. That however was not the case and was only a documentation bug (as confirmed by wingo on IRC). So let us fix that. * doc/ref/api-modules.texi (Using Guile Modules): Fix implication of omitting optional arg

bug#71800: [PATCH 0/2] Improve documentation about using modules.

2024-06-27 Thread Tomas Volf
Document the #:hide argument. Correct text for implication of leaving all optional arguments out. Tomas Volf (2): doc: Document #:hide. doc: Fix implication of omitting optional arguments. doc/ref/api-modules.texi | 29 ++--- 1 file changed, 18 insertions(+), 11

bug#71798: [PATCH 1/2] doc: Document #:hide.

2024-06-27 Thread Tomas Volf
* doc/ref/api-modules.texi (Using Guile Modules): Document #:hide. --- doc/ref/api-modules.texi | 29 ++--- 1 file changed, 18 insertions(+), 11 deletions(-) diff --git a/doc/ref/api-modules.texi b/doc/ref/api-modules.texi index 9f2bba02d..efe739a25 100644 --- a/doc/ref/ap

bug#71799: [PATCH 2/2] doc: Fix implication of omitting optional arguments.

2024-06-27 Thread Tomas Volf
According to the previous wording, omitting all optional arguments led to empty interface. That however was not the case and was only a documentation bug (as confirmed by wingo on IRC). So let us fix that. * doc/ref/api-modules.texi (Using Guile Modules): Fix implication of omitting optional arg

bug#71796: [PATCH] Do not depend on tmpnam in posix.test.

2024-06-27 Thread Tomas Volf
`tmpnam' is a deprecated procedure that can be excluded during a configure (`--disable-tmpnam'). There currently was a single test relying on it, and therefore failing is such configuration. This commit switches to mkstemp instead. * test-suite/tests/posix.test ("system*"): Use mkstemp instead o

bug#71262: [PATCH] Try to install C.UTF-8 locale before falling back to C.

2024-05-29 Thread Tomas Volf
If user does not have LANG or LC_ALL set (as does often happen in various sandboxes) glibc will just install C locale. That is fine (and permissible by POSIX), however in Guile's context it is of a mixed usefulness due to the absence of UTF-8 support. This commit changes the locale auto-installat

bug#71047: [PATCH] doc: Recommend alist-copy instead of list-copy.

2024-05-18 Thread Tomas Volf
The current recommendation of `list-copy' is not right and does not lead to preserving the original list: scheme@(guile-user)> (define x (list (cons 'a 1) (cons 'b 2))) scheme@(guile-user)> (define y (list-copy x)) scheme@(guile-user)> (assq-set! y 'b 3) $1 = ((a . 1) (b . 3))

bug#68504: [PATCH v3] Add copy-on-write support to scm_copy_file.

2024-03-12 Thread Tomas Volf
or 'auto case: CoW ---fail--> copy_file_range ---fail--> current copy ---fail--> FAIL For 'never case: copy_file_range ---fail--> current copy ---fail--> FAIL Is that an accurate summary? Or did you mean only as a fallback for the CoW, so only for 'aut

bug#69730: Segfault in (spawn) when passed wrong port

2024-03-11 Thread Tomas Volf
ile "/dev/null")), I would not expect invalid value in an interpreted language to cause a segfault. If the value is indeed invalid, it should throw an error. Original report: https://emacs.ch/@kakafarm/112075808549752692 Have a nice day, Tomas Volf -- There are only two hard things

bug#69438: basename faulty with nul and suffix

2024-02-27 Thread tomas
On Tue, Feb 27, 2024 at 08:14:58PM +, Zefram via Bug reports for GUILE, GNU's Ubiquitous Extension Language wrote: > Trying out the basename function in Guile 3.0.9: > > scheme@(guile-user)> (basename "foo/bar") > $1 = "bar" > scheme@(guile-user)> (basename "foo/bar" "r") > $2 = "ba" > scheme

bug#68504: [PATCH] Add copy-on-write support to scm_copy_file.

2024-01-24 Thread Tomas Volf
find time to actually form an opinion based on facts. Have a nice day, Tomas -- There are only two hard things in Computer Science: cache invalidation, naming things and off-by-one errors. signature.asc Description: PGP signature

bug#68504: [PATCH v3] Add copy-on-write support to scm_copy_file.

2024-01-24 Thread Tomas Volf
On modern file-systems (BTRFS, ZFS) it is possible to copy a file using copy-on-write method. For large files it has the advantage of being much faster and saving disk space (since identical extents are not duplicated). This feature is stable and for example coreutils' `cp' does use it automatica

bug#68504: [PATCH v2] Add copy-on-write support to scm_copy_file.

2024-01-24 Thread Tomas Volf
On modern file-systems (BTRFS, ZFS) it is possible to copy a file using copy-on-write method. For large files it has the advantage of being much faster and saving disk space (since identical extents are not duplicated). This feature is stable and for example coreutils' `cp' does use it automatica

bug#68505: [PATCH v2] Add more detailed instructions into the HACKING file.

2024-01-24 Thread Tomas Volf
WDYT? Modified as agreed on irc. I am not convinced on the -P, but I defer to your judgment on this. Have a nice day, Tomas Volf -- There are only two hard things in Computer Science: cache invalidation, naming things and off-by-one errors. signature.asc Description: PGP signature

bug#68505: [PATCH v3] Add more detailed instructions into the HACKING file.

2024-01-24 Thread Tomas Volf
Until now, the ./meta/guile was not mentioned anywhere, and therefore it was not obvious how to run the locally compiled Guile without installing it. While modifying the file, I took the liberty to also mention a bit about compiling Guile using Guix. Finally, the header lines where cleaned up, en

bug#68507: [PATCH] doc: Fix example in list-transduce example.

2024-01-16 Thread Tomas Volf
While the `.' might be correct from a grammatical point of view (I do not know), it turns the example into invalid scheme code, which is not ideal. New users (like me) might try to copy the whole line and wonder why it does not work (like I did). So delete it. * doc/ref/srfi-modules.texi (SRFI-1

  1   2   >