IRC channel logs
2017-09-06.log
back to list of logs
<Apteryx>Any hints as to what I'm doig wrong would be appreciated! <cmaloney>it looks like it's having problems with your comments <cmaloney>though I can't run it locally because it's complaining that i don't have match <cmaloney>(assuming that the bit between "" is a comment or docstring or ...) <Apteryx>cmaloney: thanks! Sorry, there should be a hyphen between ice and 9 in my (use-modules (ice-9 match) ...) <Apteryx>But even with that I still get the error in comments <ft>Apteryx: Doesn't #:key require define* from (ice-9 optargs)? <Apteryx>oh, that must be it... ah. I find Guile pretty tricky to get started with, it seems for every small thing I need a use-module ;) <ijp>you shouldn't need to import define* <ijp>(but yes, you should be using it) <ft>Is it in the default namespace? <Apteryx>Is a map in a map the best way to combine ("a" "b" "c") and (1 2 3 4 ...) into ("a1" "a2" "a3" "a4" "b1" "b2" ...) ? <ft>There's a map implementation in (srfi srfi-1) that allows multiple lists to be traversed, IIRC. <ft>(map f lst1 lst2 ...) <ft>f then takes as many arguments as you provide lists to map. <ft>Shortest list decides how long the procedure goes on. <ijp>Apteryx: yeah, append-map a map to get a cross product <Apteryx>Hm, I think the srfi-1 map would solve a different problem. <ijp>if it got any more complicated, use a looping macro like srfi41 <Apteryx>Also, I find myself using streams (srfi-41) simply to generate lists... And there's no stream-append-map for example. Is there a simple non-generator way to generate lists such as with range(10) in Python? <Apteryx>nice! Now I'm wondering what iota means ;) <ft>I would have thought that with srfi-1's map, that `f' would just be a string-concatenate and a number->string with those two source lists. <ijp>it doesn't mean anything, the name was taken from APL <ft>Meh. I just reread your question. Misunderstood. Scratch everything I said. :) <Apteryx>What should I use between floor or round? I'm using this with log10 to determine the width of a number (in digits). <happy_gnu[m]>So in The Land of Lisp I am on the part of the periodic table of loop macro <ijp>apteryx: floor is probably more appropriate <happy_gnu[m]>I am understanding why racket has (first '(list)) or second or all that <Apteryx>Is there a way to unload a module? I don't want map1 from srf1, I want plain map. <Apteryx>I could kill my REPL and start over, but there must be a way? <Apteryx>How do I convert a float to an integer? <ijp>assuming it has been rounded, inexact->exact <ijp>(IMO the rounding functions should do it automatically) <Apteryx>Just a small function to help with generating OpenStreetMap addr:flat or building:flat entries. <nalaginrut>ACTION is looking CastXML which is alternative of gccxml for newer C++ compiler <Apteryx>Can the guix closure from guix pull be reused by 'guix system reconfigure ...'? I'm just wondering why it's rebuilding Guile 2.2.2. <reed__>Hi everyone. I'm pretty new to guile and lisp in general. Is there a way to have a file open in one terminal and every time you save it, the function and variable declarations are updated and available to a repl open in another terminal? <janneke>reed__: Guile's REPL command: ,re will reload the module you changed <janneke>or ,re (your module) in case you're not changing the REPL's current module <janneke>reed__: emacs with geiser are a perfect setup for this kind of thing <janneke>the guile manual has some tips on that <reed__>I've actually started to head down that road already. It seems to be working well. <reed__>Another quick question. How do you kill a process in the REPL? <reed__>I mean if I wrote an infinitely recursive function, is there a way to terminate its execution? <reed__>But I'm in emacs, so C-c is bound <manumanumanu>reed__: welcome! I am pretty new around here as well. I hope you will feel as welcome as I did. <reed__>manumanumanu: So far it's been great. Both guile and guix seem very welcoming and extremely helpful. <stis>Assume I have a macro that looks like (defined-if-nondefined 'o) and then ues (set! o 1). The problem now is that I get a warning for this symbol that I woul dlike to turn off for just this variable how? <stis> "report possibly unbound variables" <stis> ,(lambda (port loc name) <stis> (if (not (member name %dont-warn-list)) <stis> (emit port "~A: warning: possibly unbound variable `~A'~%" <stis>That will do it, but it needs to go into the guile sources <stis>Yes, I managed to get it working for one file, recursive compilation will not work though <stis>scheme@(guile-user)> (use-modules (language python module f)) <stis>;;; note: source file /home/stis/src/python-on-guile/modules/language/python/module/f.py <stis>;;; newer than compiled /home/stis/.cache/guile/ccache/2.2-LE-8-3.A/home/stis/src/python-on-guile/modules/language/python/module/f.py.go <stis>;;; note: auto-compilation is enabled, set GUILE_AUTO_COMPILE=0 <stis>;;; or pass the --no-auto-compile argument to disable. <stis>;;; compiling /home/stis/src/python-on-guile/modules/language/python/module/f.py <stis>;;; compiled /home/stis/.cache/guile/ccache/2.2-LE-8-3.A/home/stis/src/python-on-guile/modules/language/python/module/f.py.go <amz3`>ijp: actually it works under chromium using the following command <amz3`>chromium-browser --js-flags="--harmony-tailcalls" <amz3`>ijp: any idea, where is coming from the duplicate 'rest' argument I was talking about on the mailing list? <daviid>manumanumanu: yep, guile-gnome and also guile-clutter <amz3`>ijp: nvm, I found a workaround for the duplicate rest argument thing <amz3`>ijp: also there an issue with utf8 <daviid>manumanumanu: guile-gnome comes with examples, guile-clutter examples web page points to some examples I wrote that are not distributed with guile-clutter ... <daviid>manumanumanu: are you using guix? <ijp>amz3`: I haven't had a look yet, but I'll try to get back to you tomorrow <amz3`>ijp: the only thing I am missing is 'js-closure' procedure which will allow to submit scheme callbacks to javascript code