IRC channel logs
2017-11-26.log
back to list of logs
<mwette>convention in unix/c is to return 0 on success (and often -1 on error) <daviid>lloda: thanks. I see, but quite honestly, I actually (much) prefer the approach I came up with, since the code is a lot shorter, cleaner imo, with no alloc at all on the C side ... but again, thanks for your ideas and example. The only convcern I had was to grab the pointer address size at run time, which I beleive I solved with this snipset <daviid>size_t pointer_address_size_c () <daviid> size_t n = sizeof(float *) * CHAR_BIT; <daviid>mwette: is size_t any diff from int in C? <mwette>on my mac/x86_64, sizeof(int)=4, sizeof(size_t)=8 <daviid>it seams this is not a valid http address <daviid>i get an error trying to open the site in a browser ... I get http-get <my web site>) with no error ... <daviid>ERROR: In procedure getaddrinfo: <daviid>ERROR: In procedure getaddrinfo: Name or service not known <daviid>I'm not (by no ean) an http guy by the way, just trying to help ... <daviid>$8 = #<<response> version: (1 . 1) code: 200 reason-phrase: "OK" headers: ((date .…> <happy_gnu[m]>now I have to learn how to output that to a file or something ahah <artyom-poptsov1>Oh wait, I was wrong: there's a chapter named "(guile) GOOPS Object Miscellany" in the manual where's object equality is discussed, including 'equal?' overloading. I just overlooked it for some reason. <amz3>I mean in theory it should return every document that do not contain 'duckduckgo' but in pratice it's easy to compute, so it should be an error <amz3>it's not easy to compute <amz3>it's easy to compute but it will take a lot of ressource <amz3>also if there is no positive tokens in the query, you can not score the results <amz3>what is best in terms of performance: to keep the computation exact until the end or use inexact numbers from the beginning \\cc ArneBab_ <ArneBab_>amz3`: that depends on the size of the problem. If exact numbers can handle it, I’d stick with them (because they are exact), but exact fractions can baloon in memory consumption. <ArneBab_>amz3`: if you want real big data stuff, you might want to adjust your algorithms to do optimized operations, like operating on the logarithm of the values to turn every multiplication into a plain (and much faster) addition. <ArneBab_>(I only saw that being done and know in theory how to do it, but I don’t have much real-life experience in doing that with Guile) <amz3`>ArneBab_: oh, I did not know about that trick <amz3`>ArneBab_: anyway, it's just to have an idea, it's very early in the project, I don't think optimising right now is a good idea <ArneBab_>I knew about the possibility in theory, but seeing it done in practice to speed up an algorithm by factor 1000 was something else :) <amz3`>I need to unit test the querying part of my search engine and then I will be *almost* ready for a demo <amz3`>hopefully it will be finished today <amz3`>I am not sure for what purpose <thomassgn>I apparently don't understand how to get the output from a system command... <thomassgn>trying this: (with-input-from-port (system "ag -l guile /home/thomas/bin") (lambda () (display (read-line )))) But keep getting the error: <thomassgn>I thought 'with-input-from-port' would set the output of command to current-input-port...? <amz3`>thomassgn: if doesn't work use open-process <amz3`>I made good progress, /me need to fix the UI now <amz3`>but I will do this another day <janneke>amz3`: mescc is part of mes, which goal is to replace GuixSD's bootstrap binaries with a full source bootstrap path <cbaines>I'm pretty sure that something in my Guile code is wrong, but Guile says the crash happened in ice-9/eval.scm... <cbaines>ice-9/eval.scm:155:9: ice-9/eval.scm:155:9: In procedure struct_vtable: Wrong type argument in position 1 (expecting struct): #<unspecified> <cbaines>Is there a way to get some more specific information about where the error occured? <mwette>try "guild compile -O0" on the file then run <sneek>Its been said that culturia is a search engine <cbaines>mwette, thanks, I ended up running the code directly from the REPL, which seemed to give a better backtrace <janneke>do we have a guile-2.2 specific cond-expand? <janneke>ACTION is having troubles with disabling an ellipsis macro for 2.0 only <janneke>hmm, it seems i cannot disable with-ellipsis test for guile-2.0 :-( <janneke>a string, where guile-2 is a symbol? <janneke>removed ugly sh scripting again and better psyntax with/without ellipsis test for mes :-)