bug#56413: [PATCH v2 1/1] scm_i_utf8_string_hash: compute u8 chars not bytes

2023-03-05 Thread Rob Browning
Noticed while investigating a migration to utf-8 strings. After making changes that routed non-ascii symbol hashing through this function, encoding-iso88597.test began intermittently failing because it would traverse trailing garbage when u8_strnlen reported 8 chars instead of 4. Change the scm_i

bug#61980: [gnu.org #1925573] [Guile manual] Dead 404 link report.

2023-03-05 Thread Therese Godefroy via RT
Hello Guile maintainers, Yuval Langer reports 2 dead links in the Guile manual (see below): 1) (html_node/SLIB.html) ../slib_html/Require.html#Require (guile.html) slib.html#Require Replacement --> https://people.csail.mit.edu/jaffer/slib/Require.html#Require 2) (html_node/JACAL.html) ../jaca

bug#61957: NetBSD: JIT doesn't work

2023-03-04 Thread Thomas Klausner
round is to map the page twice - once writable, and once executable. The NetBSD mremap(2) man page describes this and has a complete code example: https://man.netbsd.org/mremap.2 Please add support for this to guile's JIT. Thank you! Thomas (Please note that there currently is a bug in NetBSD

bug#27782: mman patch for v3.0.9

2023-03-01 Thread Matt Wette
I think this is still not there. I have found additional issues with some suggested updates. Maybe we should have a branch in the guile repo for this.

bug#61660: [feature request] optimization of case-lambda

