IRC channel logs

2016-03-20.log

back to list of logs

<amz3>I bored of writing bindings..
<stis>well guile-log is ugly C code and you could base it on actually kanren and not minikanren in stead.
<amz3>I don'follow
<stis>minikanren has a completely different solver philosphy and guile-log and kanren share the approach
<stis>well using a filure thunk and a continuation closure as parameters to every logical predicate
<amz3>Sorry, I don't understand anymore the 'assignement'
<amz3>How does this related to mk?
<stis>minikanren in stead reads a return value and to the action on the values returned
<amz3>stis: ^
<amz3>So?
<amz3>You think I could rewrite minikanren to take a failure thunk and continuation closure instead?
<stis>that's kanren
<Guest27396>anyone has a small fully autotool chained project where the doc is partially in *.texi and partially extracted the API from source, so I can copy the setup?
<stis>amz3: ^^
<amz3>stis: What's the idea you have for me, I don't understand
<amz3>Sorry, my english has its limits
<stis>Well if you want to copy the guile-log code you need the kanren version of it to stay as much true as possible. But if you like to work nore then use minikanren. But then you are more on your own.
<daviid>ACTION 
<Guest9364>anyone has a small fully autotool chained project where the doc is partially in *.texi and partially extracted the API from source, so I can copy the setup?
<amz3>stis: ok, what should I code?
<stis>that is the best code reuse id with kanren. But yeah doing it in minikanren would grow your beard so mayby not take that approach.
<Guest9364>why does it say Guest9364 and not my nick?
<amz3>Guest9364: dunno, it keeps changing all the time
<Guest9364>terrible
<amz3>Guest9364: maybe you did not identify yourself
<amz3>Guest9364: AFAIK, only Guile does that and the last time I saw a similar question it said to use copy the docstrings by hand
<stis>well first of all, decide if we really need another parser framework then go to work, try understand the guile-log sources, I'll guide you and have some fun trying to write the framework in minikanren :-)
<Guest9364>try
<stis>That's my suggestion amz3: you decide of cause :)
<amz3>Guest9364: 00:10:42 freenode -- | daviid: Nick/channel is temporarily unavailable
<amz3>stis: I'm not sure I understand, please expand your explanation
<Guest9364>amz3: did register and it says freenode -- | You are now identified for daviid.
<amz3>Guest9364: you should contact freenode or something
<Guest9364>sure
<amz3>stis: your idea is to rewrite guile-log framework in minikanren?
<daviid>ha
<daviid>had to regain
<stis>Not everything, just the parser framework or a parser framework.
<stis>everything is just too much
<amz3>the parser framework...
<amz3>ACTION thinking
<ozzloy>how do i use sxml simple? can someone give me a minimum example file?
<amz3>ozzloy: what do you want to do?
<stis>amz3: getting late here, need to go. I follow the logs so just shout if you need to conversate :)
<stis>zzz
<amz3>:)
<amz3>night
<ozzloy>i'd like to write something like (html (head (title "helo wrld")) (body (h1 "hi wrld"))) and get "<html>..."
<davexunit>ozzloy: use SXML
<amz3>ozzloy: use sxml->xml procedure
<ozzloy>oh, maybe i got it now. (sxml->xml '(html ...))
<ozzloy>i didn't know i had to quote it
<ozzloy>is there good documentation about this somewhere?
<davexunit>in the guile manual
<ozzloy>i'm reading through guile-web sources
<ozzloy>davexunit, this page? https://www.gnu.org/software/guile/manual/html_node/Reading-and-Writing-XML.html ?
<ozzloy>lol @ https://www.gnu.org/software/guile/manual/html_node/SXML-Overview.html#SXML-Overview
<ozzloy>if i want to write something for this, how do i do that?
<ozzloy>like a quick start complete minimal example file
<amz3>look at guix-web or haunt
<amz3>or https://git.framasoft.org/a-guile-mind/nanoblog/blob/master/nanoblog.scm
<davexunit>hey, wingolog post on HN front page! https://news.ycombinator.com/item?id=11320320
<davexunit>upvote to keep it there and maybe generate some discussion
<amz3>already done
<davexunit>:)
<amz3>ozzloy: you want to write SXML overview?
<ozzloy>for example: https://www.refheap.com/116169
<ozzloy>also, is there refheap for guile?
<amz3>usually people use paste.lisp.org
<amz3>I prefer www.friendpaste.com
<amz3>you should add an example use of sxml-match and sxpath
<amz3>but maintainer might be better suited to answer the Q?
<ozzloy>i think a better idea would be to remove the content-type and make it just output xml for html
<ozzloy>so forget about making it valid as a cgi script
<ozzloy>just output the html
<amz3> yes
<ozzloy>is there a better way to do the '<!DOCTYPE html>' part?
<amz3>I don't think so
<ozzloy>i see in xml->sxml there's a *TOP* on this page: https://www.gnu.org/software/guile/manual/html_node/Reading-and-Writing-XML.html#Reading-and-Writing-XML
<ozzloy>oh ok
<amz3>yeah there is another way I think, look at how guile haunt
<amz3>wait I look that for you
<amz3> https://git.dthompson.us/haunt.git/blob/HEAD:/haunt/html.scm#l110
<amz3>ozzloy: ^
<ozzloy>ACTION is sad gitorious is dead
<ozzloy>where is https://gitorious.org/guix-web/guix-web now?
<amz3> https://git.dthompson.us/
<ozzloy>amz3, super duper awesome! thanks!
<ozzloy>oh, lol, looks like they do the same thing
<amz3>written by the same person...
<ozzloy>with a function they wrote, doctype->html
<ozzloy>oh, i mean they just write out the root node, there isn't something in the sxml simple lib for it, it seems
<amz3>no
<amz3>it's not xml anyway
<amz3>sxml->xml remember
<ozzloy>root node isn't xml?
<amz3>doctype is not a xml
<ozzloy>i ... think it is?
<ozzloy>ACTION goes to look up root nodes in xml docs
<amz3>doctype is html it's no part xml spec
<amz3>good luck !
<ozzloy>oh, so it isn't! today, i learned!
<amz3>:)
<ozzloy>root node is not the name of the unmatched thing at the top. good to know.
<ozzloy>what are those things at the top then, like <!DOCTYPE> or <?xml version="1.0" ..> or similar?
<ozzloy>what's the name for those things?
<amz3>for html is doctype
<amz3>for xml in preamble i think
<ozzloy>amz3, thanks! now i know that is called preamble
<ozzloy>and doctype is one of the preambles, and html 5 requires the doctype preamble
<ozzloy>that makes naming much easier
<ozzloy> https://www.w3.org/TR/html5/syntax.html#the-doctype there's even an official doc!
<ozzloy>how do i suppress the compilation note? i see how to disable compilation, but i don't want that, i just want guile to stop telling me every time it compiles
<jyc>I'd like to know that too :P
<amz3>morning guilers!
<amz3>paroneayea: hi!
<amz3>paroneayea: do you know about articles similar to this one https://drboolean.gitbooks.io/mostly-adequate-guide/content/ch8.html ?
<amz3>I'm wondering whether i can use a monad with wiredtiger
<fhmgufs>Hi, I need some guile-gnome help again: what is the guile symbol for definitions like G_TYPE_BOOLEAN? Somewhere in the documentation it says <g-type-boolean> but that raises an error.
<amz3>davexunit: hi!
<amz3>I'm studying functionnal programming (!) and I am looking at the code of guile-combinators
<amz3>I'm wondering whether the monad you created merge the behavior of Maybe into the parser monad?
<davexunit>amz3: hmm, maybe!
<davexunit>I actually don't know
<amz3>did you learn monads using haskell?
<davexunit>amz3: nope.
<davexunit>guix and SICP taught me
<davexunit>SICP teaches you about a monad without ever using the term because it wasn't coined yet.
<amz3>okay
<fhmgufs>What's the proper way to create a <gtk-list-store> instance in guile-gnome?
<fhmgufs>So, I'm here again:
<fhmgufs>I want to create a <gtk-list-store> using (gtk-list-store-new) but I can't find the right arguments for that function.
<fhmgufs>I don't think that nobody used this funcion before.
<fhmgufs>I Have the following:
<fhmgufs>(gtk-list-store-new 5 <g-type-boolean> <g-type-string> <g-type-string> <g-type-string> <g-type-string>)
<fhmgufs>And it says: Unbound variable: <g-type-boolean> (also for the strings)
<daviid>fhmgufs: the arg is a lst
<daviid>a list of types
<daviid>also, it is <gboolean>, <gchararray> ... these are some exception in names
<daviid>see http://git.savannah.gnu.org/cgit/foliot.git/tree/foliot/p-dialog.scm line 323 and below for an example
<daviid>fhmgufs: ^^
<fhmgufs>Ok, thanks a lot! :)
<daviid>welcome!
<fhmgufs>guile-gnome is great work and Gtk+ programming in Scheme is fun (much clearler than C)
<daviid>yes, indeed
<daviid>fhmgufs: for the type, see section 4.2 of the Guile-GNOME: GObject manual
<daviid>fhmgufs: here https://www.gnu.org/software/guile-gnome/docs/gobject/html/gnome-gobject-gvalue.html#gnome-gobject-gvalue
<fhmgufs>Yes , no I see it, too. :)
<jmarciano>while listening to live streaming, I am multi-reading some guile: https://libreplanet.org/2016/streaming
<jmarciano>during listening to FreedomBox, how do I split string by \\n, maybe (string-split string #\\n) ? But this removes some of my "n" in strings ONLY.
<jmarciano>ok #\\newline, found it.
<jmarciano>I need readline completion by list
<fhmgufs>What's the nice negation function for booleans in scheme?
<fhmgufs>Ok, was just to lazy to look in the docs :)
<fhmgufs>Now I did it ;)
<jmarciano>please show me
<fhmgufs>jmarciano (not #t) => #f ;-)
<jmarciano>aha yes
<fhmgufs>wingo: Is it a bug that gtk-tree-path-new-from-string has two arguments? (https://www.gnu.org/software/guile-gnome/docs/gtk/html/GtkTreeModel)
<fhmgufs>Anyway, it's late.