IRC channel logs

2020-05-03.log

back to list of logs

<lafrenierejm>Does guile have anything like clojure's comment function?
<lafrenierejm>Or does one have to comment out by line using ;;?
<mwette>do you mean #;(this is an expression which is commented out)
<mwette>you can comment-out multiple lines with #| ... |#
<lafrenierejm>mwette: The first one is exactly what I meant! Thanks so much!
<lafrenierejm>mwette: Where in the documentation could I have found that out? I'm just starting to work in Guile, and I'm pretty lost.
<cyclopsian>lfam: that SRFI looks like the best reference, the only difference in guile's implementation is that it adds a path separator in between
<lafrenierejm>Does guile have an equivalent of clojure or hy's threading macros?
<Aurora_iz_kosmos>SRFI-62, in the manual. "S-expression comments" was the thing.
<Aurora_iz_kosmos>It'd really be nice to have those SRFIs actually in the manual rather than only hotlinked though.
<lafrenierejm>Aurora_iz_kosmos: Was that addressed to me? Or lfam and cyclopsian?
<Aurora_iz_kosmos>lafrenierejm: Part indicating where it is was aimed at you, complaint about hotlinking was a general thing.
<Aurora_iz_kosmos>lafrenierejm: The fact it's only linked means you simply couldn't find it in the manual.
<lafrenierejm>Aurora_iz_kosmos: Got it. TY.
<dsmith>lfam: I think "vicinity" was an attempt at an abstract way of saying "directory" or "folder".
<mwette>lafrenierejm: I would have expected it to be in the "comments" section of the manual https://www.gnu.org/software/guile/manual/guile.html#Scheme-Read, but it's not. I could not find it, but I'm pretty sure it's in the manual.
<mwette>SRFI-62, Section &.5.36.
<dsmith>sneek: later ask wingo How does guile-cairo get at guile-snarf-docs and guile_filter_doc_snarfage which are not normaly installed?
<sneek>Will do.
<cyclopsian>I tried to build the guile-cairo docs and it wouldn't work until I copied those scripts manually from libguile
<cyclopsian>And even then it still fails because it uses the wrong script (guile-snarf-docs-texi instead of guild snarf-check-and-output-texi)
<cyclopsian>And even then, the help still doesn't load because documentation-files is not being correctly appended to
<cyclopsian>:/
***catonano_ is now known as catonano
***Aurora_iz_kosmos is now known as Aurora_v_kosmose
<tohoyn>guile 3.0.2 gives warnings like "imported module xxx overrides core binding yyy". is it possible to get rid of them?
***amiloradovsky1 is now known as amiloradovsky
<RhodiumToad>is the relevant module using #:replace ?
<tohoyn>RhodiumToad: The modules are (srfi srfi-1) and (rnrs exceptions)
<RhodiumToad>I don't get that warning?
<tohoyn>looks like srfi-1 has "replace" for map-in-order but I still get the warning
<RhodiumToad>you're sure it's loading the correct file?
<RhodiumToad>I get nothing
<RhodiumToad>(use-modules (srfi srfi-1)) in the guile3 repl and I just get the prompt back, no output
<tohoyn>ok. I'll check.
<tohoyn>no warning
<tohoyn>it's probably a problem in my source code
<RhodiumToad>are you tweaking the load-path at all?
<tohoyn>yes
<tohoyn>I set GUILE_LOAD_PATH to point to my own source directory
<weinholt>civodul, in case you're still searching for a d-bus library, i've whipped up one with just the fundamentals: https://gitlab.com/weinholt/ac-d-bus
<civodul>weinholt: oh excellent, thank you!
<civodul>funny name :-)
<civodul>and that's brand new, right?
<weinholt>yes, fresh from the editor
<civodul>heheh, good
<stis>tja guilers!
<manumanumanu>tja stis!
<manumanumanu>tjabba, even.
<civodul>weinholt: pushed a Guix package for guile-ac-d-bus :-)
<stis>nice!
<weinholt>civodul, that was fast!
<mitigate>I'm trying to use guile-lib for the first time: I installed it in gentoo without doing anything special - but guile doesn't seem to find the modules. For eg. configure.ac checks fail. doing a (use-modules (debugging assert)) fails - and guile is installed
<mitigate>is there some config needed to get guile to load the module from say /usr/share/guile-lib/debugging/assert.scm, or from /usr/lib64/guile-lib/guile/2.2/site-ccache/debugging/assert.go
<mitigate>all i get is a (scm-error misc-error #f "~A ~S" ("no code for module" (# #)) #f)
<mitigate>I guess I could do a export GUILE_LOAD_PATH=/usr/share/guile-lib - that works but it puts stuff in ~/.cache/guile/ccache. but GUILE_COMPILED_PATH=/usr/lib64/guile-lib/ or GUILE_COMPILED_PATH=/usr/lib64/guile-lib/guile/2.2/site-ccache/ doesn't work
<daviid>mitigate: did yu manually install guile-lib or you're using a gentoo package?
<mitigate>i was using the gentoo package ("ebuild")
<mitigate>but then all the users have to agree to the copyright
<mitigate>misfire
<daviid>mitigate: so it is not a guile-lib gentoo package
<mitigate>how is it supposed to work
<daviid>well if it was a distro package, like debian or guix have a guile-lib package, not being able to use the package module(s) would be a distro bug, which is why I asked
<daviid>if yu manually installed guile-lib, yo need to know where the source code module have been installed and add that path to GUILE_LOAD_PATH
<mitigate>are the distros expected to set GUILE_LOAD_PATH (as I said above) for the user when installing guile-lib ?
<daviid>well, as i said, if yu did 'gentoo-install guile-lib' no, but if guile-lib is not a gentoo package, then yes
<daviid>so it appears there is no gentoo guile-lib package? but i'm not familiar with gentoo
<mitigate>the recipe isnt doing anything special. how does debian do it
<daviid>apt-get install guile-lib
<daviid>mitigate: where are the guile-lib installed on your machine?
<mitigate>i noted the locations above ^^
<mitigate>i dont have debian. do you?
<daviid>mitigate: i was just using debian as an example, it doesn't matter
<mitigate>yeah it doesnt matter what distro -the question is how it is supposed to work
<daviid>this should work export GUILE_LOAD_PATH=/usr/share/guile-lib
<mitigate>i mentioned that above.
<daviid>well it should not complain then
<mitigate>i mentioned a problem with that above.
<mitigate>it is not using the compiled package from the guile-lib's make install
<daviid>i don't think guile-lib does install the compiled module, but i don't remember
<mitigate>sigh
<daviid>mitigate: that is not a problem :) it just means that it will comple those for you (on a per user bses) at first attemt to use its modules ...
<mitigate>Guile-Lib version 0.2.6.1: The script pre-inst-env.in has been fixed so it properly sets GUILE_LOAD_PATH and GUILE_LOAD_COMPILED_PATH
<mitigate>you posted that item on savannah!
<daviid>hum, let me check :)
<mitigate>i'm out of time. i'll check again later
<daviid>mitigate: i don't know what gentoo ebuild does, but if you use the autotool chain, _and_ specify --with-guile-site=yes as a configure option, then yes, it will use guile's sitccache directory for te compiled modules
<daviid>and guile's global site dir for the ource modules
<daviid>sneek: later tell mitigate I don't know what gentoo ebuild does, but if you use the autotool chain, _and_ specify --with-guile-site=yes as a configure option, then yes, it will use guile's (global) site dir for the source modules and guile's siteccache dir for the compiled modules, and in that case, you, a a user, dont ned to do anything tbe able to use guile'lib's modules and they all should be (pre)compiled
<sneek>Got it.
<rlb>hmm, I imagine this might be intentional, but just noticed that (@ (foo) ...) in a file anywhere will cause a (resolve-module '(foo)) at startup, creating a potentially empty/dummy module, even if the @ ref is inside a function that's never called. Was fairly mystified for a bit, but I "fixed" my issue by changing it to an explicit (module-ref (resolve-module ...) ...).
<civodul>rlb: i think @ does resolve-module #:ensure #f
<rlb>civodul: it didn't appear to.
<rlb>but perhaps something else is/was going on -- have a bunch of other moving parts involved. But switching to the explicit resolve/ref *did* fix the problem.
<rlb>Also, was surprised it resolved when the module is loaded, as opposed to when the function is called...
<rlb>(the function containing the @ ref)
<iv-so>where can i read more about bytecode?
<iv-so>is it completely platform independent?
<rlb>No, but there are a limited number of "flavors". If you look in your ~/.cache/guile/ dir, you'll see what flavor your platform needs.
<rlb>And iirc the dist archive contains "all" the flavors precompiled. There are just a couple/handful, I think.
<iv-so>i am interested in cross-compiling guile libraries
<rlb>Hmm, well I'd assume that guile's "make dist" must know how to precompile all the flavors for ./modules/ , so maybe you'd be interested in something similar?
<rlb>ahh, another possibly relevant bit: "guild compile -h" lists the --target option.
<iv-so>wow, thanks
<rlb>certainly
<rlb>Might also be able to find the "list" of "all" targets or however guile does it by poking around in the Makefile.am's.
<daviid>str1ngs: I'd like to work callbacks, prepred a 'templte', here https://paste.gnome.org/pusrhf6to - but as it is, it fails, and that is (according to the GI introspection friends) a bug in the annotation for the function, for its child-setup-data-destroy, which manual says it may be NULL, but the annotation in the typelib, which I check in g-golf source code of course, says it cant
<daviid>str1ngs: so the question is, do you kow another function, that would not be part of an unstable lib/typelib that I could use to learn and implement what's missng in g-golf? I tried, an asked on introspection, but so far could not find any
<daviid>I tried GtkWindow, GtkApplication, CltterActor, GApplication, looking in their respective manual, but couldn't find any
<daviid>str1ngs: also, when clicking on the (manual entry) GSpawnChildSetupFunc for the child_setup argument, I get a 404 - do you happen to know where that doc is?
<daviid>though I really wish I cn find a simpler and stable function to learn and play with ...