2023-02-27 Thread lloda
gt;> + (cond (kw >> + ;; FIXME: Not handling keyword cases. >> + #f) > > Maybe s/FIXME/XXX/ since it’s at most a limitation, certainly not a bug. > > It LGTM and Andy already approved it on IRC, so go ahead! > > Ludo’. Apologies for not seeing this earlier. Pushed to 3b47f87618047ebb8812788c64a44877a4f2e0dd. Thanks! - Daniel

bug#61660: [feature request] optimization of case-lambda

2023-02-27 Thread Ludovic Courtès
> + (($ src-case req opt rest kw inits > gensyms case-body alt) > +(cond (kw > + ;; FIXME: Not handling keyword cases. > + #f) Maybe s/FIXME/XXX/ since it’s at most a limitation, certainly not a bug. It LGTM and Andy already approved it on IRC, so go ahead! Ludo’.

bug#61788: [3.0.9] --disable-tmpnam build fails "make check"

2023-02-25 Thread Matt Wette
I built gule-3.0.9 with "configure --disable-tmpnam" and get the following failure from posix.test while running "make check": Running ports.test warning: call to primitive-fork while multiple threads are running; further behavior unspecified.  See "Processes" in the manual, for

bug#61766: Typo in docs

2023-02-24 Thread lloda
> On 24 Feb 2023, at 15:54, Giorgos Tzampanakis > wrote: > > Hi, > > In the signature of raise-exception in [1] it should say "continuable?" > instead of just "continuable". > > [1] > https://www.gnu.org/software/guile/manual/html_node/Raising-and-Handling-Exceptions.html Fixed in 52465

bug#61766: Typo in docs

2023-02-24 Thread Giorgos Tzampanakis
Hi, In the signature of raise-exception in [1] it should say "continuable?" instead of just "continuable". [1] https://www.gnu.org/software/guile/manual/html_node/Raising-and-Handling-Exceptions.html

bug#61660: [feature request] optimization of case-lambda

2023-02-24 Thread lloda
Fixed patch handling rest & #:optional, with test cases. 0001-peval-reduces-some-inlined-case-lambda-calls.patch Description: Binary data

bug#61660: [feature request] optimization of case-lambda

2023-02-23 Thread lloda
Patch attached, tests tbd. Thoughts? 0001-peval-reduces-some-inlined-case-lambda-calls.patch Description: Binary data

bug#61660: [feature request] optimization of case-lambda

2023-02-20 Thread lloda
On 3.0.9 > ,optimize ((case-lambda (() 0))) = 0 but > ,optimize ((case-lambda (() 0) ((a) 1))) = ((case-lambda (() 0) ((a) 1))) The problem with this is that when the output of a macro contains case-lambda, recursive application results in geometrical increase of code size. It seems that

bug#61598: guile 3.0.9 missing module ice-9/readline.scm

2023-02-18 Thread Jean Abou Samra
> Le 18 févr. 2023 à 09:25, p...@posteo.net a écrit : > > The Guile 3.0 manual mentions "(use-modules (ice-9 readline))", but the > module appears to be missing from the Guile 3.0.9 source code tarball. I > noticed the issue was brought up for version 3.0.9 RC1,

bug#61599: regarding "guile 3.0.9 missing module ice-9/readline.scm"

2023-02-18 Thread Jean Abou Samra
> Le 18 févr. 2023 à 09:25, p...@posteo.net a écrit : > > Please disregard my previous bug report: "guile 3.0.9 missing module > ice-9/readline.scm". I realized what the problem was afterwards. The module > readline.scm is in a separate location in the source tarba

bug#61599: regarding "guile 3.0.9 missing module ice-9/readline.scm"

2023-02-18 Thread pell
Please disregard my previous bug report: "guile 3.0.9 missing module ice-9/readline.scm". I realized what the problem was afterwards. The module readline.scm is in a separate location in the source tarball and wasn't included with the other ice-9 modules because I forgot

bug#61598: guile 3.0.9 missing module ice-9/readline.scm

2023-02-18 Thread pell
The Guile 3.0 manual mentions "(use-modules (ice-9 readline))", but the module appears to be missing from the Guile 3.0.9 source code tarball. I noticed the issue was brought up for version 3.0.9 RC1, but the bug was closed. Has the module been intentionally removed for some reason? I

bug#27782: mman patch for v3.0.9

2023-02-14 Thread Matt Wette
Note.  I have made more changes based on feedback from the mailing list. 1) removed use of scm_c_take_typed_bytevector 2) changed code to generate PAGE_SIZE I think the mmap finalizer still needs review from the Guile experts. I'm attaching a patch to the v3.0.9 release (commit 9b20ca). Sorry a

bug#61476: mmap() with RWX cannot correctly invalidate cache

2023-02-13 Thread Torrekie
I'm building Guile 3.0.9 on iOS 14.5.1 (Darwin 20.4.0) which is suffering some system API differences within pthread_jit* stuff. cat alist.doc array-handle.doc array-map.doc arrays.doc async.doc atomic.doc backtrace.doc boolean.doc bitvectors.doc bytevectors.doc chars.doc control.doc continuat

bug#32279: activate-readline interaction with git

2023-02-02 Thread Jelle Licht
Hi Mark et all, I can no longer reproduce this issue, so I'll close the issue. - Jelle Mark H Weaver writes: > Hi Jelle, > > Jelle Licht writes: >> Loading the (git) module after a call to (activate-readline) from >> (ice-9 readline) stalls my repl, in most (9 out of 10) cases. > > The (git)

bug#61095: possible misuse of posix_spawn API on non-linux OSes

2023-01-27 Thread Omar Polo
Actually I can avoid the EBADF by checking that the fd is 'live' with something like fstat: [[[ Index: libguile/posix.c --- libguile/posix.c.orig +++ libguile/posix.c @@ -1325,8 +1325,12 @@ SCM_DEFINE (scm_fork, "primitive-fork", 0, 0, 0, static void close_inherited_fds_slow (posix_spawn_file_ac

bug#61095: possible misuse of posix_spawn API on non-linux OSes

2023-01-27 Thread Omar Polo
Hello, I've noticed that test-system-cmds fails on OpenBSD-CURRENT while testing the update to guile 3.0.9: test-system-cmds: system* exit status was 127 rather than 42 FAIL: test-system-cmds Here's an excerpt of the ktrace of the child process while executing that specific test: (the fi

bug#61086: [3.0.9] Wrong ‘AR’ value in ‘--enable-lto’ builds

2023-01-26 Thread Ludovic Courtès
In 3.0.9, ‘configure --enable-lto’ goes like this: --8<---cut here---start->8--- checking for ar... ar checking the archiver (ar) interface... ar checking for ar... (cached) ar checking for ranlib... ranlib checking for gcc option to enable large file support...

bug#61079: [3.0.9] ‘system*’ broken on GNU/Hurd

2023-01-26 Thread Ludovic Courtès
0.9rc1/test-suite/standalone' In execvp of guile: Bad file descriptor test-system-cmds: system* exit status was 127 rather than 42 FAIL: test-system-cmds --8<---cut here---end--->8--- This looks like a bug in the new ‘posix_spawn’-based ‘system*’, o

bug#61073: ‘spawn’ crashes when passed a non-file port

2023-01-26 Thread Ludovic Courtès
Ludovic Courtès skribis: > Here’s an example: > > $ ./meta/guile > GNU Guile 3.0.9 > Copyright (C) 1995-2023 Free Software Foundation, Inc. > > Guile comes with ABSOLUTELY NO WARRANTY; for details type `,show w'. > This program is free software, and you are welcome to redistribute it > under cert

bug#61073: ‘spawn’ crashes when passed a non-file port

2023-01-26 Thread Ludovic Courtès
Here’s an example: --8<---cut here---start->8--- $ ./meta/guile GNU Guile 3.0.9 Copyright (C) 1995-2023 Free Software Foundation, Inc. Guile comes with ABSOLUTELY NO WARRANTY; for details type `,show w'. This program is free software, and you are welcome to red

bug#61058: [PATCH] Fix asymetric mutex locking when joining thread.

2023-01-25 Thread Bug reports for GUILE, GNU's Ubiquitous Extension Language
From: Olivier Dion If `join-thread' timeout, the thread mutex is not unlocked, resulting in deadlock to the next call to it or deadlock of the thread itself when it terminates. Thus, always unlock the mutex. Fix: #55356 * module/ice-9/threads.scm (join-thread): Always unlock thread mutex. ---

bug#58498: Acknowledgement (Foreign callback returned by procedure->pointer cannot be executed in foreign thread.)

2023-01-24 Thread Zhu Zihao
Ping. Can someone hear me? -- Retrieve my PGP public key: gpg --recv-keys B3EBC086AB0EBC0F45E0B4D433DB374BCEE4D9DC Zihao

bug#60971: build failure of v3.0.9rc1 on mac os 12.6

2023-01-23 Thread Ludovic Courtès
lloda skribis: > lgtm, no other issues on mac os. Awesome, pushed as 9b20ca275dba758a194073936cde7c95311bd51e. Ludo’.

bug#60971: GNU Guile 3.0.9rc1 available for testing!

2023-01-23 Thread Aleix Conchillo Flaqué
On Mon, Jan 23, 2023 at 2:48 AM Ludovic Courtès wrote: > Hi, > > Greg Troxel skribis: > > > lloda writes: > > > >> This looks like https://debbugs.gnu.org/60971 < > https://debbugs.gnu.org/60971> on mac os. > > > > Yes, it does. > > > > My quick reaction is that if the POSIX-required macros ope

bug#60971: GNU Guile 3.0.9rc1 available for testing!

2023-01-23 Thread lloda
lgtm, no other issues on mac os. thanks Daniel

bug#60971: GNU Guile 3.0.9rc1 available for testing!

2023-01-23 Thread Ludovic Courtès
Hi, Greg Troxel skribis: > lloda writes: > >> This looks like https://debbugs.gnu.org/60971 >> on mac os. > > Yes, it does. > > My quick reaction is that if the POSIX-required macros operation on > system types that might be struct, then faking up ints for testi

bug#61025: 3.0.9rc1: readline.scm missing

2023-01-23 Thread balducci
hello build of 3.0.9rc1 stops for me with: 8< /bin/sh ../libtool --tag=CC --mode=compile gcc -m64 -DHAVE_CONFIG_H -I. -I.. -I. -I.. -I./.. -I../lib -I../lib -I/home/balducci/tmp/install-us-d/guile-3.0.9rc1.d/guile-3.0.9rc1 -Wall -Wmissing-prototypes -Wpointer-arith -fno-stric

bug#60971: build failure of v3.0.9rc1 on mac os 12.6

2023-01-20 Thread lloda
Hello, v3.0.9rc1 fails on mac os 12.6.2 & gcc 12.2 or clang 14, same error in either case. gcc's error is: CC libguile_3.0_la-posix.lo In file included from ../../../src/guile4/libguile/posix.c:82: ../../../src/guile4/libguile/posix.c:109:9: error: l

bug#60234: Build failure on mac os 12.6 / gcc 12.2

2023-01-20 Thread lloda
> On 18 Jan 2023, at 23:16, Ludovic Courtès > wrote: > > Hi Daniel, > > lloda mailto:ll...@sarc.name>> skribis: > >> .../libguile/threads.h:194:43: error: 'scm_i_current_thread' is defined with >> tls model global-dynamic >> 194 | SCM_INTERNAL SCM_THREAD_LOCAL scm_thread

bug#60234: Build failure on mac os 12.6 / gcc 12.2

2023-01-20 Thread Ludovic Courtès
Hi Daniel, lloda skribis: > .../libguile/threads.h:194:43: error: 'scm_i_current_thread' is defined with > tls model global-dynamic > 194 | SCM_INTERNAL SCM_THREAD_LOCAL scm_thread *scm_i_current_thread; > | ^ > .../libguile/threads.c:357:30: no

bug#60928: [PATCH] bugfix/make_hash_table: fix segfault when arg< 0 for make-hash-table

2023-01-19 Thread lloda
No worries, thanks for the report! I note that there's already an old test for (make-hash-table -1) in hash.test. Regards Daniel

bug#60928: [PATCH] bugfix/make_hash_table: fix segfault when arg< 0 for make-hash-table

2023-01-19 Thread Bug reports for GUILE, GNU's Ubiquitous Extension Language
lloda writes: > It seems this is the same bug as https://bugs.gnu.org/60488 and > https://bugs.gnu.org/58154, at least it doesn't segfault in main > anymore. oh sorry about the false patch then, I had searched my local repo for commits containing the word segfault and didn'

bug#60928: [PATCH] bugfix/make_hash_table: fix segfault when arg< 0 for make-hash-table

2023-01-18 Thread lloda
It seems this is the same bug as https://bugs.gnu.org/60488 and https://bugs.gnu.org/58154, at least it doesn't segfault in main anymore.

bug#60928: [PATCH] bugfix/make_hash_table: fix segfault when arg< 0 for make-hash-table

2023-01-18 Thread Bug reports for GUILE, GNU's Ubiquitous Extension Language
* libguile/hashtab.c (make_hash_table): FIX SEGMENTATION FAULT Currently on Guix if a user evokes (make-hash-table arg) where arg < 0, guile segfaults. This patch adds the most straight forward solution, checking if the value passed to make-hash-table is less than 0, and if so, throwing an error w

bug#59647: [PATCH] Fix typos in docstrings.

2023-01-16 Thread jgart
> Hi! These are not typos: “iff” is short for “if and only if”. Oops! 🦆 Thanks for clarifying that ;()

bug#59647: [PATCH] Fix typos in docstrings.

2023-01-16 Thread Ludovic Courtès
jgart skribis: > * libguile/boolean.c > (scm_not): Fix typo. > (scm_boolean_p): Fix typo. > --- > libguile/boolean.c | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) > > diff --git a/libguile/boolean.c b/libguile/boolean.c > index e8370331f..930001a89 100644 > --- a/libguile/b

bug#60022: configure.ac fix for C99 compatibility

2023-01-16 Thread Ludovic Courtès
Hi Florian, Florian Weimer skribis: > This patch is needed to improve C99 compatibility: > > diff --git a/configure.ac b/configure.ac > index b3879df1f..cc865a028 100644 > --- a/configure.ac > +++ b/configure.ac Applied, thanks. Ludo’.

bug#60487: string-ref segfaults with n < 0 on Guile 3.0.8

2023-01-16 Thread Ludovic Courtès
Hi, fester...@posteo.net skribis: > The following code results in a segmentation fault on Guile > 3.0.8-deb+3.0.8-2 (obtained from the Debian repositories): > (string-ref "my string" -3) I can reproduce it with 3.0.8, where I get this backtrace: --8<---cut here---sta

bug#60522: make-vector takes 100% cpu if called without argument in the REPL

2023-01-16 Thread Ludovic Courtès
Hi, Sascha Ziemann skribis: > The following throws an error: > guile -c '(make-vector)' > > But the evaluation of '(make-vector)' in the REPL generats just a warning: > > ;;; :1:0: warning: possibly wrong number of arguments to `make-vector' > > and seems to enter an endless loop afterwards. Th

bug#27782: patch for mmap and friends

2023-01-14 Thread Matt Wette
On 1/14/23 2:42 PM, Maxime Devos wrote:     {   /* Use the fd of the port under clobber protection from concurrency. As scm_dynwind_acquire_port assumes that FILE is a port, check that first. */   SCM_VALIDATE_PORT (SCM_ARG5, file);   scm_dynwind_acquire_port (fil

bug#27782: patch for mmap and friends

2023-01-14 Thread Maxime Devos
On 14-01-2023 01:49, Matt Wette wrote: Please consider this patch for adding mmap(), munmap() and msync()  to libguile/filesys.c.  Included is update for posix.texi and test file mman.test. Once included, feature 'mman should be #t. Matt + if (SCM_UNBNDP (fd)) +c_fd = -1; + else

bug#60799: Bogus 'Error while printing exception' message when raising srfi-35 exception

2023-01-14 Thread Maxim Cournoyer
Hello Ricardo, Ricardo Wurmus writes: > Hi Maxim, > >> When raising a srfi-35 defined exception type like in the following, a >> generic (and unhelpful) "Error while printing exception" message is >> shown, with not even the exception type mentioned: >> >> (use-modules (srfi srfi-35)) >> >> (def

bug#60799: Bogus 'Error while printing exception' message when raising srfi-35 exception

2023-01-13 Thread Ricardo Wurmus
Hi Maxim, > When raising a srfi-35 defined exception type like in the following, a > generic (and unhelpful) "Error while printing exception" message is > shown, with not even the exception type mentioned: > > (use-modules (srfi srfi-35)) > > (define-condition-type &platform-not-found-error &err

bug#60799: Bogus 'Error while printing exception' message when raising srfi-35 exception

2023-01-13 Thread Maxim Cournoyer
Hello Guile, When raising a srfi-35 defined exception type like in the following, a generic (and unhelpful) "Error while printing exception" message is shown, with not even the exception type mentioned: --8<---cut here---start->8--- (use-modules (srfi srfi-35))

bug#27782: patch for mmap and friends

2023-01-13 Thread Matt Wette
On 1/13/23 4:49 PM, Matt Wette wrote: Please consider this patch for adding mmap(), munmap() and msync()  to libguile/filesys.c.  Included is update for posix.texi and test file mman.test. Once included, feature 'mman should be #t. Matt Please add the attached file: test-suite/tests/mman.test

bug#27782: patch for mmap and friends

2023-01-13 Thread Matt Wette
Please consider this patch for adding mmap(), munmap() and msync()  to libguile/filesys.c.  Included is update for posix.texi and test file mman.test. Once included, feature 'mman should be #t. Matt From 6c944174d35d43f87340c8199d47f3f088fa6ca7 Mon Sep 17 00:00:00 2001 From: Matt Wette Date: F

bug#59321: ice-9's open-input-pipe is unexpectedly slow on some systems

2023-01-13 Thread Ludovic Courtès
Hello! Andrew Whatson skribis: > commit c012d7b0d5248a99a3a92780687a676c5d420f5f > Author: Andrew Whatson > Date: Thu Dec 8 21:43:28 2022 +1000 > > Reduce redundant close() calls when forking on some systems. > > Some systems provide "/proc/self/fd" which is a directory containin

bug#52835: [PATCH 0/2] Fix spawning a child not setting standard fds properly

2023-01-13 Thread Ludovic Courtès
what Josselin provided at the beginning of this bug report (let’s not forget we were initially fixing an actual bug :-)) and updated ‘NEWS’: 527c257d6 Make 'system*' and 'piped-process' internally use 'spawn'. 551929e4f Add 'spawn'. edfca3b7e Update gnuli

bug#60779: ‘SCM_F_BYTEVECTOR_IMMUTABLE’ is not honored by bytevector instructions

2023-01-13 Thread Ludovic Courtès
Bytevector literals are marked as ‘SCM_F_BYTEVECTOR_IMMUTABLE’, but VM instructions that access bytevectors do not check that flag, which can lead to segfaults: --8<---cut here---start->8--- $ cat t.scm (use-modules (rnrs bytevectors)) (define bv #vu8(1 2 3)) (

bug#52835: [PATCH 0/2] Fix spawning a child not setting standard fds properly

2023-01-13 Thread Bug reports for GUILE, GNU's Ubiquitous Extension Language
Hello Josselin & Ludo, Thanks for your work on this, posix_spawn is a nice improvement! My comments on the changes in the wip-posix-spawn branch follow. In doc/ref/posix.texi: @quotation Note If you are only looking to fork+exec with some pipes set up, using pipes or the more @code{spawn} p

bug#52835: [PATCH 0/2] Fix spawning a child not setting standard fds properly

2023-01-12 Thread Ludovic Courtès
Hi Josselin, and a happy new year full of good hacks! :-) Josselin Poiret skribis: > I've done the above by using the C functions to bind keyword arguments, > and added the #:use-path? keyword argument. One annoying thing though > is that since it uses keyword arguments, the first line of the

bug#57948: [PATCH] Avoid 'frame-local-ref' errors when printing backtrace.

2023-01-11 Thread Andrew Whatson
Ludovic Courtès wrote: > > Applied, thanks! Thank you! > PS: Please use ‘git format-patch’ so the patch can be directly consumed > by ‘git am’. My mistake, sorry about that. Noted for next time :) Cheers, Andrew

bug#57948: [PATCH] Avoid 'frame-local-ref' errors when printing backtrace.

2023-01-11 Thread Ludovic Courtès
Hi, Andrew Whatson skribis: > commit 164bdce6acf53796cb96ef1930a89c6caf84bc39 > Author: Andrew Whatson > Date: Wed Jan 11 14:04:32 2023 +1000 > > Test for 'frame-local-ref' errors when printing backtrace. > > This test reproduces the error from , and >

bug#57948: [PATCH] Avoid 'frame-local-ref' errors when printing backtrace.

2023-01-10 Thread Andrew Whatson
Ludovic Courtès wrote: > > It would be great if you could add a simple test case though, so that > the bug doesn’t eventually come back to haunt us. I've finally tracked this one down, a patch with a unit test for this bug is attached. Cheers,

bug#52835: [PATCH v8 1/2] Add spawn.

2023-01-07 Thread Bug reports for GUILE, GNU's Ubiquitous Extension Language
* libguile/posix.c: Include spawn.h from Gnulib. (do_spawn, scm_spawn_process): New functions. --- doc/ref/posix.texi | 34 -- libguile/posix.c | 162 - libguile/posix.h | 1 + 3 files changed, 192 insertions(+), 5 deletions(-) diff --git

bug#52835: [PATCH 0/2] Fix spawning a child not setting standard fds properly

2023-01-07 Thread Bug reports for GUILE, GNU's Ubiquitous Extension Language
Hi Ludo, Happy new year! Ludovic Courtès writes: > ‘spawn*’ is expressive enough, but a procedure with 6 positional > arguments cannot be exposed as-is IMO. > > One tiny thing that’s missing is a boolean to choose between > ‘posix_spawn’ and ‘posix_spawnp’. > > So we need either ‘spawn’ defined

bug#52835: [PATCH v8 2/2] Make system* and piped-process internally use spawn.

2023-01-07 Thread Bug reports for GUILE, GNU's Ubiquitous Extension Language
* libguile/posix.c (scm_system_star, scm_piped_process): Use do_spawn. (start_child): Remove function. Co-authored-by: Ludovic Courtès --- libguile/posix.c | 231 --- 1 file changed, 77 insertions(+), 154 deletions(-) diff --git a/libguile/posix.c b/l

bug#60528: uri->string swallows mandatory slashes

2023-01-04 Thread tomas
On Tue, Jan 03, 2023 at 09:00:48PM +0100, Liliana Marie Prikler wrote: > Hi folks, > > Below some unexpected behaviour observed in Guile 3.0.8, but it also > dates back to 2.2.7 and possibly earlier versions. > > scheme@(guile-user)> ,use (web uri) > scheme@(guile-user)> (string->uri "file:///hom

bug#60528: uri->string swallows mandatory slashes

2023-01-03 Thread Liliana Marie Prikler
Hi folks, Below some unexpected behaviour observed in Guile 3.0.8, but it also dates back to 2.2.7 and possibly earlier versions. scheme@(guile-user)> ,use (web uri) scheme@(guile-user)> (string->uri "file:///home") $1 = #< scheme: file userinfo: #f host: #f port: #f path: "/home" query: #f frag

bug#60522: make-vector takes 100% cpu if called without argument in the REPL

2023-01-03 Thread tomas
On Tue, Jan 03, 2023 at 05:57:19PM +0100, Sascha Ziemann wrote: > The following throws an error: > guile -c '(make-vector)' > > But the evaluation of '(make-vector)' in the REPL generats just a warning: > > ;;; :1:0: warning: possibly wrong number of arguments to `make-vector' > > and seems to e

bug#60522: make-vector takes 100% cpu if called without argument in the REPL

2023-01-03 Thread Sascha Ziemann
The following throws an error: guile -c '(make-vector)' But the evaluation of '(make-vector)' in the REPL generats just a warning: ;;; :1:0: warning: possibly wrong number of arguments to `make-vector' and seems to enter an endless loop afterwards. Environment: $ guile --version guile (GNU Guil

bug#60488: string-ref segfaults with n < 0 on Guile 3.0.8

2023-01-02 Thread Jean Abou Samra
f in ?? () >> #27 0x77c9918a in __libc_start_call_main >> (main=main@entry=0x50b0, argc=argc@entry=1, >> argv=argv@entry=0x7fffe0b8) at >> ../sysdeps/nptl/libc_start_call_main.h:58 >> #28 0x77c99245 in __libc_start_main_impl (main=0x50b0, >> argc=1, argv=0x7fffe0b8, init=, fini=> out>, rtld_fini=, stack_end=0x7fffe0a8) at >> ../csu/libc-start.c:381 >> #29 0x51aa in ?? () > > Sorry, didn't see #59874. This bug report is a duplicate of that bug. > Therefore this should be closed. > > >

bug#60488: string-ref segfaults with n < 0 on Guile 3.0.8

2023-01-02 Thread festerdam
l_main.h:58 #28 0x77c99245 in __libc_start_main_impl (main=0x50b0, argc=1, argv=0x7fffe0b8, init=, fini=, rtld_fini=, stack_end=0x7fffe0a8) at ../csu/libc-start.c:381 #29 0x51aa in ?? () Sorry, didn't see #59874. This bug report is a duplicate of that bug. Ther

bug#60487: string-ref segfaults with n < 0 on Guile 3.0.8

2023-01-02 Thread festerdam
The following code results in a segmentation fault on Guile 3.0.8-deb+3.0.8-2 (obtained from the Debian repositories): (string-ref "my string" -3) gdb's backtrace is the following: #0 0x77f1bcc5 in ?? () from /lib/x86_64-linux-gnu/libguile-3.0.so.1 #1 0x77f26c49 in scm_c

bug#60461: [PATCH] Improve compliance of HTTP challenge parsing

2023-01-01 Thread mason1920
* module/web/http.scm (parse-challenges, validate-challenges) (write-challenges): Make challenge arguments optional. Add support for encoded values as challenge argument. * test-suite/tests/web-http.test (Response Headers): Test valid challenges that were not being handled before. --- module/web/h

bug#52835: [PATCH 0/2] Fix spawning a child not setting standard fds properly

2022-12-25 Thread Ludovic Courtès
Josselin Poiret skribis: > * libguile/posix.c (scm_system_star, scm_piped_process): Use do_spawn. > (start_child): Remove function. LGTM, thanks!

bug#52835: [PATCH 0/2] Fix spawning a child not setting standard fds properly

2022-12-25 Thread Ludovic Courtès
Josselin Poiret skribis: > * libguile/posix.c: Include spawn.h from Gnulib. > (do_spawn, scm_spawn_process): New functions. > * module/ice-9/spawn.scm: New file > (spawn): New procedure. > --- > libguile/posix.c | 82 ++ > libguile/posix.h | 2

bug#52835: [PATCH 0/2] Fix spawning a child not setting standard fds properly

2022-12-25 Thread Ludovic Courtès
Hi Josselin, Josselin Poiret skribis: > I've added a convenience module (ice-9 spawn) with a `spawn` procedure > in it, which takes an optional argument list which defaults to just the > executable, and optional environment variables as well as in, out and > err ports. I also think everything i

bug#52835: [PATCH v7 1/2] Add spawn* and spawn.

2022-12-23 Thread Bug reports for GUILE, GNU's Ubiquitous Extension Language
* libguile/posix.c: Include spawn.h from Gnulib. (do_spawn, scm_spawn_process): New functions. * module/ice-9/spawn.scm: New file (spawn): New procedure. --- libguile/posix.c | 82 ++ libguile/posix.h | 2 ++ module/ice-9/spawn.scm | 54

bug#52835: [PATCH v7 2/2] Make system* and piped-process internally use spawn.

2022-12-23 Thread Bug reports for GUILE, GNU's Ubiquitous Extension Language
* libguile/posix.c (scm_system_star, scm_piped_process): Use do_spawn. (start_child): Remove function. Co-authored-by: Ludovic Courtès --- libguile/posix.c | 233 --- 1 file changed, 78 insertions(+), 155 deletions(-) diff --git a/libguile/posix.c b/l

bug#52835: [PATCH 0/2] Fix spawning a child not setting standard fds properly

2022-12-23 Thread Bug reports for GUILE, GNU's Ubiquitous Extension Language
Hi Ludo, thanks for the quick review and fixes. > I pushed it to ‘wip-posix-spawn’ along with fixups I’m proposing, mostly > along the lines of what I suggested in > : Nice but also see below. > I also added Andrew Whatson’s patch from >

bug#52835: [PATCH 0/2] Fix spawning a child not setting standard fds properly

2022-12-23 Thread Ludovic Courtès
Hi Josselin, Josselin Poiret skribis: > Here is hopefully the last reroll of this patchset. First of all, I did not > include the gnulib patch again because it still applies cleanly and it is > extremely large, but it should be applied before those 3 patches. Yay! > The first two patches shou

bug#27782: patch to add support for mmap and friends

2022-12-22 Thread Matt Wette
Please disregard previous patch.  I have more to do. I'll try to catch the next release cycle.

bug#52835: [PATCH v6 0/3] Move spawning procedures to posix_spawn.

2022-12-22 Thread Bug reports for GUILE, GNU's Ubiquitous Extension Language
Hello Ludo, Here is hopefully the last reroll of this patchset. First of all, I did not include the gnulib patch again because it still applies cleanly and it is extremely large, but it should be applied before those 3 patches. The first two patches should be applied on the current major release

bug#52835: [PATCH v6 2/3] Make system* and piped-process internally use spawn.

2022-12-22 Thread Bug reports for GUILE, GNU's Ubiquitous Extension Language
* libguile/posix.c (scm_system_star, scm_piped_process): Use do_spawn. (start_child): Remove function. --- libguile/posix.c | 181 ++- 1 file changed, 39 insertions(+), 142 deletions(-) diff --git a/libguile/posix.c b/libguile/posix.c index e92625483..f

bug#52835: [PATCH v6 3/3] Move popen and posix procedures to spawn*.

2022-12-22 Thread Bug reports for GUILE, GNU's Ubiquitous Extension Language
* libguile/posix.c (scm_piped_process, scm_init_popen): Remove functions. (scm_port_to_fd_with_default): New helper function. (scm_system_star): Rewrite using scm_spawn_process. (scm_init_popen): Remove the definition of piped-process. (scm_init_posix): Now make popen available unconditionally. *

bug#52835: [PATCH v6 1/3] Add spawn*.

2022-12-22 Thread Bug reports for GUILE, GNU's Ubiquitous Extension Language
* libguile/posix.c: Include spawn.h from Gnulib. (do_spawn, scm_spawn_process): New functions. --- libguile/posix.c | 81 libguile/posix.h | 2 ++ 2 files changed, 83 insertions(+) diff --git a/libguile/posix.c b/libguile/posix.c index b5352c2c4..

bug#44505: Guile 3.0.4 build fails on macOS Big Sur / ARM

2022-12-20 Thread lloda
Fixed in 3bdcc3668fd8f9a5b6c9a313ff8d70acb32b2a52. Thanks Daniel

bug#60234: Build failure on mac os 12.6 / gcc 12.2

2022-12-20 Thread lloda
Patched in f859e0f58b211eedcb0dce4f2382cfebf37010d7.

bug#60234: Build failure on mac os 12.6 / gcc 12.2

2022-12-20 Thread lloda
The error is .../libguile/threads.h:194:43: error: 'scm_i_current_thread' is defined with tls model global-dynamic 194 | SCM_INTERNAL SCM_THREAD_LOCAL scm_thread *scm_i_current_thread; | ^ .../libguile/threads.c:357:30: note: previously defined

bug#27782: patch to add support for mmap and friends

2022-12-20 Thread Matt Wette
Guile Maintainers: Please consider the atttached patch for mmap and friends. Includes mmap, mmap/shared, munmap, msync. Matt From 306570beb3d1895abd03700593cc342282e4ccd1 Mon Sep 17 00:00:00 2001 From: Matt Wette Date: Tue, 20 Dec 2022 17:15:27 -0800 Subject: [PATCH] Add support for mmap, munma

bug#60170:

2022-12-17 Thread Stefan Israelsson Tampe
Putting this program in q.scm (lambda () (let* ((tag (list 'let/ec))) (call-with-prompt tag (lambda () (let lp () (call-with-values h (let () (define (g a b) (let ((kk (nm a u v))) (cond ((equal? kk _filen

bug#32040: bug in repl/server.scm

2022-12-16 Thread Matt Wette
I can confirm this still exists in guile 3.0.8: The symptom that I see is when client (telnet localhost 37146) quits server responds with the following:    In thread:   Wrong type to apply: ()  Nice find Isaac!

bug#36682: Error in Guile scripting examples

2022-12-12 Thread Maxim Cournoyer
Hi, Maxim Cournoyer writes: [...] > I have the following two files: > > fact: > > #!/run/current-system/profile/bin/guile \ > -e main -s > !# > (define-module (fact) > #:export (fact)) > > (define (fact n) > (if (zero? n) 1 > (* n (fact (- n 1) > > (define (main args) > (display (f

bug#52835: [PATCH 0/2] Fix spawning a child not setting standard fds properly

2022-12-12 Thread Ludovic Courtès
Hello, Josselin Poiret skribis: >> I would call this one ‘primitive-spawn’ rather than ‘spawn*’ and keep it >> private to (ice-9 popen). > > Is there any reason we would want this to not be accessible to the user? > There are already a bunch of functions that manipulate raw fdes, and > people mi

bug#60022: configure.ac fix for C99 compatibility

2022-12-12 Thread Florian Weimer
This patch is needed to improve C99 compatibility: diff --git a/configure.ac b/configure.ac index b3879df1f..cc865a028 100644 --- a/configure.ac +++ b/configure.ac @@ -904,7 +904,7 @@ AC_CACHE_VAL(guile_cv_localtime_cache, AC_RUN_IFELSE([AC_LANG_SOURCE([[#include #include extern char **enviro

bug#36682: Error in Guile scripting examples

2022-12-12 Thread Maxim Cournoyer
new > namespace). > > And it seems that this is indeed a bug in the documentation, because > https://www.gnu.org/software/guile/manual/html_node/Scripting-Examples.html#Scripting-Examples > jumps to defining fac as a module but does not at the same time define > and import fact

bug#59540: Calling length on a very long improper list is disastrous.

2022-12-12 Thread Ludovic Courtès
Hi, lloda skribis: > I think excessive output is a more serious problem, because it should be > possible to go to a backtrace frame and look at objects directly. On the > other hand, it should also be possible to C-c when guile starts to flood the > terminal. But neither of these workarounds

bug#59540: Calling length on a very long improper list is disastrous.

2022-12-12 Thread lloda
> On 10 Dec 2022, at 18:27, Ludovic Courtès wrote: > > ... > Of these only #2 is something we could work on. However, truncation has > proven to be a hindrance sometimes (in backtraces, objects are > automatically), so I’m not sure we want to enable it by default on > wrong-type-arg error mes

bug#59874: Segfault from string-ref with negative 'k'

2022-12-11 Thread Jean Abou Samra
(Closing since this has been fixed.) OpenPGP_signature Description: OpenPGP digital signature

bug#59984: segfault in list-ref

2022-12-11 Thread Jean Abou Samra
Le 12/12/2022 à 05:10, Christopher Lam a écrit : Hi guile dev team Here's a glaring segfault in guile 3.0.8 This is a duplicate of https://debbugs.gnu.org/cgi/bugreport.cgi?bug=59874, which is already fixed in master. Best, Jean OpenPGP_signature Description: OpenPGP digital signature

bug#59984: segfault in list-ref

2022-12-11 Thread Christopher Lam
Hi guile dev team Here's a glaring segfault in guile 3.0.8 GNU Guile 3.0.8 Copyright (C) 1995-2021 Free Software Foundation, Inc. Guile comes with ABSOLUTELY NO WARRANTY; for details type `,show w'. This program is free software, and you are welcome to redistribute it under certain conditions; t

bug#52835: [PATCH 0/2] Fix spawning a child not setting standard fds properly

2022-12-11 Thread Bug reports for GUILE, GNU's Ubiquitous Extension Language
Hi Ludo, Ludovic Courtès writes: > For top-level functions, please add a comment above explaining what it > does. Completely forgot about that. I will do it at some point, however we will need to settle on how to resolve the issue at the bottom first. > I would call this one ‘primitive-spawn

bug#57440: Guile manual has incorrect history on the name

2022-12-10 Thread Dr. Arne Babenhauserheide
Ludovic Courtès writes: > Hi Arne and Lee, > "Dr. Arne Babenhauserheide" skribis: >> From 8bfc607ffbc433b7dde50787cf813bd455726daa Mon Sep 17 00:00:00 2001 >> From: Arne Babenhauserheide >> Date: Sat, 27 Aug 2022 01:57:57 +0200 >> Subject: [PATCH] doc: Lee Thomas suggested the name change. > >

bug#59540: Calling length on a very long improper list is disastrous.

2022-12-10 Thread Ludovic Courtès
Hi Jeremy, Jeremy Phelps skribis: > I lost my Emacs session today because I accidentally called the length > function on an extremely long improper list. > > But Guile prints the entire thing when it reports the error that happens > when the length function gets to the improper part of the list.

<    1   2   3   4   5   6   7   8   9   10   >