IRC channel logs

2021-04-01.log

back to list of logs

<soda__hobart>you can use the tree *** matching syntax from ice-9 match on an alist, right? i am trying: (match '((#:a (#:b . 1) (#:c . 2))) ((p *** 1) p) (_ #f)) which gets me #f, but i must be messing something up, because i tried something similar the other day and got '(#:a #:b) for the output
<soda__hobart>well, actually it was like this: (match '((#:a . [(#:b . 1) (#:c . 2)])) ((p *** 1) p) (_ #f))
<soda__hobart>this works: (match '(#:a (#:b 1) (#:c 2)) ((p *** 2) p) (_ #f))
<jadedctrl>hey, does anyone know of a way to change site-dir?
<daviid>jadedctrl: you may decide where guile is installed, but not the fact that the site-dir is 'computed' based on guile's effective version, iiuc your question
<jadedctrl>daviid: alright, thanks
<daviid>jadedctrl: what are you trying to do?
<wingo>moin
<abcdw>Hi guile! Is there a function in guile similar to interpose in clojure? https://clojuredocs.org/clojure.core/interpose
***apteryx_ is now known as apteryx
<wingo>getting the details of inlinable exports right has been a pain and the pandemic is not helping!
<wingo>also the fsf board shenanigans are not helping :P
<leoprikler>abcdw: well, there is string-join, but I don't think that counts ;P
<zzappie>abcdw: if you are after transducers there is srfi-171 btw
<abcdw>leoprikler, zzappie: Thank you for tips, implemented it myself https://git.sr.ht/~abcdw/rde/tree/master/item/gnu/home-services-utils.scm#L192
<zzappie>I also went for fold :)
<zzappie> https://paste.debian.net/1191963/
<zzappie>oops it doesnt work with '()
<leoprikler>Same as string-join, but without join and string, so "-"?
<zzappie>leoprikler: didnt get you. I'd expect it return '() for '() input
<leoprikler>twas but a silly pun
<zzappie>ah I sometimes bad at parsing puns
<leoprikler>well, puns are context-sensitive, so LALR won't get you anywhere :)
<zzappie>leoprikler: well this was a nice one :D
<abcdw>zzappie: Your implementation is a good one!
<abcdw>leoprikler: (: Both puns are great)
<dsmith-work>UGT Greetings, Guilers
<civodul>roptat: hey! re <https://gitlab.com/guile-git/guile-git/-/merge_requests/27>, could you add tests?
<civodul>OrangeShark, mbakke: i'd like to make a Guile-Git release shortly, presumably 0.5.0 according to semver
<lampilelo>is having a global struct with data and then accessing, reading and writing to its fields from all over the place is common in c? omg i want pure functions
<lampilelo>i'm trying to extend a program but it's kinda difficult to understand this spaghetti code
*dsmith-work hands lampilelo a pasta-friendly comb
<lampilelo>i think i'll have to use it and redesign some stuff, at least it's not a big project
<lampilelo>straighten things, if you will
<dsmith-work>Back in the DOS days, I was using a bbs that had uucp capability (which is why I was messing with it). Was all globals everywhere.
<dsmith-work>Some functions were merely to set globals.
<dsmith-work>Was just about impossible to reason about.
<dsmith-work>The docs even said that the author breaks it all the time when touching it.
<lampilelo>wow, yeah, sounds like fun
<dsmith-work>Ugh
<dsmith-work>I thought I had successfully suppressed those memories.
<lampilelo>:D
<zzappie>I was given bunch of industrial electronic units to do factory process automation. Those things were programmed in STX language...
<zzappie>This is the last thing you want to learn. All tools are proprietary and terrible
<zzappie>In fact I found it so unusble that I coded up code generation in python for an enourmous state machine with bunch of globals
<zzappie>This might sound clever but boy it was my first coding job and that was a real monster :)
<zzappie>amazingly this thing still works
<roptat>civodul, sure :)
***nckx is now known as Thunderbi