<codemac>Would anyone mind helping me with a usage of syntax-case? <codemac>I'm trying to make my own verison of define-struct, but I think I have a deep misunderstanding somewhere, so I've reduced it to a small printer thingie, I'll paste here in a moment. <codemac>Basically, with syntax case, I'd like a way to go from a symbol, add some text around it, and then use it as a symbol again. <ijp>#,foo is (unsyntax foo), we could unparse that in the error, but I don't remember if we do that for unquote <codemac>it still doesn't work complaining about a raw symbol in macro, but I'm still struggling with syntax->datum stuff I think <ijp>codemac: basically, rather than deal with symbols, macros deal with syntax objects which carry around some extra information (source location, lexical environment, etc.) <ijp>syntax->datum strips it, datum->syntax adds it <ijp>the first argument to datum->syntax is an identifier whose information to use for the datum <ijp>so (datum->syntax #'name (string->symbol ...)) here <ijp>we should add an identifier-append, or an identifier-format or something <ijp>everyone has probably written their own <paroneayea>I feel like I've been working with them more and more, but have a hard time understanding a clear example of what *makes* something a combinator <paroneayea>is it the way that you can "chain" calls to each other? <davexunit>paroneayea: it's about a set of operations that satisfy the closure property <ijp>there isn't really a good definition <paroneayea>I thought closure was about the ability for a type of data contains more of that type of data <paroneayea>though I guess you can consider larger numbers to be "containing" the smaller numbers... <ijp>closure would be far too broad imo <paroneayea>what it "feels like" to me is that I can chain expressions <davexunit>paroneayea: the chaining happens because everything satisfies the closure property <davexunit>ijp is probably right that it is too broad, but I can't think of anything better. <paroneayea>I guess integer arithmetic doesn't feel like "closure" to me because I don't think of it as heirarchical <paroneayea>I should go over the picture language section again <ijp>in the lc, a combinator is a closed lambda term <ijp>in the no free variables sense <paroneayea>lambda calculus is something I need to understand better also ;) <ijp>if you know a functional language, you know about as much as you need to know <davexunit>paroneayea: think about map/filter/fold. there's no hierarchy there necessarily <ijp>maybe sprinkle in some church rosser to taste <davexunit>(filter odd? (map (lambda (x) (* x x)) '(1 2 3 4))) <davexunit>each expression evaluates to a list, so we can combine them. <quigonjinn>davexunit: It seems that the git repo for your guile-parser-combinators isn't working. I didn't check it yesterday <janneke>ACTION got records and lalr up in mes and parses the simplest of C programs :-) <janneke>slowly starting to appreciate the idea of a VM <ijp>I strongly suggest defining your generics in a module and importing that <kr2>That makes sense, thank you! <ijp>as an aside, you can have multi file gists <kr2>(I'm from a Java background) Essentially something to act as an interface, then implementation elsewhere? <kr2>Did not know that :) <ijp>kr2: basically I think merge-generics causes more harm than good <ijp>kr2: anyway, I think your issue is simpler, you didn't define a method for <b> on y <ijp>if you s/y/x/ it goes through fine <kr2>ijp: So I would hope it calls the method for <a> on y, as <b> is a subclass of <a> <kr2>What I am trying to acheive is have <a> as an 'abstract class' that defers the implementation of x to its subclasses, then have <b> as a concrete subclass implementing x <ijp>oh right, I misread some of that code <ijp>kr2: hmm, I've been trying a few different things, but I keep getting that error ***dje__ is now known as xdje
<ijp>yeah, I don't understandit <kr2>Thanks anyway, I don't seem to manage to get around it either, so I'll perhaps try the mailing list <davexunit>amz3`: it's not a solution. there's guile-gnutls, too. <davexunit>the problem is that guile doesn't support https out-of-the-box <amz3`>davexunit: it works out of the box, I compiled the sources from git yesterday <davexunit>amz3`: you cannot use guile's web modules with https endpoints out of the box <amz3`>the API is not very nice, but it's direct bindings of libcurl for which must have loads of doc <amz3`>guile-curl works out-of-the-box, it's not a builtin of guile <paroneayea>the gnutls hack that guix does still does I think leaks the descriptor right? <paroneayea>though as davexunit said, it should work out of the box <amz3`>you don't understand or don't want to understand <davexunit>amz3`: sorry but you're the one not understanding here. <amz3`>I understand that http-get should work with https, i'm not saying otherwise <amz3`>the bug in Guile is still valid <paroneayea>amz3`: I think you and davexunit are "close" in agreement: I think davexunit was saying it wasn't "the solution" <paroneayea>whereas you were saying "it's a current solution' <sneek>ACTION sprays icy cold water over the combatants <spk121>Hi. I saw mention of curl and (web modules) in the logs. Not ideal, but, the curl bindings and (web response) can sorta be made to work together.