IRC channel logs

2025-03-10.log

back to list of logs

<spk121>ACTION spends all day trying to figure out debbugs / git format-patch / git send-email
<lechner>Hi, how may I tell, with gdb or otherwise, the name of the procedure in line 55, please? https://bpa.st/C76Q
<lechner>or any other helpful debugging info?
<lechner>the call to a Guile procedure inside a shared C library (libpam) fails only when called from a Guile script, presumably indicating that libguile is already in "Guile mode" when loaded for the second time
<lechner>could it be a bug in libguile because a procedure is not being converted to a PRIMITIVE_P when already in Guile mode?
<ttz>hello !
<ttz>I was reading a piece the other day on exceptions vs typed monadic errors. One argument in favor of explicit errors was referential transparency. Thinking about it I was wondering how the compiler was managing to optimize away expressions in Guile since it seems not obvious to tell when an expression is can raise an exception and therefore has side-effects. Would anyone have some pointers about it?
<humm>(int*)0xdeadcafe
<dariqq>rlb: I circumvented my canonical-host problem from last week by just asking the cross cc to -dumpmachine. For native builds I just use the %host-type variable from guile
<rlb>dariqq: nice (TIL -dumpmachine)
<lechner>Hi, does this indicate an internal error? "Exception thrown while printing backtrace:" ?
<spk121>lechner: usually. either an exception that happens really early before things are properly set up, or some weird problem with character encodings
<rlb>I'm wondering if I saw that recently when one of the renderers for an instance threw...
<lechner>sneek Hi, what does this error mean, please? "While compiling expression:
<lechner>Syntax error: unknown location: unexpected syntax in form ()"
<dthompson>lechner: it means that () isn't valid syntax.
<dthompson>there's nothing in operator position
<dthompson>wild guess: are you using 'match' but haven't imported it?
<lechner>dthompson / thanks! your experience is impressive! that was it
<lechner>dthompson / i was in the guile REPL and had forgotten to import it
<dthompson>I... may have run into this a few times :P
<lechner>Hi, has anyone here tried arei over geiser?
<dthompson>iirc the two are incompatible but I don't know for sure
<lechner>incompatible?
<dthompson>arei is intended to be a replacement for geiser. it uses a completely different protocol.
<dthompson>I haven't used it because it doesn't provide the regular Guile REPL experience
<lechner>ah, okay. i have to learn. maybe abcdw, who is present, has some more advice
<lechner>dthompson / while you are here, i have a difficult debugging problem in guile-pam i'm hoping to bounce off of someone. it would only take a minute or two
<old>lechner: that ice-9 match error is such a pain ..
<old>how many time I've encountered this error and scratching my head
<lechner>old / thanks!
<lechner>Hi, is there a conditional in libguile that checks whether Guile mode is already active?
<dthompson>lechner: what's your question?
<dthompson>we'll see if I actually know the answer
<lechner>dthompson / Hi, and thanks! At this point, I am looking for spiritual guidance
<lechner>I rewrote Linux-PAM in Guile, which makes Guile modules configurable and accessible to a large user base. i think it has potential.
<lechner>unfortunately, it does not work when called from a guile script, most notably my reimplementation of login and getty
<lechner>the error i get is not consistent (!) but generally looks like this https://bpa.st/C76Q
<lechner>a function pointer is not that but a procedure. in my mind, that looks like a previously implicit conversion did not take place because libguile was already in Guile mode (but it could of course be something else). Does that theory hold any water?
<lechner>everything works when called from ELF via libpam
<lechner>it makes PAM modules accessible to a large user base
<lechner>i have used it in production with mingetty and greetd as well as GNOME for over a year
<dthompson>oof, never good when backtrace printing fails
<dthompson>I can see that the code is using eval and failing
<lechner>thanks! is it failing inside the eval?
<dthompson>seems to be, but I can't really tell what's wrong from the info available
<lechner>i have been unable to isolate the bug in any of my guile code but I also have a small C module. maybe I have to go through again. It's old style, with print statements
<lechner>my debugging method, that is
<janus>how do i use srfi 9 records from a lalr parser?
<janus>i tried having my parser call e.g. make-decl
<janus>but i get this error:
<janus>ice-9/eval.scm:213:45: Wrong type to apply: #<syntax-transformer make-decl>
<janus>maybe i am not including the file with the types in the right way... since i use 'include'
<janus>but i tried to use modules, and i can't get them to export right
<janus>another thing i tried is regular guile records, which seem to have less boilerplate, but since srfi is recommended, i thought i should stick with that
<janus>this is the tutorial i am working with: https://wiki.call-cc.org/eggref/5/lalr
<janus>it's for chicken , but with minor adjustments it works for guile
<janus>on the rhs you can see it calls regular functions like cons , add-binding, invoke-proc.. that's where i am trying to call make-decl