IRC channel logs
2023-02-04.log
back to list of logs
<lechner>Hi, does Guile have something like Hackage? <sneek>Welcome back whereiseveryone, you have 1 message! <sneek>whereiseveryone, old says: What's the status on this meeting for Guile's debugger workgroup? <whereiseveryone>sneek: later tell old: We had a nice guile debugging session today with ludo at Guix Days <whereiseveryone>sneek: later told old: I'm aiming for next month. I'll send an email out to the mailing list soon to schedule it. <mirai>I thought receive+values would work but it didn't <chrislck>mirai: use quasiquote with @ -- `(1 ,@(let ((...)) a b c) 20 30 40 (998 999)) <chrislck>oops -- `(1 ,@(let ((...)) (list a b c)) 20 30 40 (998 999)) <chrislck>oops -- `(1 ,@(let ((...)) (list a b c)) 20 30 40 998 999) <mirai>I'm aware that quasiquoting+splice could be used here <mirai>but can this kind of effect be achieved without it? <wklew>mirai: you could use append-map, and then wrap all of your single values in list <mwette>`(1 ,@(let ((...)) (list a b c) 20 30 40 . (998 999))) <mwette>(fold-right (lambda (e l) (if (pair? e) (append e l) (cons e l))) '() '(1 .... (998 999))) <old>does guile only support truncate(2)? I'm trying to truncate a shared memory created via shm_open <old>which has no filesystem path. Guile should use ftruncate(2) instead for that type of port <mwette>I was just looking at that. I think it does have the other <mwette>you are passing the fd? I think truncate-file will work. guile does call ftruncate in the guts of libguile (for truncate-file) <old>No I pass the port object <old>Typically I do a shm_open followed by a fdopen on the resulting filescriptor <old>I will try truncate-file with fd <old>it's weird though that Guile try to (truncate-file (port-filename port) size) for ports <old>It should use the underlying filedescriptor if available <old>shm_open is definitely something cool to have <old>however, it's from librt and not libc <old>so not portable for macOS and Windows I guess <old>Personnally I don't care, but I understand if Guile must support these <mwette>right: the librt dependency, that's what scared me away from adding it <old>unrelated to all that <old>but sysconf would be great to have <old>along with the constants