***wxie1 is now known as wxie
***wxie1 is now known as wxie
***apteryx is now known as Guest71302
***apteryx_ is now known as apteryx
***rekado_ is now known as rekado
<rekado>ArneBab: can you recommend a way to load a wisp file? I’m using a copy of (language wisp spec)’s “read-one-wisp-sexp” with “load”, but I see that the return value of (wisp-scheme-read-chunk port) doesn’t have any source properties. <rekado>ArneBab: never mind: it was all my problem! <dukester>Learning scheme using guile. Noob question OK? <justin_smith>dsmith-work: once again we fail to meet the SLA for random IRC drop ins <dsmith-work>"Don't ask to ask, just ask. Then wait. Hours maybe." <justin_smith>on some topics, I've gotten great time saving advice after a 48 hour wait on IRC <leoprikler>Still higher throughput than carrier pigeons, though. <dustyweb>leoprikler: carrier pigeons are high latency, but with TB+ sized microsd cards, they nonetheless may have incredible averaged bandwidth rates <leoprikler>Perhaps, but those may not be suitable for transportation under all conditions (e.g. heavy rain) <leoprikler>though I suppose the same could be said for paper <nij>There was an article in the CL circle a few years ago, claiming that CL is finally an (acceptable) scripting language (link: http://fare.tunes.org/files/asdf3/asdf3-els2014.html). To be honest, I don't understand that article well. But hoping to use Guile as my scripting language, I wonder if Guile satisfies what the article says? Is Guile "an acceptable scripting language" as well? <dustyweb>nij: it's heavily used as a scripting language here, yes <justin_smith>nij: historically it's been advocated as a replacement for other scripting languages, and it's designed to be embedable <nij>Thats my impression is, and also is what I hope for :D <dustyweb>nij: also "scripting language" is only vaguely defined, but yes, Guile can be used for every definition of it <justin_smith>nij: I don't know if it's "the official embedded scripting option for gnu" any more, but it's used in many programs <dustyweb>even in the case of writing manu-scripts for plays, as ArneBab has demonstrated ;) <nij>justin_smith: it might not be the case any more :(? <nij>dustyweb: reference please :D :D ?!?! <justin_smith>nij: I haven't checked so I'm being cautious in what I claim :D <nij>I mean ArneBab's showcase <leoprikler>I have no idea, what they mean by an acceptable scripting language either. <leoprikler>Like why would a scripting language even need a build system? <leoprikler>What about a build system makes a scripting language run faster? <justin_smith>in order to use a language that isn't portable without a build system? <justin_smith>I may be skewed here, but I think the actual motive for that paper is "we want our build system to be as general and able to leverage the OS as much as make" <justin_smith>with a minor side effect of demonstrating you could also do other random portable system stuff with cl if you jump through those same hoops <nij>maybe I should just go to #lisp and ask "What's the point of this paper.. [link]" :P <leoprikler>I think there's a nicer way of phrasing that question, but yeah, I somewhat agree with justin's reading. <nij>Yeah I won't do that.. <leoprikler>Tbh. it is more of an example why *not* to have a language/tool-specific build system. <justin_smith>as an aside, it's amazing how much languages can build little galapagos of closed of evolution - cl people know a lot of things the rest of us can learn from, and they also have conventions that are absolutely nuts <justin_smith>(of course I could say that about haskellers, or people who are forced to use c++, or clojurists, or...) <nij>(again just a joke. sorry) <leoprikler>to be fair, C++ has some features that I greatly miss in Scheme, like templates <ecraven>the one thing I'm coming to miss most is type declarations, that I can use at compile-time to decide things.. <ecraven>but templates are like macros, not like goops, aren't they? <justin_smith>ecraven: macros used to parameterize code over types though <justin_smith>leoprikler: have you ever used ml / ocaml? I like their version - parameterized modules which take one or more types as arguments, returning a namespace of functions over the specified types <ecraven>justin_smith: the problem [well, trade-off really] is not the calculation, but that you are fundamentally *missing* the actual type information. <ecraven>for example, I was playing around with some opengl stuff.. I'd like to just pass around bytevectors, which contain vec2, vec3, vec4 and so on. these could efficiently be passed along to OpenGL. but now, they don't have any more type information than "bytevector", so I cannot actually use them well in code <Anonymous____>Someone can gimme a help to solve an exercise? im completly lost** <justin_smith>ecraven: right, but in ocaml that's mixed with inference (which automatically figures out the types) and introspection (that tells you the types), plus (usually optional) declaration <leoprikler>To be fair, I like types as predicates actually. <Anonymous____>Its from an exercise from The Scheme Programming Language Ed4 <Anonymous____>I never have seen any kind of loop being possible withouth recursion or iterative construction using "gotos" internally <ecraven>justin_smith: yea, maybe I'd like a Scheme that works like ocaml :P <ecraven>I haven't looked at ocaml in a decade or two, I should do that again <ecraven>probably what I want is just plain impossible :D <justin_smith>ecraven: most ocaml code *can* work as sexps even (it's just considered weird to write it that way) ***Anonymous____ is now known as Anonymous__
<justin_smith>eg instead of "f(x)" they use "f x", and "(f x)" is the same <ecraven>what's a good book? Real world OCaml? <justin_smith>Anonymous__: we have looping constructs in scheme, eg. "do" <leoprikler>Anonymous__: You're supposed to use call/cc to create a loop in a similar way to setjmp/longjmp. <Anonymous__>justin_smith: i already did while and other using define-syntax, but i dont think author want this, because all of those have recursive means in his internals <justin_smith>Anonymous__: yeah, leoprikler has your actual answer here <leoprikler>I'm trying with you, I'll let you know once I've figured it out <Anonymous__>I just have seen about call/cc today, it seems like a goto with steroids because the state is back again <justin_smith>Anonymous__: right, which means you can do the thing with goto you initially said wasn't allowed <Anonymous__>I have read some examples in wiki too.. its very strange for me, but im thinking this cool also <Anonymous__>the author dont explicit says that iterative syntax is not allowed, but its dont seem to be what he wants <Anonymous__>the book have an answer leoprikler, but im not going to read it yet <justin_smith>ecraven: also, I would be remiss not to mention that rust borrows a *lot* of good features from ml, while being more mainstream and having a much more active community these days <ecraven>yea, but rust is an entirely different sort of language than Scheme, to my limited knowledge at least <justin_smith>ecraven: that's true - the first version of ml was written in a lisp, and in many ways it shows, rust is further away and tries to be more like c++ <dsmith-work>While Rust has some FP-like stuff in it, it is very much an imperative language. <cbaines>Yet Guile seems to crash, inside (backtrace) ! <Anonymous__>leoprikler: I did it with the help of ecraven in #scheme <leoprikler>that's the same as your previous one, just different brackets, no? <Anonymous__>I have missed the first step the last one because i will be not bounded.. i tried to use i in lambda passed to call/cc in the other version <dsmith-work>dukester\0: But answers might be slow.. Don't worry about waiting a day or two. <dukester\0>"Teach Yourself Scheme in Fixnum Days" says that (define foo bar) defines a global variable. AND to use (set! foo bar) changes the value. However, I can change the value by just re-defining foo. Is that normal? <civodul>cbaines: your example works for me; that is, it displays two backtraces: the first one from the 'backtrace' call, the second one due to non-continuable exception <cbaines>civodul, so you don't get the same output I do? <civodul>otherwise that'd mean 'getenv' is broken <civodul>yeah if i unset COLUMNS, i get the same error as you <cbaines>I'm pretty sure that's a sure sign that this is a bug in Guile <joshuaBPMan>Hello, I'm considering adding the (decode) module to guile's default (web ) module and friends. So it would be (web decode). <civodul>the error comes from the 'terminal-width' fluids <cbaines>I'm also getting more confident that this is a weird but, as the string->number call is wrapped with false-if-exception <joshuaBPMan>would ya'll be ok to add this to guile's web implementation? <cbaines>civodul, you're definitely testing using a script, rather than a REPL? <cbaines>the behaviour is different in a REPL <civodul>cbaines: yes; and indeed, at the REPL, i can call (terminal-width) with COLUMNS unset, and it returns 72 <civodul>you're using a pre-unwind handler here <civodul>whereas false-if-exception only sets a post-unwind handler <cbaines>what, so the Guix Build Coordinator code is not responsable for error handling inside of (system repl debug)... <cbaines>hmm, what you said made sense initially, but I'm not so sure now <ft>dukester\0: There is also a way to use define inside of another definition, introducing a name within another scope. Using set! always modifies the value of the symbol that's in scope. It doesn't introduces a new binding. <ft>dukester\0: On the top-level, using (define foo ...) after a previous (define fo ...) will replace the earlier definition. So in that case it'll seem similar. set! modifies the previous definition. <ft>What I said isn't really limited to the top-level either. <justin_smith>also, set! works with bindings created by let, and unlike calling let again it actually changes the variable rather than hiding it <cbaines>civodul, maybe it is with-exception-handler that's breaking false-with-exception within (system repl debug)... <cbaines>I switched out with-exception-handler for with-throw-handler, and (backtrace) doesn't crash *wingo looks at removing ltdl dep, for the nth time <wingo>i am assuming that these days, .la files are useless <wingo>i know that fedora/redhat/etc delete them from their packages <wingo>i see that debian removes them as well <wingo>this may be a 3.2 change tho so i guess i should branch :/ <wingo>maybe we could drop the dep in 3.0 tho, if functionality isn't changed <nij>Are there ql/asdf equivalents for guile? <wingo>not really :/ most guile hackers end up using guix for that, as a more general user-space package manager <wingo>there was an attempt a while back to make a guile-specific thing but afaiu it did not succeed <wingo>but guix does it better than guile could have done in many ways <daviid>wingo: hello! is there any hope that module-use! bug in 3.0 can be solved? <nij>so I just want to write a little script that deals with csv files.. <nij>how would guix help in this case? <nij>(I noticed that it's not as easy as in CL to find a package that helps deal with csv) <daviid>it was first reported (not by me but that does matter) here bug#43025 <wingo>nij: if guix packaged a csv package, it would be as simple as "guix install guile-csv" :) <nij>OH! I didn't know it's under "guile-charting" :-( sorry for that <nij>Any tips on searching packages? <nij>Also, I heard that comparing to CL, guile might lack of many packages. Would you recommend me to use cl as my main scripting lang as opposed to guile? <nij>ft: I checked that page, and searched "csv" with no luck. <wingo>CL may well have more packages! <ft>I wasn't trying to suggest that it was complete in any shape or form. :) <nij>ft: sure :-) I get that. Thanks for the suggestion anyway!! <wingo>yeah library availability is getting better but not like python-level :) <daviid>wingo: g-golf needs module-use!, not a works around 'as proposed' - no pun, there is a real problem with the work around, which offers a 'static' re-export, unlike module-use!, which does the right thing ... let me know if you need more info - the bug report (first message) has a snipset <wingo>daviid: can look a it at some point, sur *wingo pleased that gnulib is still a thing <daviid>wingo: thanks you very much. I bleive it is the only 'stopper' for g-golf to work with 3.0 <nij>wingo: is python-level >>>>>>>> CL-level? <civodul>wingo: Debian has "always" removed .la files :-) <civodul>are you considering not using libtool? <spk121>wingo: re libltdl. These days dlopen() is available on BSD, Linux, Cygwin. The only holdout is Windows Native or MinGW, but, cygwin has Windows Native to dlopen conversion code <civodul>i hit a .so/.dylib issue a couple of weeks ago, which i thought didn't exist anymore <civodul>but if that's the only problem, that should be manageable <spk121>also, once I replaced ltdl with gmodule to see if I could. There's a tree in the repo (wip-replace-ltdl-with-gmodule) not that you'd want to add a gmodule dependency <civodul>(and ltdl didn't help in this case anyway) <wingo>spk121: that would be really nice if we just had to have a special case for mingw. <wingo>our needs are not so complicated so perhaps we could locally define just the parts of dlopen/* that we would need, and otherwise just code to the dlopen api <spk121>wingo: IMHO, that is what you should do. Code to dlopen. Borrow Cygwin's dlopen for posix-w32.c should MinGW or Windows Native be resurrected. <wingo>spk121: tx very much for feedback. (does mingw not work right now??) <daviid>ecraven: ywrt opengl, are you aware of guile-opengl? <dsmith-work>If ltdl goes away, will that fix the long standing misleading error message that happens when it can't find the .so OR the init func returns an error? <wingo>spk121: weird that it differs from 2.2, as i don't think much OS-related changed. but ACK. obviously working on windows would be good! <wingo>& please feel free to commit anything that's upstreamable *wingo will update gnulib soon; have a half-done update locally