IRC channel logs
2022-11-17.log
back to list of logs
<w0ll3q1uszxabiwo>How the hug do i contribute an example code to the guile docs `7.5.3.5 Fold, Unfold & Map` so that i can avoid screaming at monitor for it to be hot garbage next time? <w0ll3q1uszxabiwo>i want to add example inspired by racket to the thing to make it more understandable <drakonis>but map is explained earlier in the documentation? <drakonis>anyways, anything interesting happening lately in guile land? <ArneBab>manumanumanu: can you give me the subject-line of your patches? I???m currently swamped with email <sneek>cow_2001, you have 1 message! <sneek>cow_2001, old says: where they are in their reading of the Guile's manual <cow_2001>i've gotten stuck at the API. i'm not much of a C programmer, so the API chapter is... ah... <old>you can skip the part that talks about C in the API if you're only interested in pure Scheme <haugh>that's pretty much what I'm doing <haugh>although I'm trying to keep an open mind about it because it seems like a feature set that could one day be life-changing <cow_2001>i also want to learn C, but maybe i shouldn't learn it by reading Guile C API <_< <old>Then hack your way by looking at small code base that are not too archaic or make a small project <old>From what I remember, to learn C I've read the entire GNU Bison manual and implement a JSON parser in C with it <old>Quite a good exercice <old>Btw if you read the classic from R&K, this is a very old C. Modern C is a bit different but you will get at least the base of it <old>Probably avaible for free at your local library ;) <cow_2001>there is also the recent RMS guide, but it has no exercises <cow_2001>some of the exercises in K&R are ill defined :| <cow_2001>there was an exercise where you need to find the maximal and minimal representable values of various types. these values are available in the headers, but they also give extra points for creative hacks which are probably platform and compiler dependant :| <old>I'm not sure if you will find a strong community around C on IRC <old>Nothing to lose to try I guess <cow_2001>they are pretty strong, from my grass leaf vantage point <cow_2001>do you find yourself learning better when you learn one thing for a period of days or a few topics per day? <old>I learn better by reading a lot then applying my reading <dalepsmith>K&R is great. Most everyone learned C from that. Back in the day, I used to read a lot of usenet posts. <old>I often read almost the entire book then I implement something with my learning <old>Ofc, re-reading chapter for clarity is often done also <old>But that's just how I learn. Everybody is different <cow_2001>but do you slice up your day learning for an hour topic A then an hour of topic B, etc or do you dedicate a week for topic A then a week for topic B etc? <dalepsmith>Yah, you have to "do the exercises". Need to solve a real-world problem. Make your head work at it. <cow_2001>the question is the frequency of topic switching, i guess <old>Well if by topic you mean switching between Computer Science and Biology for example <cow_2001>i want to learn C, Guile, and data science in this coursera course <old>Often at a variable frequency of 1-2 weeks <dalepsmith>For me, a first reading of anything is only partial. After a while I go back and I see things I missed earlier. <cow_2001>so you dedicate yourself for 1 or 2 weeks for a topic <old>Around that yes. It really depend on my schedule to be honest <old>Right now I'm writting my master thesis, so most of my lecture are off for a bit <cow_2001>i try not to miss anything and understand everything and it makes reading way too slow. need to let go. <old>cow_2001: Skkim through is also a good thing <dalepsmith>More like I don't pick everything up on the first pass. <old>Read fast, learn fast. Then go back to re-reading when needed for more clarity <old>Typically why I have the book in paper, so I can re-read whenever I want anywehre (subway, bus, etc.) <old>It's the text book that I had at the university. I would not read everything since it's 1200 pages, but it's a solid reference manual <cow_2001>dalepsmith: you are just a natural skimmer! ;p <cow_2001>really, i have to fight the urge to be thorough. <lilyp>they have tests whether you're a chad? <old>weird name for a database textbook PF I agree <old>sneek: tell stis welcome <old>Is there any Guile conference/talk for the community usually? Something like Guix day. <pinoaffe>old: there have been some guile-related talks at fosdem, iirc <yosik>Hi everyone! It looks like `guile -c "(list-ref '(1 2) -1)"` segfaults on 3.0.8. <daviid>yosik: 3.0.8.71-dadee-dirty oesn't segfault here, it correctly reports an error, fwiw <old>I also get segfault with 3.0.8 from guix <daviid>in guix, i pretty sure (list-ref lst out-of-range-index) correctly raises an exception, since guile's inception <old>guile-next is 3.0.7 so as yosik said, it's fine <old>confirm I just get a Value out of range error <dalepsmith>And I can confirm it throws and exception for 3.0.8.71-634ca <lilyp>Also got a segfault for (list-ref '() -1) <lilyp>Possibly the negative integer is what makes this crazy ??? (list-ref '() 0) throws <old>Here's the backtrace with GUILE_JIT_THRESHOLD=-1: 7 <dalepsmith>exp@entry=(list-ref (quote (1 2)) 4611686018427387903)) <old>this is fixed on main branch <old>Version 3.0.8 as: range_error (arg, 0, scm_integer_from_uint64 (UINT64_MAX) <old>When it's supposed to be: range_error (arg, scm_integer_from_uint64(0), scm_integer_from_uint64 (UINT64_MAX)); <old>I think that solve it <dalepsmith>Ahh. yes. NEVER expose a bare 0 (or NULL) as a SCM. <old>Can't wait for 3.0.9 :)