00:34 offby1: it speaks well of you 00:51 (join) jeapostrophe 01:07 (quit) dnolen: Quit: dnolen 01:17 (quit) jeapostrophe: Quit: jeapostrophe 01:29 (quit) sstrickl: Quit: sstrickl 02:11 (quit) jonrafkind: Ping timeout: 244 seconds 02:17 (join) masm 03:41 (join) mceier 03:42 (join) hkBst 04:01 (join) misterncw 04:06 (quit) tewk: Remote host closed the connection 04:06 (join) tewk 04:10 (quit) DT``: Quit:  04:20 (quit) misterncw: Remote host closed the connection 04:22 (join) misterncw 04:24 (join) vu3rdd 04:24 (quit) vu3rdd: Changing host 04:24 (join) vu3rdd 04:26 (join) DT`` 04:28 (quit) ckrailo: Quit: Computer has gone to sleep. 04:50 (quit) DT``: Remote host closed the connection 04:59 (join) DT`` 06:22 (join) MayDaniel 06:26 (quit) misterncw: Remote host closed the connection 06:30 (join) misterncw 06:48 (quit) MayDaniel: Read error: Connection reset by peer 06:50 (part) EM03 07:02 (quit) DT``: Remote host closed the connection 07:04 (join) DT`` 07:12 (quit) tauntaun: Quit: Ex-Chat 07:17 (join) lucian 07:36 (quit) lucian: Read error: Operation timed out 07:47 (join) lucian 07:53 (nick) mario-go` -> mario-goulart 07:58 (quit) masm: Read error: Operation timed out 08:00 (join) samth_ 08:03 (join) masm 08:18 (quit) hkBst: Remote host closed the connection 08:19 (join) hkBst 08:22 (join) dnolen 08:26 (quit) hkBst: Ping timeout: 250 seconds 08:33 (join) jeapostrophe 09:06 (join) hkBst 09:21 (quit) jeapostrophe: Quit: jeapostrophe 09:35 (quit) lucian: Read error: Operation timed out 09:44 (quit) dnolen: Quit: dnolen 09:47 (join) dnolen 09:48 (quit) dnolen: Client Quit 09:51 (join) lucian 09:52 (quit) samth_: Ping timeout: 250 seconds 09:55 (join) jeapostrophe 10:06 (join) PLT_Notify 10:06 PLT_Notify: racket: master Eli Barzilay * 54fea48 (1 files in 1 dirs): Another entry for Matthew 10:06 PLT_Notify: racket: master Eli Barzilay * 42fe92c (1 files in 1 dirs): Split the glob patterns on ";", and add them all to the gtk dialog. 10:06 PLT_Notify: racket: master Eli Barzilay * 1582f16 (3 files in 2 dirs): * Make the drracket `default-filters' have a ";"-separated glob for all ... 10:06 PLT_Notify: racket: master commits ef915d0...1582f16 - http://bit.ly/l4aw0L 10:06 (part) PLT_Notify 10:10 (join) ulrik19 10:10 ulrik19: Hi every body :) 10:11 ulrik19: I've a problem with DrScheme ! Is there anyone who can help me ? 10:12 (nick) blomqvist -> abbe 10:12 (nick) abbe -> blomqvist 10:17 ulrik19: Ok ! This is my problem ! I'm writting a code of an interpreter with DrRacket and i use the language "Big Scheme" (something like that, sorry, i'm french) 10:17 ulrik19: but set-cdr! is undefined 10:18 ulrik19: and i need to use set-cdr! to modify a list in a function 10:22 (quit) jeapostrophe: Quit: jeapostrophe 10:22 DT``: ulrik19, in Racket, conses are immutable. 10:23 DT``: use mcons/mlist/set-mcar!/set-mcdr!, etc. 10:25 (quit) lucian: Read error: Connection reset by peer 10:26 stamourv: ulrik19: That "Big Scheme" thing is probably the "Pretty Big" language, which is kept around only for backwards compatibility, you shouldn't write new code in it. 10:26 (join) lucian 10:27 stamourv: You should use "Determine language from source" (or something like that) from the language menu, then put "#lang racket" (without the quotes) at the top of your file. 10:27 stamourv: That will give you access to the full power of the racket language. 10:29 (join) anRch 10:31 ulrik19: thanks for your help ! I will try all you told 10:34 stamourv: Oh, and follow DT``'s advice too. He's right about set-cdr!. 10:35 stamourv: And keep in mind that set-cdr! is rarely the solution to your problem, there's almost always a better way to do it that doesn't involve mutation. 10:39 (join) dnolen 10:42 ulrik19: stamourv : when i'm passing a list as parameter to a function. How can I modify this original list without using set-cdr! ? 10:44 stamourv: ulrik19: Well, to _modify_ it, you would need set-cdr!, but you could, instead of modifying the original, have the callee return a new list and have the caller use that new one instead of the old one. 10:44 stamourv: That achieves pretty much the same thing, but without any mutation. 10:45 (join) RpR 10:45 (nick) samth_away -> samth 10:45 stamourv: If other parts of the program also need to see the changes to the list, you can try putting the list inside a box, and replacing the contents of the box with the new list, instead of mutating the list directly. 10:47 (quit) vu3rdd: Remote host closed the connection 10:48 ulrik19: Well ! You are right ! My function already returns something ! I think I will use a box ! thanks ! 10:49 DT``: ulrik19, if you can, try to just avoid mutation. 10:49 stamourv: Yes, that's usually a good guideline. 10:50 ulrik19: Sorry, but I don't understand why mutations are so "bad" ? 10:51 samth: they make your programs hard to write, read, and understand 10:51 stamourv: Mutation makes it hard/impossible to understand your programs by understanding each part separately. 10:51 stamourv: Which makes debugging much harder. 10:52 ulrik19: ok 10:52 DT``: mutation is less modular. 11:17 (join) Fare 11:24 (join) ckrailo 11:29 (quit) hkBst: Remote host closed the connection 11:41 (join) mithos28 11:45 (quit) anRch: Quit: anRch 11:49 (quit) lucian: Read error: Operation timed out 11:50 (join) lucian 12:01 (quit) Fare: Ping timeout: 250 seconds 12:11 (join) jeapostrophe 12:11 (quit) jeapostrophe: Client Quit 12:12 (quit) realitygrill: Ping timeout: 258 seconds 12:14 (join) jonrafkind 12:24 (join) dyoo 12:25 (join) realitygrill 12:25 (quit) lucian: Read error: Operation timed out 12:28 (quit) dyoo: Ping timeout: 252 seconds 12:35 (quit) misterncw: Remote host closed the connection 12:38 (quit) dnolen: Ping timeout: 252 seconds 12:42 (join) lucian 12:45 (join) carleastlund 13:17 (quit) realitygrill: Ping timeout: 246 seconds 13:28 (join) jeapostrophe 13:30 (quit) mithos28: Quit: mithos28 13:36 (join) Fare 13:57 (join) MayDaniel 14:06 em: When is it appropriate to use mutation? In Racket I think lists are not mutable. But aren't hashe's mutable? 14:07 jonrafkind: there are immutable and mutable hashes 14:07 jonrafkind: hashes are mutable by default, iirc 14:08 em: Do you side with those who say immutable is usually to be preferred? 14:08 jonrafkind: http://docs.racket-lang.org/reference/hashtables.html?q=hash#(def._((quote._~23~25kernel)._make-immutable-hash)) 14:08 jonrafkind: i dunno, being immutable is ok sometimes but when things are easier by using mutation just do that 14:09 jonrafkind: i find its a waste of time to try to convert a mutable procedure into an immutable one 14:09 em: procedures can also be said to be mutable or immutable? I thought mutable or immutable refered to data-types 14:10 jonrafkind: i mean a procedure that works with either mutable or immutable data 14:10 em: Okay 14:12 em: It seems more in the spirit of functional programing to use immutable data. Does it not? Isn't a mutation in data really a change of state? 14:12 em: or a side effect? 14:12 jonrafkind: yes but eventually it becomes a huge pain to only deal with immutable values 14:12 jonrafkind: i mean this is my experience, you may find things are different for you 14:12 jonrafkind: i find being purely immutable adds artificial problems 14:13 jonrafkind: of course you should be *mostly* immutable, but a little mutation here and there is fine 14:13 em: Isn't it also very costly for resources since to be totally immutable means each time you do want a transformation from one data to another data you need to copy the whole thing over + changes into a new thing, and possibly destroy the original. 14:14 jonrafkind: sometimes thats true but there a ways to avoid such costs, the immutable hash tables do some trick to amortize the cost of updating it at the cost of creating the hash table 14:14 em: like for a list, to 'change' one element in the list really meams making a whole new list with the change in it. But if lists were mutable you could just change that one element. 14:14 jonrafkind: in general you can use a "zipper' to do functional updates without copying the entire data structure 14:14 em: that's over my head 14:14 jonrafkind: for structs what you say is true, the entire thing is copied, but supposedly its fast these days 14:14 jonrafkind: basically dont worry about the cost of copying unless you measure it to matter 14:16 em: sometimes i have found copying to be pretty expensive. 14:16 offby1: em: I haven't read the scrollback -- just your original question -- but I avoid mutation when it's reasonably easy to do so -- which is almost all the time. 14:17 em: For example, I wanted to parse some text. I had a lot of data from an html page and I wanted to strip out all the html tags. to do that I found the places where the tags started and ended, and then cut the strings at thoes points and glued the ends back together with appends. Each time I did that a new copy of the whole thing as made, of course. 14:17 em: for some reason regex is able to do stuff like replace without the huge cost of my brute force method. I dont get how it does that. 14:17 offby1: em: this https://github.com/offby1/doodles/blob/master/plt-scheme/web/amazon/group.rkt is the first thing I've written in I-don't-know-how-long where I cannot figure out how to eliminate the mutation. 14:17 rudybot: http://tinyurl.com/3tsvy99 14:18 offby1: em: if I were mangling html, I'd first convert it to sexprs with (planet neil/htmlprag); it has a function html->shtml 14:19 em: neil also did a thing that changes json into sjson 14:19 offby1: em: I suspect this is simply a matter of writing lots of functional code: after a while you learn what's easily doable. I suspect your problem is that you're simply unaware of many of the handy tools and techniques available that'd make your job easier 14:19 em: that neil guy seems to do a lot of stuff. 14:19 offby1: yep 14:20 jonrafkind: frustrating yourself to do things "the right way" is bad, imo 14:20 jonrafkind: just do things however you feel like, if that involves mutation so be it. eventually you will get comfortable with immutability 14:20 em: Yeah if i knew about that shtml that would be good. On the other hand, most of the things I do are for no greater purpose than to experiment and learn racket anyway. So maybe reinventing the wheel has utility in that case. 14:20 samth: offby1, what exactly is that supposed to do? 14:21 samth: oh, wait, i see now 14:21 offby1: what jonrafkind said. 14:22 offby1: I write functionally mostly because I dig it, and also because I have the vague sense that it's easier to test. 14:22 offby1: samth: I was a little surprised that there wasn't something like that built-in already. 14:23 ohwow: Hey guys, would I be right if I said that LISP is strongly dynamicly typed? 14:23 jonrafkind: i use mutation say when I loop over some values and want to store stuff in a hash table. it tends to be easier to just update the hash table then to constantly return a new updated hash table after each element is touched 14:23 samth: ohwow, i wouldn't say anything like that 14:24 ohwow: Why? 14:24 offby1: samth: just out of curiosity, what was it that made you realize what my code was supposed to do? Was it the little tests? 14:24 samth: i would say that (usually) lisp is untyped 14:24 samth: offby1, yes, the tests 14:24 offby1: (it sure 'nuff wasn't the documentation!) 14:24 samth: types = static types 14:24 ohwow: But even in Wikipedia it says that LISP is dynamically typed 14:24 ohwow: A programming language is said to be dynamically typed when the majority of its type checking is performed at run-time as opposed to at compile-time. In dynamic typing, values have types but variables do not; that is, a variable can refer to a value of any type. 14:25 samth: (a) dynamically typed is a phrase i don't like, but sometimes it's neccessary/useful 14:25 samth: (b) wikipedia isn't always right :) 14:25 ohwow: okay :[ 14:25 jonrafkind: you should probably explain yourself about a), samth .. 14:26 samth: eli, ping -- git.racket-lang.org is not working 14:26 samth: i'm getting "PTY allocation requires failed on channel 0" 14:26 DT``: samth, wasn't dynamic typing = only values have types, variables do not? Isn't it exactly what Lisp does? 14:26 samth: s/requires/request/ 14:26 samth: DT``, i don't like saying that "values have types" 14:26 samth: types are about static checking 14:27 offby1: samth: curious -- that ssh problem crops up on github too occasionally 14:27 samth: but even leaving aside whether "dynamic typing" is a good term, "strong" has no place in this discussion 14:27 DT``: I wouldn't say that, 2 is clearly a different thing from "2" or #\2. 14:27 offby1: samth: I'd argue with you about "types are about static checking", but then I realize ... you're samth :) 14:27 samth: DT``, certainly 14:28 samth: offby1, that's very true, but i'm not sure i see your point :) 14:28 offby1: samth: so ... what terminology do you prefer, to contrast a language like scheme with a language like Pascal? 14:28 samth: i would say that pascal is typed, and scheme is not 14:28 offby1: surely their type systems are different; and surely there's a simple phrase that summarizes that difference 14:28 offby1: huh 14:28 offby1: ok 14:30 samth: mostly i think that people who say things like "scheme does so have types" should just be more ok with saying that not having types is fine 14:30 em: is it cheating to use that (for/list .. ) procedure? 14:30 samth: except when it isn't -- then you need typed racket :) 14:30 em: isn't that like a python/c type of thing. 14:30 samth: em, `for/list' is great; we strongly encourage you to use it 14:31 em: okay. 14:32 em: for some reason i had this idea that in scheme we should use recursive or iterative procedures and in languages like c or python they had loop syntax like while or for etc that did that for you. 14:32 samth: using `for/list' *is* writing a recursive and/or iterative procedure 14:32 samth: it's just a really convenient way of doing it 14:33 offby1: em: yes, for/list is definitely cheating; you should never use it. 14:33 offby1 whistles innocently 14:34 offby1: also, what the hell are you doing writing in Scheme? Real programmers write in assembly 14:34 offby1: or they toggle console switches 14:35 DT``: what? Real Programmers write in C, because nothing is as fast as C. 14:35 DT``: ... not even C. 14:42 em: because c is the speed of light. 14:44 em: why are the for/ called "comprehension forms" ? 14:45 samth: for/list is like a list comprehension in python 14:46 em: i wonder why they are called comprehensions. 14:46 em: I think racket came before python. 14:46 offby1: because they're incomprehensible, duh. 14:46 offby1 whistles innocently 14:48 samth: offby1, https://gist.github.com/1005012 14:50 stamourv: em: It's related to defining sets by comprehension, in mathematics. 14:51 stamourv: Racket started around 95ish, and python started 90ish, I believe. 14:58 offby1: samth: fab! I see you work for free :-) 14:59 samth: offby1, with for/fold, all things are possible 14:59 (quit) MayDaniel: 15:03 offby1: funny, I use that a lot; I just didn't see its applicability here 15:03 samth: mattmight, i see that the PLDI schedule formatting hasn't improved :) 15:03 mattmight: Nope. 15:03 (quit) lucian: Read error: Operation timed out 15:04 mattmight: I just got a "final" schedule though. Maybe I'll fix it now. ;) 15:38 (quit) Fare: Read error: Operation timed out 15:38 em: stamourv: well scheme started way before python. did scheme have list comprehensions? 15:43 DT``: em, I'm pretty sure that Python itself took LCs from Haskell/some other language, which in turn took them from set theory (I think). 15:47 stamourv: DT``: Yes, I believe they come from Haskell. 15:48 jonrafkind: there is absolutely nothing unique to python, afaik 15:48 bremner_: attitude? 15:49 jonrafkind: indentation enforced whitespace possibly.. 15:49 DT``: bremner_, inherited from Lisp weenies. 15:49 DT``: jonrafkind, Haskell has that too. 15:50 bremner_: haskell has indentation semantics, but they are optional. 15:50 jonrafkind: oh ok, didn't know that 15:50 stamourv: jonrafkind: There's a lot of random brain damage that is unique to it. 15:50 jonrafkind: yea yea :p 15:51 stamourv: see: http://www.quora.com/What-are-the-main-weaknesses-of-Python-as-a-programming-language 15:51 rudybot: http://tinyurl.com/4hg4xhm 15:51 jonrafkind: hm i wonder if any were fixed in pythono 3 15:51 stamourv: If so, I'm sure new ones were introduced to compensate. 15:52 DT``: that would be pythonic. 15:52 bremner_: hmm. I'm skeptical that Parnas invented "information hiding" 15:52 jonrafkind: cmon, be optimistic 15:53 DT``: jonrafkind, AFAIK, python 3 has only fixed the can't-access-outer-variables issue. 15:53 jonrafkind: well thats good at least, i always hated that issue 15:55 DT``: instead of nonlocal, I'd preferred a let, though. 15:55 DT``: or var, or something else. 15:56 jonrafkind: nonlocal??? bleh.. yea let or var is much better 15:56 jonrafkind: this reminds me of 'our' and 'my' from perl 15:56 jonrafkind: 'hey we screwed up, lets invent some stupid keyword to "fix" it' 15:57 bremner_: well, at least perl scopes were fixed. 15:58 DT``: bremner_, didn't nonlocal fix everything? 15:58 bremner_: DT``: oh, no idea. But "my" was what, 10 years ago? 15:59 jonrafkind: rofl, some guy lists "No ++ and -- operators." as an issue with python 15:59 (join) MayDaniel 16:00 jonrafkind: flaming death to the person that came up with those operators! 16:00 bremner_: PDP-11 assembly 16:00 DT``: not having ++ and -- is one of the few things pyhton got right. 16:01 stamourv: There's worse, PIC18 has registers that auto-increment/decrement if you read them. 16:11 (join) tauntaun 16:11 (join) PLT_Notify 16:11 PLT_Notify: racket: master Carl Eastlund * c8600f0 (1 files in 1 dirs): Added examples to documentation for for/fold/derived, for*/fold/derived, ... - http://bit.ly/iTLd2m 16:11 (part) PLT_Notify 16:28 (quit) ulrik19: Ping timeout: 252 seconds 16:37 (quit) jao: Ping timeout: 250 seconds 16:40 em: is there any such thing as a 'racket object'? 16:41 DT``: everything? (what do you mean?) 16:42 em: i was reading something called 'cPickle' for python which takes python objects and 'serialises' them into a byte stream. 16:43 em: I wondered if Racket had anything like that, but I guess that would only make sense if Racket had Racket Objects that could be serialised. 16:43 samth: em, i'd just refer to racket values 16:43 samth: and take a look at the `serialize' procedure 16:43 em: okay cool 16:44 DT``: em, you can just write/read most Racket objects (conses, hashes, vectors, etc) 16:44 DT``: for the rest, look at serialize like samth said. 16:52 em: this is kind of an odd question but if you are starting out is there any 'shame' in using modules from planet? 16:53 bremner_: there is never any shame in re-using software. Presumably the quality of modules on planet varies a bit more than core modules, although I don't really know that. 16:54 em: is there any substantial difference between 'library' and 'module'? 16:55 (join) PLT_Notify 16:55 PLT_Notify: racket: master Vincent St-Amour * 6de5f48 (1 files in 1 dirs): Optimize sqr on floats. 16:55 PLT_Notify: racket: master Vincent St-Amour * bb71f9b (1 files in 1 dirs): Fix contract generation for Exact-Rational. ... 16:55 PLT_Notify: racket: master commits c8600f0...bb71f9b - http://bit.ly/it9HYT 16:55 (part) PLT_Notify 16:58 offby1: em: in racket-land, "module" is a technical term, whereas I think "library" is vaguer 16:58 offby1: libraries are _typically_ modules, but they might also be units. 16:58 offby1: I think. 17:05 em: To me, both modules and libraries mean nothing more than "a file that you can call upon to load a bunch of related procedures and use in your own program" 17:11 (join) mheld_ 17:14 (quit) mheld_: Client Quit 17:15 offby1: *shrug* 17:16 offby1: modules get loaded via "require" 17:16 offby1: libraries, in theory, might use some other mechanism 17:16 offby1: I wouldn't stress over it 17:16 (join) jao 17:36 (nick) samth -> samth_away 17:38 (quit) MayDaniel: Read error: Connection reset by peer 17:54 (join) lucian 17:55 (quit) YokYok: Ping timeout: 248 seconds 18:02 (join) YokYok 18:15 (join) anRch 18:24 (quit) lucian: Read error: Operation timed out 18:36 (quit) jeapostrophe: Quit: jeapostrophe 18:39 (join) lucian 18:41 (join) PLT_Notify 18:41 PLT_Notify: racket: master Vincent St-Amour * 801354f (3 files in 3 dirs): Add syntax-within? to unstable/syntax. 18:41 PLT_Notify: racket: master Vincent St-Amour * 1ad63e5 (1 files in 1 dirs): Unify doc formatting. 18:41 PLT_Notify: racket: master commits bb71f9b...1ad63e5 - http://bit.ly/ltdatV 18:41 (part) PLT_Notify 18:45 em: offby1: when do you personally use contracts? 18:54 offby1: em: most of the time 18:55 offby1: it just makes development a tad easier 18:55 offby1: since they give me slightly-clearer error messages when I invoke a function with the wrong type of argument. 18:55 offby1: some day I'll start using typed racket seriously: that will give me those sorts of errors even if the code in question doesn't actually get called! 18:59 (quit) anRch: Quit: anRch 19:01 (quit) martinhex: Read error: Connection reset by peer 19:08 (join) dherman 19:10 (join) jeapostrophe 19:22 (quit) carleastlund: Quit: carleastlund 19:26 (join) PLT_Notify 19:26 PLT_Notify: racket: master Matthew Flatt * defae9b (1 files in 1 dirs): adjust `struct' expansion for the top level ... 19:26 PLT_Notify: racket: master Matthew Flatt * b24c387 (18 files in 6 dirs): add PLTDISABLEGC environment variable 19:26 PLT_Notify: racket: master commits 1ad63e5...b24c387 - http://bit.ly/lZvExX 19:26 (part) PLT_Notify 19:28 (join) PLT_Notify 19:28 PLT_Notify: racket: master Robby Findler * 9e36dc8 (2 files in 2 dirs): adding a missing 2htdp/image color => racket/gui color coercion ... - http://bit.ly/lJzwsi 19:28 (part) PLT_Notify 19:28 (join) martinhex 19:35 (quit) jeapostrophe: Quit: jeapostrophe 19:46 (join) PLT_Notify 19:46 PLT_Notify: racket: master Matthew Flatt * d74aa0c (1 files in 1 dirs): try to fix CAS for Mac OS X PPC - http://bit.ly/lUPsUg 19:46 (part) PLT_Notify 20:12 (join) jeapostrophe 20:17 (quit) ckrailo: Quit: Computer has gone to sleep. 20:26 em: hm this form called "generator" seems kind of cool if I am understanding it. 20:27 jonrafkind: it too is in python 20:38 (quit) jonrafkind: Ping timeout: 240 seconds 20:49 (quit) dherman: Quit: dherman 20:50 (join) ckrailo 20:57 (quit) jao: Ping timeout: 250 seconds 21:03 (quit) masm: Ping timeout: 240 seconds 21:10 (join) dherman 21:24 (join) samth_ 21:57 (quit) jeapostrophe: Quit: jeapostrophe 21:59 (quit) dherman: Quit: dherman 22:25 (join) jeapostrophe 22:26 (quit) jeapostrophe: Client Quit 22:36 (join) jeapostrophe 22:37 (quit) jeapostrophe: Client Quit 22:50 (quit) lucian: Read error: Operation timed out 23:03 (quit) dsp_: Read error: Operation timed out 23:04 (join) dsp_ 23:12 (join) jeapostrophe 23:12 (join) dnolen 23:12 (quit) jeapostrophe: Client Quit 23:24 (join) jeapostrophe 23:31 (quit) RpR: Remote host closed the connection 23:36 (quit) eli: Ping timeout: 252 seconds 23:37 (join) eli 23:40 (quit) tauntaun: Quit: Ex-Chat 23:43 (quit) dsp_: Ping timeout: 260 seconds 23:43 (quit) jeapostrophe: Quit: jeapostrophe 23:46 (join) jeapostrophe 23:48 (join) dsp_ 23:49 (quit) jeapostrophe: Client Quit 23:50 (join) jeapostrophe 23:53 (quit) jeapostrophe: Client Quit 23:55 (join) jeapostrophe