00:01:04 -!- Nisstyre [~nisstyre@infocalypse-net.info] has quit [Remote host closed the connection] 00:02:29 Nisstyre [~nisstyre@infocalypse-net.info] has joined #scheme 00:07:22 TR2N [email@2001:470:1f14:135b::2] has joined #scheme 00:08:53 -!- schmir [~schmir@p54A91554.dip0.t-ipconnect.de] has quit [Remote host closed the connection] 00:09:13 -!- StephenFalken [email@2001:470:1f14:135b::2] has quit [Ping timeout: 240 seconds] 00:11:20 lewis1711 [~lewis@125-239-255-244.jetstream.xtra.co.nz] has joined #scheme 00:12:28 jeapostrophe_ [~jay@69.169.141.110.provo.static.broadweavenetworks.net] has joined #scheme 00:12:53 -!- jeapostrophe_ [~jay@69.169.141.110.provo.static.broadweavenetworks.net] has quit [Client Quit] 00:13:53 just a question... do continuations causes "jumps"? I mean, the flow of the process going from some place to another? 00:17:52 offby1 [~user@pdpc/supporter/monthlybyte/offby1] has joined #scheme 00:18:23 how could it be any different? 00:18:32 what rien meant to say was 'yes' 00:18:40 I don't mean to be rude, sorry :) 00:18:54 it was an honest question because I don't know what he really means by"process" 00:21:37 -!- leppie [~lolcow@196-210-162-106.dynamic.isadsl.co.za] has quit [Read error: Connection reset by peer] 00:21:39 then that's why j-invariant was telling me that my define example was an exception 00:21:57 leppie [~lolcow@196-210-162-106.dynamic.isadsl.co.za] has joined #scheme 00:22:29 scottj [~scott@206.212.250.58] has joined #scheme 00:22:59 if I do something like ... (let ([foo (+ 1 2]) ... will foo get calculate every time i call the function, or will it be cached the first time? 00:23:48 every time you call which function? 00:24:02 foo? 00:24:16 right, need better pseudo code 00:24:20 hehe 00:24:31 (define (rofl lol) (let ([foo (+ 1 2])... 00:24:31 but if the let is over the function then you're right 00:24:37 every time i call rofl 00:24:40 in that case no 00:24:49 you'd have to have it backwards for it to "cache" 00:24:55 I see 00:25:07 because then you're literally building a closure 00:25:28 which means you have a function who is the sole proprietor of a pointer to a global variable 00:26:17 so I'd have to have a function nested inside the let statement 00:26:22 -!- tessier [~treed@mail.copilotco.com] has quit [Ping timeout: 250 seconds] 00:26:25 yes 00:26:41 got it 00:30:14 http://paste.lisp.org/display/118511 if anyone likes tearing apart noob scheme code, then look at this:) (object system is semi functional, next step is being able to access private and public properties when defining properties) 00:30:50 -!- githogori [~githogori@33.sub-75-210-61.myvzw.com] has quit [Remote host closed the connection] 00:36:27 if that's noob then my code is kindergarten: http://paste.lisp.org/display/118512 00:37:17 is what you're doing possible with just r5rs and if so, why are you using non-r5rs features (tables) ? 00:38:08 rien: r5rs has no hashtables as far as I am aware. Unless I implemented my own, which seems a tad silly when gambit has em 00:39:23 well I don't know anything about gambit but scheme has hashes (associative arrays) that are pretty easy to use 00:39:36 sorry, that didn't make any sense 00:39:46 s/but scheme/but chicken scheme has an egg that/ 00:39:56 lewis1711: SRFI 69 has hashtables. 00:40:11 lewis1711: R5RS is minimal; SRFIs flesh it out. :-D 00:40:13 right, again, not an egg :) 00:40:29 lewis1711: you should use srfi 69 so that I can play with your code :)) 00:40:45 hmm, I'll see if gambit implements it 00:40:52 it would be make-hash insteand of make-table and probably the other differences should be minimal as well 00:41:49 hmm, gambit doesn't have it. does chicken? 00:41:54 I have chicken installed somewhere 00:42:26 yes chicken does 00:42:37 your code is very readable to me (and I'm a dummy) 00:42:53 thanks 00:42:59 may I suggest (apply response args) instead of (eval (cons response args)) 00:43:16 ...is that the same thing? 00:43:26 yes but without the overhead of running eval 00:43:46 rudybot: (apply + '(1 2 3)) 00:43:46 rien: your sandbox is ready 00:43:47 rien: ; Value: 6 00:44:15 doesn't work here 00:44:18 Unless you're writing a REPL, eval is almost always the wrong thing to use. 00:44:18 *** ERROR IN (console)@7.1 -- (Argument 1) PROCEDURE expected 00:44:18 (apply '(lambda (n) (+ (random-integer n) 1)) '(4)) 00:44:32 lewis1711: You can't use a quoted lambda. 00:44:35 -!- kilimanjaro [~kilimanja@unaffiliated/kilimanjaro] has quit [Ping timeout: 272 seconds] 00:44:37 lewis1711: Use a real one, instead. 00:44:37 the first argument to apply can't be a symbol 00:44:45 Nor a list. 00:44:46 and the last must 00:44:48 @ rien 00:44:55 right 00:45:03 cky: yeah, uh, how else do I unquote something apart from eval?:P 00:45:10 -!- Genosh [~Genosh@223.Red-83-32-116.dynamicIP.rima-tde.net] has quit [Quit: http://quasiquote.me] 00:45:11 lewis1711: Why is it quoted in the first place? 00:45:15 right :) 00:45:43 cky: otherwise it'd get eval'd 00:45:51 lewis1711: That makes no sense. 00:46:32 one way to "wrap" something so that it doesn't get evaled is to put it inside a lambda 00:46:41 That,. 00:46:43 I dunno tbh 00:46:48 I don't get why the hp code works 00:46:51 when it's a quote 00:46:59 lewis1711: Yes, that's the usual answer people give about why they use eval. :-P 00:47:01 the code is programming me, man 00:47:25 what is so evil about eval? 00:47:31 huge overhead 00:47:35 -!- rgrau [~user@62.Red-88-2-20.staticIP.rima-tde.net] has quit [Remote host closed the connection] 00:47:40 but most importantly, no need for it 00:47:44 Extreme breakage of a number of abstractions. :-P 00:48:11 cky: I am pretty sure I'll break my code doing what you say. but just for you 00:48:33 I don't think doing the change I proposed should break it 00:49:15 if it does, then it's because you're storing the lambdas as symbols, and instead you should wrap them in lambdas (yes, again) 00:50:01 lewis1711: If you post your code, I can probably try to refactor it a bit. But, your choice. 00:50:01 if we pretend there's no eval, then once you '(something), that something is gone forever as code (someone correct me if I'm wrong) 00:50:10 http://paste.lisp.org/display/118511 00:50:10 rien: Pretty much. 00:50:16 rien: Unless you implement your own interpreter, ec. 00:50:19 okay then I understand 00:50:21 right 00:50:23 oh, rien posted it for me 00:50:27 his code is at the link above 00:50:28 it's up there cky :) 00:50:33 (I am trying it myself) 00:51:09 man i am sick of the operator is not a PROCEDURE error 00:51:17 scheme doesn't even have operators 00:51:52 Operators are overrated. 00:51:59 Anyway. 00:52:45 Genosh [~Genosh@113.Red-95-121-141.dynamicIP.rima-tde.net] has joined #scheme 00:59:48 lewis1711: http://paste.lisp.org/+2JF4/1 :-) 01:00:44 Heh, I edited the wrong paste. 01:01:04 -!- Nisstyre [~nisstyre@infocalypse-net.info] has quit [Remote host closed the connection] 01:01:07 (I edited 118480 rather than 118511.) 01:01:10 yeah, that looks like an old paste I made :D 01:01:10 But, you get the idea anyway. 01:01:25 Hey, I'd have made your new one pretty much identical to what I had, anyway. 01:01:43 I can't find the changes 01:01:43 -!- qhe [~qhe2@134.134.139.72] has quit [Ping timeout: 255 seconds] 01:01:44 :/ 01:02:02 lewis1711: Go to the bottom of the page.... 01:02:17 it's very similar but it got rid of the eva 01:02:18 l 01:02:34 bottom of the page/ there's only one paste for me in that link 01:02:48 rien: Indeed. 01:02:56 rien: I used quasiquotation to allow the lambda to be unquoted. 01:03:05 ok, we are reading different pastes 01:03:11 lewis1711: Yes, read 118480. 01:03:13 Annotation 1. 01:03:21 I am 01:03:26 there are no quasiquotations 01:03:32 lewis1711: http://paste.lisp.org/display/118480#1 01:03:38 rudybot: `(1 2 3) 01:03:39 cky: your racket sandbox is ready 01:03:39 cky: ; Value: (1 2 3) 01:03:44 rudybot: `(1 2 ,(+ 1 2)) 01:03:44 cky: ; Value: (1 2 3) 01:03:53 -!- j-invariant [~aaaa@unaffiliated/j-invariant] has quit [Quit: leaving] 01:03:54 rien thanks 01:03:56 lewis1711: ^^--- that's quasiquotation. 01:04:00 yeah 01:04:07 cky: what you linked me was not the annotated one 01:04:10 quasi = almost in Latin :) 01:04:10 some bug in lisppaste 01:04:16 Fail. :-( 01:06:12 -!- bweaver [~user@host-68-169-158-230.WISOLT2.epbfi.com] has quit [Quit: ERC Version 5.3 (IRC client for Emacs)] 01:06:17 cky: is the only change the quasi quoted argument? 01:06:21 I tried that and got errors 01:06:33 no 01:06:40 he got rid of your eval 01:06:58 he changed only the eval and added the quasiquotation 01:07:19 yeah, I did that too 01:07:21 now i get 01:07:30 I also made the formatting more orthodox. :-P 01:07:37 > (monster 'hp) 01:07:37 *** ERROR IN (console)@19.1 -- Operator is not a PROCEDURE 01:07:37 ((object ((public hp 30) (public name "steve") (public roll-dice #))) 'hp) 01:07:44 -!- parcs [~patrick@ool-45741d7d.dyn.optonline.net] has quit [Quit: WeeChat 0.3.3] 01:08:09 parcs [~patrick@ool-45741d7d.dyn.optonline.net] has joined #scheme 01:08:26 I guess it can't be tasted unless you ahve gambit, so my bad 01:08:32 but I think I get the gist of what you're trying to do 01:09:05 I think he tested in gambit, no? cky? 01:09:32 rien: I haven't done any testing. 01:09:46 rien: I usually can picture the code's execution without having to test it out. :-P 01:09:47 oh 01:09:53 apparently not :PP 01:09:58 rien: Heh. 01:10:00 hehehe 01:10:23 ah hang on, here's a change i missed 01:10:27 "(procedure? value)" 01:10:44 -!- masm [~masm@bl19-144-49.dsl.telepac.pt] has quit [Ping timeout: 260 seconds] 01:10:55 lewis1711: Uh huh. 01:11:21 I actually had that in my code originally then made that lambda symbol hack when it didn't work:D 01:12:08 hmm, nope still weird bugs 01:12:28 damn it, why did you have to tell me eval was evil, I could've lived in ignorance!;) 01:12:39 Heh. 01:12:41 rpg [~rpg@216.243.156.16.real-time.com] has joined #scheme 01:12:48 I'm trying to get it to work in chicken 01:12:53 maybe I'll convert you :) 01:12:58 If you worked with me, you'd get slaughtered in a code review. :-P 01:13:07 but I'm getting silly errors, like "make-hash-table" unknown keyword 01:13:09 (For using eval when unnecessary, that is.) 01:13:54 people use scheme at work!? 01:14:07 No, actually we use Ruby and Java. 01:14:17 I'd love to run a place that codes Scheme for work, though. :-P 01:14:24 but how are they supposed to encapsulate their enterprise level public type cast interfaces? 01:14:25 ahh 01:14:38 well ruby does have an eval 01:14:51 Yes, and I still frown on needless use of eval in Ruby. :-D 01:14:56 mind you I imagine the overhead for that is not any worse than regular ruby code 01:15:00 Though, granted, Ruby needs it rather more than Scheme. 01:15:00 since it's all interpreted anyway 01:15:10 qhe [~qhe2@134.134.139.70] has joined #scheme 01:15:13 kanru [~kanru@61-30-10-70.static.tfn.net.tw] has joined #scheme 01:15:17 zevarito [~zevarito@r186-48-111-120.dialup.adsl.anteldata.net.uy] has joined #scheme 01:15:21 hey lewis, what does "make-table init "error message" mean? are you initializing the table with a key "init" and a value" error msg" ? 01:15:29 lewis1711: We actually use JRuby, which compiles to Java bytecode. 01:15:37 rien: chicken let me define things with the same symbol. otherwise it looked good 01:15:49 rien: that's the message you get if you try and use a key that doesn't exist 01:16:06 not really neccessary, just experiment with objects that don't crash when you send the wrong message 01:16:09 right, so init and "error message" is akey bvalue pair that you're storing in the table? 01:16:20 no, not quite 01:16:38 it's more like try and do this, if you can't, print the init thing 01:16:40 or return it, rather 01:17:02 but "init" doesn't get referred to in the rest of the code 01:17:03 so if I go (table-ref table 'key-that's-not-there) 01:17:09 no I get the purpose 01:17:09 it'd return the init message 01:17:12 just not wht it means 01:17:14 no, init is not a key 01:17:19 what is it? 01:17:24 a constructor option 01:17:26 hang on 01:17:32 what does it mean to make-table init: "error" ? 01:17:41 and also, what's tc-list 01:17:59 Nisstyre [~nisstyre@infocalypse-net.info] has joined #scheme 01:18:01 rien: I presume init: is a keyword. Different implementations use different notations for keywords. 01:18:03 http://www.iro.umontreal.ca/~gambit/doc/gambit-c.html#Tables 01:18:10 rien: scroll down to make tables 01:18:21 cky: how does scheme make symbols? 01:18:26 rien: tc-list is typecheck list, just some function i made that checks if it's a list 01:18:37 not really needed either 01:18:37 rien: Bare words in S-expressions are symbols. 01:18:40 oh!!! 01:18:55 I get it lewis, init: is a named parameter youre passing to make-table 01:18:57 tessier_ [~treed@mail.copilotco.com] has joined #scheme 01:19:05 yeah, maybe:D 01:19:09 rien: Yes, that's why I said init: is a keyword. 01:19:20 is there know other way to unquote something, other than evaluating it?:/ 01:19:26 *no 01:19:29 lewis1711: Use quasiquote. 01:19:30 cky: I didn't know named parameter == keyword in Scheme 01:19:51 rien: Keywords are not part of R5RS (not sure if R6RS has them), but many implementations provide them. 01:20:02 ic 01:20:12 cky, I am 01:20:13 -!- samth is now known as samth_away 01:20:16 > (monster 'hp) 01:20:16 *** ERROR IN (console)@25.1 -- Operator is not a PROCEDURE 01:20:16 ((object ((public hp 30) (public name "steve") (public roll-dice #))) 'hp) 01:20:26 rudybot: (string->keyword "foo") 01:20:26 cky: ; Value: #:foo 01:20:43 rien: #:foo is the notation used by Racket for keywords. 01:20:48 that's weird 01:20:51 rien: whereas foo: is the notation used by Gambit. 01:21:00 now that I read it 01:21:24 monster isn't evaluated, it's a list that hasn't been eval'd 01:21:24 wtf 01:21:45 cky: what's the notation used for chicken? you said bare words 01:22:10 rien: Symbols and keywords are different beasts. 01:22:12 OH! I started the quasi quote in the wrong place 01:22:12 herp 01:22:19 lewis1711: Hahahaha. 01:22:24 incubot: eval (string->keyword "foo") 01:22:25 foo 01:22:30 O_o 01:22:45 cky: see I keep confusing those. 01:22:46 incubot: eval (equal? (string->keyword "foo") (string->symbol "foo")) 01:22:47 #f 01:22:49 cky: ahh, working now 01:22:54 lewis1711: Much better. 01:23:08 rien: See, my code does work without having to be tested, if it's trivial. :-P 01:23:15 lol 01:23:20 heh 01:23:26 I probably should've just copy pasted 01:23:28 I'm ocnverting it to use srfi-69 01:23:50 hmm, quasi quotes as arguments are sort of ugly. oh well 01:24:21 rien: Keywords are used only for keyword arguments, and not all Scheme implementations provide those. :-P 01:24:37 rien: Symbols are, shall we say, bread and butter in Scheme (and Lisp) programming. 01:25:02 xwl_ [~wixu@nat/nokia/x-uettqajsiqsyowzz] has joined #scheme 01:25:06 rien: Here's what I mean by "symbols are barewords". 01:25:10 I still don't get how they're different from strings tbh 01:25:25 rudybot: (symbol? (car '(foo))) 01:25:25 cky: ; Value: #t 01:25:28 in ruby it makes sense, since a string is a specific object with methods 01:25:31 lewis1711, cky: this works in chicken and uses srfi-69: http://paste.lisp.org/display/118480#2 01:25:34 -!- homie [~levgue@xdsl-78-35-180-2.netcologne.de] has quit [Ping timeout: 255 seconds] 01:25:58 -!- wbooze [~levgue@xdsl-78-35-180-2.netcologne.de] has quit [Ping timeout: 276 seconds] 01:26:01 nice 01:26:07 lewis1711: Symbols have a very special property compared to strings: they are interned. (Some implementations provide uninterned symbols, but we won't talk about those.) 01:26:08 hash-table does look very similar to gambits table 01:26:10 cky: isn't a symbol any form that is quoted? 01:26:18 lewis1711: yep 01:26:32 -!- zevarito [~zevarito@r186-48-111-120.dialup.adsl.anteldata.net.uy] has quit [Remote host closed the connection] 01:26:43 rien: why the for-each over map? 01:26:48 since that for-each looks very mappy 01:27:12 lewis1711: Use for-each if your lambda returns no useful value. 01:27:14 lewis1711: I didn't touch that :) 01:27:25 I always use map 01:27:25 lewis1711: Use map if you will use the lambda's values. 01:27:30 rien: You shouldn't. 01:27:30 right 01:27:38 iterator vs list constructor 01:27:48 lewis1711: map has to keep each return value. for-each just throws them away. 01:27:54 no such difference in Haskell, I'll rid myself of those habits eventully 01:28:05 oh 01:28:07 cky: yeah, I get you now. 01:28:15 similar things in most languages that have map 01:28:17 -!- jonrafkind [~jon@crystalis.cs.utah.edu] has quit [Ping timeout: 272 seconds] 01:28:19 *nods* 01:28:37 I wonder though 01:28:46 why one can't make table literals, or hashtable literals 01:28:46 oh the reason we don't have for-each in haskell it's because there's no mutability there 01:28:54 instead you have to set! them, which is pretty ugly 01:29:13 rien: yeah, it'd only makes sense in functions with side effects wouldn't it? 01:29:19 lewis1711: In Common Lisp, I think there are reader macros to allow hashtable literals. But don't quote me on that. 01:29:28 lewis1711: yeah that's what I just realized :) 01:29:44 lewis1711: what's a "literal"? 01:29:48 '(In Common Lisp, I think there are reader macros to allow hashtable literals. But don't quote me on that.) 01:29:51 *lewis1711* chortles 01:29:52 how would that make hash-table different? 01:30:13 rien: you wouldn't have to mutate anything 01:30:36 have you used Lua? table = {a : 3, b: 2} 01:30:37 hmm not sure I get it still. 01:30:43 yes I've used Lua 01:30:56 that is a literal? 01:30:59 instead of... table = {}... then setting each member 01:31:02 yeah 01:31:06 oh... 01:31:18 cky is right though, i could make a macro to do it 01:31:23 just do alist->hash-table 01:31:28 -!- Nisstyre [~nisstyre@infocalypse-net.info] has quit [Quit: Leaving] 01:31:30 rien: A "literal" is essentially anything quoted. A "symbol" is a quoted identifier. So, for instance, (quote x) is a symbol literal. (quote 2) is a number literal. (quote (1 2 3)) is a list literal. 01:31:30 hmmm 01:31:35 *lewis1711* checks gambit manual 01:32:10 lewis1711: http://srfi.schemers.org/srfi-69/srfi-69.html#lst 01:32:48 carleastlund: hmm ok. 01:33:11 but I think what lewis1711 means is he'd like to initialize the hash while declaring it? 01:33:22 Some things are literals without using (quote ...) explicitly; strings and numbers, for instance, don't need to be quoted in their own. 01:33:31 oh I get it 01:33:43 like they have special syntax for them 01:34:15 For instance, in Racket, (quote #hash((1 . one) (2 . two))) is a hash literal that maps 1 and 2 to the symbols 'one and 'two. But this is not standard Scheme. 01:34:26 ohh there is a list->table funciton. nice, can make a functional object:) 01:36:46 :-) 01:37:09 -!- copumpkin [~pumpkin@unaffiliated/pumpkingod] has quit [Quit: Computer has gone to sleep.] 01:37:38 rien: you know a bit of ocaml, right? I can sort of read some haskell because it looks similar, I should try and learn it at some point 01:37:40 rudybot: (alist->hash-table '((1 . 2) (3 . 4))) 01:37:40 rien: error: reference to undefined identifier: alist->hash-table 01:37:44 incubot: (alist->hash-table '((1 . 2) (3 . 4))) 01:37:45 # 01:38:15 lewis1711: I can read ocaml because I know haskell, but I want to know ocaml. I don't really care for "purely functional" 01:38:30 ah 01:38:32 carleastlund: gotcha 01:38:41 carleastlund: that can probably be made in any scheme with macros, right? 01:38:50 carleastlund: that nice #hash thing 01:39:03 rien: Macros do not affect anything inside "quote". 01:39:03 rien: http://caml.inria.fr/pub/docs/oreilly-book/html/index.html this is by far the best ocaml resource I've found (though not as popular as others) 01:39:05 lewis1711: so I'd like to move my haskell knowledge to ocaml and stay there :) 01:39:40 lewis1711: thanks a lot, I'll use that 01:39:41 I'd use ocaml more if I could be bothered with it's C-interface. it's so much nicer to interface with C in gambit though 01:39:50 On the other hand, reader macros (which are very different from regular macros) can make new literals. 01:40:25 -!- pdelgallego [~pdelgalle@1385159852.dhcp.dbnet.dk] has quit [Ping timeout: 246 seconds] 01:40:32 carleastlund: what I meant was, one can probably whip up a #hash macro as syntactic sugar to a alist->hash-table call 01:40:47 carleastlund: reader macros then, yeah 01:40:54 rien: Only if your Scheme implementation has reader macro support. 01:41:07 reader macros aren't r5rs? 01:41:21 No. 01:41:27 homie [~levgue@xdsl-78-35-144-175.netcologne.de] has joined #scheme 01:41:37 sbrtgr [~user@174-30-215-125.mpls.qwest.net] has joined #scheme 01:41:43 -!- dRbiG [p@irc.kaer.tk] has quit [Read error: Connection reset by peer] 01:41:44 lewis1711: good to know, I'm using chicken because of the community and because I could get opengl up and running in no time 01:42:00 Nisstyre [~nisstyre@infocalypse-net.info] has joined #scheme 01:42:01 -!- Nisstyre [~nisstyre@infocalypse-net.info] has quit [Excess Flood] 01:42:04 cky: wow, I never would have thought that. do chicken and gambit both offer reader macros? 01:42:17 Nisstyre [~nisstyre@infocalypse-net.info] has joined #scheme 01:42:20 -!- Nisstyre [~nisstyre@infocalypse-net.info] has quit [Excess Flood] 01:42:24 -!- gravicappa [~gravicapp@ppp85-140-65-205.pppoe.mtu-net.ru] has quit [Ping timeout: 240 seconds] 01:44:19 Nisstyre [~nisstyre@infocalypse-net.info] has joined #scheme 01:45:23 chicken has them 01:45:44 wbooze [~levgue@xdsl-78-35-144-175.netcologne.de] has joined #scheme 01:45:55 I think gambit has them. Undocumented though. 01:46:03 hmm 01:46:20 it'll be a long way until I really need macros anyway 01:46:25 jeapostrophe_ [~jay@69.169.141.110.provo.static.broadweavenetworks.net] has joined #scheme 01:48:03 dRbiG [p@irc.kaer.tk] has joined #scheme 01:49:30 erjiang [~eric@7.80.244.66.jest.smithvilledigital.net] has joined #scheme 01:58:03 Axioplase_: just like namespaces:D (all it says in the manual is TO DO) 01:58:09 Erm, I think reader macros are quite different from macros in general. (As created by define-syntax) 01:59:49 yes, they are 02:02:48 -!- leppie [~lolcow@196-210-162-106.dynamic.isadsl.co.za] has quit [Read error: Connection reset by peer] 02:03:04 leppie [~lolcow@196-210-162-106.dynamic.isadsl.co.za] has joined #scheme 02:03:45 copumpkin [~pumpkin@209-6-232-56.c3-0.sbo-ubr1.sbo.ma.cable.rcn.com] has joined #scheme 02:03:45 -!- copumpkin [~pumpkin@209-6-232-56.c3-0.sbo-ubr1.sbo.ma.cable.rcn.com] has quit [Changing host] 02:03:45 copumpkin [~pumpkin@unaffiliated/pumpkingod] has joined #scheme 02:06:23 bitweiler [~bitweiler@adsl-99-40-239-167.dsl.stl2mo.sbcglobal.net] has joined #scheme 02:07:22 -!- leppie [~lolcow@196-210-162-106.dynamic.isadsl.co.za] has quit [Ping timeout: 255 seconds] 02:08:01 leppie [~lolcow@196-210-162-106.dynamic.isadsl.co.za] has joined #scheme 02:09:48 -!- Genosh [~Genosh@113.Red-95-121-141.dynamicIP.rima-tde.net] has quit [Quit: http://quasiquote.me] 02:25:55 -!- bitweiler [~bitweiler@adsl-99-40-239-167.dsl.stl2mo.sbcglobal.net] has quit [Ping timeout: 272 seconds] 02:31:56 jcowan [~John@cpe-74-68-112-189.nyc.res.rr.com] has joined #scheme 02:32:02 bitweiler [~bitweiler@adsl-99-40-239-167.dsl.stl2mo.sbcglobal.net] has joined #scheme 02:32:45 -!- scottj [~scott@206.212.250.58] has quit [Quit: go oregon!] 02:38:24 -!- gnomon [~gnomon@CPE0022158a8221-CM000f9f776f96.cpe.net.cable.rogers.com] has quit [Ping timeout: 240 seconds] 02:38:43 gnomon [~gnomon@CPE0022158a8221-CM000f9f776f96.cpe.net.cable.rogers.com] has joined #scheme 02:39:35 ugh, r5rs has no partition function:( 02:40:29 oh well, remp and filter it is 02:40:38 The traditional answer is "Write your own, it's trivial." In a context where writing compilers is something people do for fun, *everything* is trivial; that's why it's traditional to use no comments. 02:40:52 Scheme programmers are supposed to find code easier to read than comments. 02:41:13 wtf, there is no remp or filter in r5 02:41:35 jcowan: where is this info from? no comments is bad style no matter what language 02:42:26 All I can do is point to the way Schemers behave. I agree with you myself, but as Shaw said to the person who booed his play, what are we two against so many? 02:42:45 lewis1711: if I know that properly written scheme code is self-documenting 02:43:12 self-documentation is a myth perpetuated by people who don't understand the point of documentation in the first plac 02:43:13 *place 02:44:18 I am no programmer just a hobbyist but most scheme code I've read I can tell what is does just by reading the code. 02:44:41 *wbooze* selfcoduments himself 02:44:42 can you tell why it does? 02:44:45 Sure. But why is it there? That's what comments do for you, they let you 02:44:53 that ^ 02:45:01 use a procedure or module *without* needing to know how it works. 02:45:22 oh, that makes sense 02:46:13 unless you do stuff like (define (i-am-doing-this-because-i-tried-using-foo-but-i-recieved-errors-at-some-stage-i-should-refactor... 02:46:14 :D 02:46:15 I'm writinig a small library right now, and the comments are attached to each procedure saying what it does and when/why to use it. There aren't any comments on how the code works. 02:47:01 lewis1711: SRFI 1 has partition. 02:47:03 jcowan: comments in that sense are logical 02:47:14 lewis1711: Get used to searching for SRFIs. That's the Scheme way. 02:47:21 heh 02:47:54 cky: I don't get srfis. they're requests, right? so even if you find one that does what you want, you have to count on your implementation having implemented it 02:47:56 lewis1711: Scheme is not PHP. Things are in libraries, not all built-in into one gigantic heap. 02:48:03 otherwise you have to write it yourself 02:48:18 cky: I've never used PHP in my life, so try and associative me with another language you look down on:P 02:48:22 lewis1711: You generally aim to use an implementation that supports a broad selection of SRFIs. 02:48:22 *associate 02:48:33 SRFIs, like RFCs, start out as requests, but most SRFIs have reference implementations, making it easy for most Schemes to provide them. 02:49:26 http://tinyurl.com/scheme-s5 lists, for a large selection of SRFIs, which Schemes implement them. 02:49:35 s5 stands for Spreadsheet of Scheme Systems Supporting SRFIs 02:50:08 gambit doesn't have it. will have to do it myself 02:50:32 Check for yourself, I don't keep that up to date 02:50:53 jcowan: I did 02:52:24 You can just snarf the srfi-1 code yourself and compile it; it's very portable. 02:53:31 oh hmm 02:53:32 http://srfi.schemers.org/srfi-1/srfi-1-reference.scm 02:53:36 perhaps I can! 02:57:46 lewis1711: gambit is slib-compatible. 02:58:01 Install slib, and there you go. 02:58:14 Actually, I should use it too :) 02:58:31 slib eh 03:00:34 i just install it myself: http://people.csail.mit.edu/jaffer/SLIB 03:00:46 different from srfi, but slightly *more* pronouncable:) 03:00:52 even though it includes a single srfi 03:03:17 lewis1711: SRFI is pronounced "surfie". 03:03:30 lewis1711: Just like cdr is pronounced "cooder". 03:04:00 (These are the standard pronunciations used in the community; I did not just make them up. :-P) 03:04:36 cky: oh, really? i always thought cdr had a schwa: . 03:06:01 klutometis: Right, yes, I'm a New Zealander, so pronouncing cooder would imply the last syllable is a schwa. 03:06:20 (New Zealand does not do rolling Rs, unless you're from Southland or something.) 03:06:56 oh, ok; it's just that "cooder" is only one voiced dental away from . 03:06:57 klutometis: If you're trying to say that the _first_ syllable is a schwa, then that's news to me. 03:07:08 Hahahahahaha. 03:07:09 cky: yes, yes; that was my hypothesis. 03:07:42 i would have said, "cudder." 03:07:44 But, like, New Zealanders pronounce vowels really short, so, it doesn't sound so far off from a schwa anyway. 03:07:52 interesting 03:07:59 Hence the usual jokes about fush'n'chups. 03:08:04 heh 03:08:06 I went with "coulder" 03:08:12 could er 03:08:37 that's what TSPL said. it got to me before you all;) 03:08:41 lewis1711: Pretty much identical, if pronounced with New Zealand accent. 03:08:53 to whjat? cooder? 03:08:54 I pronounce CDR with the FOOT vowel. 03:08:59 lewis1711: Yes. 03:09:00 guess i don't have a new zealand accent 03:09:03 as opposed to the GOOSE vowel. 03:09:12 "cooder" is ambiguous 03:09:16 which is not a bad thing, as it sounds terrible 03:09:16 :P 03:09:26 lewis1711: Oooh, burn. 03:09:35 jcowan: Good point (re ambiguity). 03:09:50 jcowan: I also say it with the "foot" sound rather than "goose". 03:10:10 cooder would rhyme with goose imo 03:10:11 In a few places there is no distinction, notably Scotland. 03:10:25 oi cood put ut in tha frug 03:10:30 so "could-er" would be a less ambiguous spelling, since "could" has the FOOT vowel. 03:10:37 lewis1711: I have the "fush and chups" variety of Kiwi accent. i.e., the dominant one. :-P 03:10:47 jcowan: Agree. 03:10:52 the country one? 03:11:11 Or more precisely the KIT = STRUT accent. 03:11:14 lewis1711: Well, no country Kiwi would call me one. :-P 03:11:28 *cky* = ex-Aucklander. 03:12:19 city people don't usually have strong accents here 03:12:24 jcowan: this vowel, then? 03:13:05 klutometis: Well, the point of saying FOOT is that it means "the vowel you use when you say 'foot'", which may or may not be precisely that vowel. 03:13:22 lewis1711: Where's "here" for you? I can't seem to remember. 03:13:30 nz 03:13:34 lewis1711: Well, yeah. 03:13:39 lewis1711: But, which part of New Zealand. 03:14:03 lower north island. it's irrelevant anyway, as there aren't regional accents 03:14:06 there's hick, city and native 03:14:12 hick? 03:14:14 Heh. 03:14:38 what accent do the sheep have? 03:14:47 Axioplase_: yeah, country folk. get an absurd amount of money from the government. ruin our water ways 03:15:36 Ha, I didn't know that word. 03:15:36 bremner: you have sheep that can talk?:O 03:15:59 I assumed NZ could only work if the sheep were running most things. 03:16:06 *lewis1711* sings "talk to the animals, walk with the animals" 03:16:06 bremner: Hehehehehe. 03:16:13 Axioplase_: From Hick, a now-disused nickname for Richard 03:16:37 If this were #stackoverflow rather than #scheme, I'd have something very smartalecky to say to all that stuff about sheep. :-P 03:16:39 jcowan: "hook" is an instance of near-close near-back; i'm trying to discern whether that's identical to "foot." 03:16:45 Yes. 03:17:05 But it is really more correct to say that hook *in certain accents* is near-close near-back. 03:17:16 jcowan: I still think that "Hick" is better than "Dick" 03:17:29 Australian and RP don't sound much alike, but *structurally* they are identical; the vowels are isomorphic. 03:17:44 cky: the first time i ever heard about sex with sheep was in australia. i am pretty sure animal sex is their fascination;) 03:18:00 classic case of psychological projection 03:18:01 "When men were men and sheep were nervous." 03:18:11 lewis1711: Hahahaha. This isn't the right venue for it, but, point noted. 03:18:43 erjiang: I spotted your brief visit to the channel. (BTW, I know you answer lots of [scheme] questions on SO, so I want to acknowledge that at least.) 03:18:46 :-D 03:18:57 why, thank you :) 03:19:21 :-D 03:19:34 I find most questions on SO boring, but some Scheme ones aren't too bad. 03:19:41 jcowan: Don't they? I'm not a native speaker, but when I fail to identify a Brit (or, more precisely and Englishman), he more than often happens to be Australian 03:19:56 cky: the few that aren't homework questions, anyways 03:19:58 I guess I must find more shibboleth to tell them apart 03:20:01 erjiang: Exactly. 03:20:50 -!- bitweiler [~bitweiler@adsl-99-40-239-167.dsl.stl2mo.sbcglobal.net] has quit [Ping timeout: 240 seconds] 03:20:59 Some Australians do sound very RP, what is called Cultivated Australian. But General Australian, for example, uses the same quality of vowel in "cup" and "carp", except that "carp" is prolonged relative to "cup". This is not so in the U.K. or the U.S. in any accent I know of. 03:21:19 *nods* 03:21:21 Axioplase_: you're French? 03:21:54 jcowan: Yes sir. 03:22:41 However, I'm proud to even make English people believe I'm from Northern England when I meet them. 03:23:04 I like imitating the accent in foreign countries while asking for directions 03:23:58 bitweiler [~bitweiler@adsl-99-40-239-167.dsl.stl2mo.sbcglobal.net] has joined #scheme 03:24:16 -!- carleastlund [~cce@gotham.ccs.neu.edu] has quit [Quit: carleastlund] 03:24:36 lewis1711: Both my French and Japanese have mixed accents I randomly mix Québécois and France's French, as well as standard Japanese and Northern dialect 03:25:38 Modius_ [~Modius@cpe-70-123-158-125.austin.res.rr.com] has joined #scheme 03:25:43 However, my English is fairly consistent, though I can get an Irish or a Scottish accent after I recall how some native speakers talk (in order to "tune" my voice) 03:26:20 -!- kniu [~kniu@DOHOHO.RES.CMU.EDU] has quit [Remote host closed the connection] 03:26:50 homie` [~levgue@xdsl-78-35-144-175.netcologne.de] has joined #scheme 03:26:57 kniu [~kniu@DOHOHO.RES.CMU.EDU] has joined #scheme 03:27:05 Axioplase_: In most English accents, the difference between "cup" and "carp" is roughly the difference between "tache" and "tâche" among those who still make the distinction. 03:27:51 -!- homie` [~levgue@xdsl-78-35-144-175.netcologne.de] has quit [Remote host closed the connection] 03:28:04 -!- wbooze [~levgue@xdsl-78-35-144-175.netcologne.de] has quit [Quit: ERC Version 5.3 (IRC client for Emacs)] 03:28:27 -!- phao [~phao@189.107.253.248] has quit [Ping timeout: 240 seconds] 03:28:45 hmm. I admit I say "tache" and "tâche" similarly 70% of the times (I try to distinguish them, but in casual conversation, they'd collapse) 03:28:54 *jcowan* nods. 03:29:08 martin_hex [~mjc@93-97-29-243.zone5.bethere.co.uk] has joined #scheme 03:29:08 -!- martinhex [~mjc@93-97-29-243.zone5.bethere.co.uk] has quit [Disconnected by services] 03:29:09 -!- martin_hex is now known as martinhex 03:29:31 FillIRC [~Fill@static.195.170.4.46.clients.your-server.de] has joined #scheme 03:29:43 I'll ask people around me. There are many English speakers in Japan from all around the world (JETters, English teachers in high schools), and it will make a perfectly nice survey. 03:29:55 homie` [~levgue@xdsl-78-35-144-175.netcologne.de] has joined #scheme 03:31:24 -!- dfkjjkfd [~paulh@158-9-ftth.onsnetstudenten.nl] has quit [Quit: Lost terminal] 03:32:00 stepnem_ [~stepnem@176.119.broadband10.iol.cz] has joined #scheme 03:32:09 -!- homie` [~levgue@xdsl-78-35-144-175.netcologne.de] has quit [Client Quit] 03:33:19 wbooze [~levgue@xdsl-78-35-144-175.netcologne.de] has joined #scheme 03:34:08 Kirill [~user@CPEf81edff80afa-CM0016924f5bee.cpe.net.cable.rogers.com] has joined #scheme 03:34:17 hi! are "when" and "unless" part of any rnrs? 03:34:20 rpg_ [~rpg@216.243.156.16.real-time.com] has joined #scheme 03:34:40 Kirill: Not that I'm aware of. Write your own, if your implementation doesn't have it. :-D 03:34:41 A Norman told me by email that he made no brun/brin distinction, and I pointed out that in an email he had written four years earlier, he said that he made the distinction clearly even though people around him did not. 03:34:51 cky: I'm using gambit, and by default it doesn't have it. either that, or I'm confused 03:34:53 -!- homie [~levgue@xdsl-78-35-144-175.netcologne.de] has quit [*.net *.split] 03:34:53 -!- Modius [~Modius@cpe-70-123-158-125.austin.res.rr.com] has quit [*.net *.split] 03:34:53 -!- Fill [~Fill@unaffiliated/fill] has quit [*.net *.split] 03:34:54 -!- stepnem [~stepnem@176.119.broadband10.iol.cz] has quit [*.net *.split] 03:34:54 -!- preflex [~preflex@unaffiliated/mauke/bot/preflex] has quit [*.net *.split] 03:34:54 -!- devn [~defn@rot13.pbqr.org] has quit [*.net *.split] 03:34:54 -!- `micro [~micro@www.bway.net] has quit [*.net *.split] 03:34:54 -!- sloyd [sloyd@station457.vo3.net] has quit [*.net *.split] 03:34:55 -!- timchen1` [tim@163.16.211.21] has quit [*.net *.split] 03:34:55 -!- stepnem_ is now known as stepnem 03:35:10 -!- DrDuck [~duck@216.186.151.63] has quit [Ping timeout: 255 seconds] 03:35:25 Normand. And I don't make this distinction either. And never heard it. I discovered in a book a few months ago that they were "supposed" to be pronounced differently 03:35:26 Well, definitely worth writing your own, then. :-D 03:35:40 homie [~levgue@xdsl-78-35-144-175.netcologne.de] has joined #scheme 03:35:43 already did =) I just like to make sure I'm not writing something that already exists 03:35:55 any gambit users here to confirm/deny existence of when/unless in gambit? 03:36:04 Kirill: I reimplemented them. 03:36:13 good enough for me =) 03:36:21 :-D 03:36:36 -!- jeapostrophe_ [~jay@69.169.141.110.provo.static.broadweavenetworks.net] has quit [Quit: jeapostrophe_] 03:36:38 -!- rpg [~rpg@216.243.156.16.real-time.com] has quit [Ping timeout: 240 seconds] 03:37:26 preflex [~preflex@unaffiliated/mauke/bot/preflex] has joined #scheme 03:37:26 devn [~defn@rot13.pbqr.org] has joined #scheme 03:37:26 `micro [~micro@www.bway.net] has joined #scheme 03:37:26 sloyd [sloyd@station457.vo3.net] has joined #scheme 03:37:26 timchen1` [tim@163.16.211.21] has joined #scheme 03:37:28 "Normand" in French = "Norman" in English. He even had an English name, or rather a name that was also an English word borrowed long ago. 03:37:56 -!- Azuvix [~Azuvix@71-215-25-216.bois.qwest.net] has quit [Quit: Leaving] 03:41:58 lolcow [~lolcow@196-210-162-106.dynamic.isadsl.co.za] has joined #scheme 03:41:58 -!- leppie [~lolcow@196-210-162-106.dynamic.isadsl.co.za] has quit [Read error: Connection reset by peer] 03:42:33 -!- Caleb-- [thedude@109.65.199.183] has quit [Ping timeout: 272 seconds] 03:43:25 adu [~ajr@pool-72-83-254-159.washdc.fios.verizon.net] has joined #scheme 03:44:32 sanduz2 [~sanduz2@75-149-186-118-Miami.hfc.comcastbusiness.net] has joined #scheme 03:47:26 -!- parcs [~patrick@ool-45741d7d.dyn.optonline.net] has quit [Ping timeout: 240 seconds] 03:47:50 -!- erjiang [~eric@7.80.244.66.jest.smithvilledigital.net] has quit [Ping timeout: 240 seconds] 03:49:04 parcs [~patrick@ool-45741d7d.dyn.optonline.net] has joined #scheme 03:49:27 can someone tell me whats wrong with this: http://pastebin.com/Ya4Ab9Eq 03:49:56 jcowan: This seems like the moment at which this question will be as on-topic as it's ever likely to be: Are you the same John Cowan who I've seen commenting on http://separatedbyacommonlanguage.blogspot.com/ ? 03:50:02 Yes. 03:50:08 Cool. :-) 03:50:10 But I'm not the Doobie Brother. 03:50:18 Heh 03:50:41 I don't even engage in doobieous battles. 03:52:46 timj__ [~timj@e176192203.adsl.alicedsl.de] has joined #scheme 03:53:54 -!- lolcow [~lolcow@196-210-162-106.dynamic.isadsl.co.za] has quit [Ping timeout: 265 seconds] 03:54:30 leppie [~lolcow@196-210-162-106.dynamic.isadsl.co.za] has joined #scheme 03:56:46 -!- timj_ [~timj@e176199223.adsl.alicedsl.de] has quit [Ping timeout: 276 seconds] 03:57:56 sanduz2: http://pastebin.com/4GcWXyNb 03:58:28 hope that helps, you wasn't evaling sumsquare if condition was meet 03:58:47 thank you bitweiler 03:59:15 np 04:04:09 slk- [~dick@bas2-streetsville39-2925474908.dsl.bell.ca] has joined #scheme 04:10:23 hello sirs, i have a question about list? 04:10:34 how do I know if something is not a list, !list? 04:10:52 (not (list x)) 04:10:58 er, (not (list? x)) 04:11:04 type in haste, repent at leisure 04:11:07 ok cool thx 04:14:35 -!- bitweiler [~bitweiler@adsl-99-40-239-167.dsl.stl2mo.sbcglobal.net] has quit [Ping timeout: 260 seconds] 04:15:03 quick question 04:15:05 (define (reverse-all L) 04:15:05 (cond [(null? L) L] 04:15:05 [(list? (last L)) (reverse (car (reverse L))) ] 04:15:06 [(not (list? (last L))) (car (reverse L))])) 04:15:17 im trying to have 2 things happen when a condition is true 04:15:21 can I do this? 04:15:38 ie. [(list? (last L)) (reverse (car (reverse L))) (reverse-all L)] 04:17:08 You can, but it probably doesn't do what you want. It calls reverse, throws away the result, and then calls reverse-all. 04:17:16 Remember that Scheme is based on expressions, not statements. 04:17:40 gay 04:17:42 There are Scheme procedures that have side effects, but none of the above do. 04:18:02 .oO(scheme has sex?) 04:18:07 so "(reverse l) returns a new list that contains the elements of l in reverse order: it does not, imperatively, reverse l. 04:18:50 oh i see 04:18:58 jeapostrophe_ [~jay@69.169.141.110.provo.static.broadweavenetworks.net] has joined #scheme 04:19:12 bitweiler [~bitweiler@99.40.239.167] has joined #scheme 04:19:34 boy I got to stop infinite looping 04:20:13 Buy a faster computer, then. 04:20:35 if I can afford one I would 04:21:11 think I better leave project euler alone 04:21:33 My computer can run (define (loop) (loop)) (loop) twice as fast as yours! 04:21:39 every once in a while I have the project euler urge, but then I lie down for 20 minutes and the urge goes away 04:21:55 plus I am not that mathematically incline 04:22:04 lol 04:22:41 Kirill: five minutes with me 04:22:47 heh 04:22:52 well, it's sleep time. night everyone! =) 04:22:54 -!- Kirill [~user@CPEf81edff80afa-CM0016924f5bee.cpe.net.cable.rogers.com] has left #scheme 04:25:27 *offby1* does project euler once in a while 04:25:31 also programming praxis 04:26:30 -!- jeapostrophe_ [~jay@69.169.141.110.provo.static.broadweavenetworks.net] has quit [Quit: jeapostrophe_] 04:31:27 offby1: what is seiving? 04:32:31 I dunno. 04:32:44 Maybe computing primes with the "sieve of whats-his-name" method? 04:32:51 Sieving, however, is what you do to get the lumps out of your slour 04:32:57 ah 04:32:59 s/slour/flour/ 04:33:01 ah 04:33:03 I have a little hand-siever 04:33:08 I call it "sifting" 04:33:21 Or in general applyin an algorithm repeatedly to a list, changing a parameter each time, and removing the hits. 04:33:25 Dialectical difference, I reckon 04:33:41 fds: what dialect says "sieve"? I'm from East Coast US 04:33:53 or as jcowan might say: A small island off the US East Coast 04:34:04 I'm from West Coast UK 04:34:07 jcowan: I see Google gonna buy that old Port Authority building. 04:34:10 *jcowan* isn't from there, but lives there 04:34:10 I say sieve 04:34:16 gotcha 04:34:22 offby1: Yeah, but that doesn't mean they can kick out all existing tenants. 04:34:32 I would hope not. 04:34:38 Perhaps fail to renew their leases 04:34:52 Some of them have data centers in that building, which are extremely expensive to move. 04:40:19 githogori [~githogori@adsl-66-123-22-146.dsl.snfc21.pacbell.net] has joined #scheme 04:43:04 -!- gnomon [~gnomon@CPE0022158a8221-CM000f9f776f96.cpe.net.cable.rogers.com] has quit [Ping timeout: 255 seconds] 04:44:57 gnomon [~gnomon@CPE0022158a8221-CM000f9f776f96.cpe.net.cable.rogers.com] has joined #scheme 04:52:24 -!- RageOfThou [~RageOfTho@users-146-124.vinet.ba] has quit [Ping timeout: 240 seconds] 04:52:51 -!- MrFahrenheit [~RageOfTho@users-146-124.vinet.ba] has quit [Ping timeout: 240 seconds] 04:53:27 -!- sanduz2 [~sanduz2@75-149-186-118-Miami.hfc.comcastbusiness.net] has quit [Quit: Leaving] 04:56:07 mwolfe [~michael@cpe-67-49-72-40.socal.res.rr.com] has joined #scheme 05:00:46 nilg [~user@77.70.2.229] has joined #scheme 05:03:19 -!- rpg_ [~rpg@216.243.156.16.real-time.com] has quit [Quit: rpg_] 05:03:44 -!- myu2 [~myu2@v077103.dynamic.ppp.asahi-net.or.jp] has quit [Remote host closed the connection] 05:04:42 -!- groovy2shoes [~guv@unaffiliated/groovebot] has quit [Quit: groovy2shoes] 05:15:03 jonrafkind [~jon@jonr5.dsl.xmission.com] has joined #scheme 05:19:29 man, I have *no* idea what they are talking about in the SLIB manual:P 05:20:25 *offby1* recalls it being a tad eccentric, but more-or-less comprehensible 05:20:30 "they" is probably just Aubrey Jaffer 05:20:59 He does seem a little eccentric, but also really cool. :-) 05:21:24 llke all good coders he is probably semi autistic and thus crap at documentation:P 05:21:47 alas 05:22:59 seriosuly though, it's installed, uh, how does one use it? it mentions require a lot, which doesn't even seem to be an r5 word 05:23:00 *jcowan* is merely socially inept, and actually pretty good at documentation. 05:23:05 lol 05:23:26 yeah I am not bad at documentation. the coding could do with some work 05:25:08 lewis1711: I suspect that, with any modern scheme, one doesn't use it at all. 05:25:42 offby1: most schemes are still r5 and missing a lot 05:26:26 my favorite scheme -- Racket -- arguably is missing the least; and yet _it_ is missing a lot :-| 05:28:00 racket is probably the nicest scheme I've used actually. but if i actually want to use scheme for something non-trivial I want better integration with C-land 05:29:28 I've never really played with it, but I hear the racket FFI is the best there is 05:29:38 lets you do everything you want without having to write a line of C code 05:29:54 jeapostrophe_ [~jay@69.169.141.110.provo.static.broadweavenetworks.net] has joined #scheme 05:29:58 That's not hard to arrange, provided you are willing to write Scheme that looks a lot like C. 05:30:01 offby1: I am not really into FFI's. I prefer writing extensions 05:30:16 In general, there is always glue; whether it is weird C glue or weird Scheme glue is what varies. 05:30:17 in gambit I can just embed the C right in there 05:30:54 <_danb_> so when does one use gambit vs chicken vs guile vs racket ? 05:31:09 offby1: actually, if there was a nice racket-C tute, I probably would have stuck with it. it looks messier than gambit but still doable, though i'm not 1337/patient enough to figure it out from the manual 05:31:34 _danb_: you use usually start with the one that suits your needs at a given time, and stick to it. 05:31:52 <_danb_> but if they were chocolates in a chocolate box.... 05:32:15 _danb_: Then, at a given time, my boss was from Lindt. 05:33:12 _danb_: But chocolates do not suit any *need* per say. 05:33:35 Personally I picked Chicken because I thought it had a cool implementation. 05:33:46 <_danb_> well, which ones are the soft centres and which have the nuts in them 05:33:49 But now I like Chibi because it's small and easy to understand. 05:34:02 yeah chicken seemed nice, but the no-warning-about-multiple-define thing was a deal breaker 05:34:08 Chibi? never heard of it 05:34:09 _danb_: wait, are we talking about chocolate, or ... 05:34:09 If I need threads, I'll use an implementation with threads. Then I need exceptions. So, I'll consider an implementaion with threads and exceptions. And so on. 05:34:19 <_danb_> :) 05:35:06 _danb_: By choosing an implementation, you choose a language. 05:35:16 <_danb_> Axioplase_: I guess I wanted a 10,000ft view of what each one did that made it notable 05:36:07 racket is probably the most popular, and is very nice and well documented. not minimalist like a lot of schemes 05:36:28 <_danb_> lewis1711: yup, I wish racket was the next ruby or python in that regard 05:36:34 <_danb_> I mean it's there but... 05:36:44 _danb_: When comparing two languages, (say, C++ and Java), it's easy. When comparing 10+ languages all together, it's a mess. You won't get your 10,000ft view. 05:36:48 don't compare ruby to python, that's not fair on ruby!:D 05:36:56 _danb_: the biggest thing I miss from racket: an ORM that talks to MySQL. 05:37:08 They have an ORM, and they have MySQL drivers ... just not one piece that does both 05:37:08 Axioplase_: unless you have 10+ eyes 05:37:24 <_danb_> offby1: noone's done an orm! hm 05:37:39 ORMG! 05:38:14 <_danb_> that's a bit surprising (in racket) 05:38:33 _danb_: no, there's an ORM; but if I recall correctly it only talks to PostGres 05:38:38 <_danb_> I'd probably try to do it without inheritance 05:38:40 <_danb_> oh 05:38:47 and "ORM" in racket probably means something rather different than ORM in Python 05:39:01 <_danb_> well that's easy then; postgres is far superior anyway :) 05:39:21 <_danb_> I was thinking of active record and the active record pattern 05:40:26 "Support for locating an implementation's auxiliary directory is uneven among implementations. Also, the person installing SLIB may not have write permission to some of these directories (necessary for writing slibcat). Therefore, those implementations supporting getenv (except SCM and Scheme48) provide a means for specifying the implementation-vicinity through environment variables. Define the indicated environment variable to th 05:41:54 _danb_: Well, Gambit and Chicken produce the fastest compile code; Racket is the biggest, though Chicken has a fairly big set of 3rd-party libraries. Chibi is R5RS-complete and very compact. Scsh and Gauche are meant for writing scripts, mainly. Kawa and SISC are Java-based. Scheme 9 is a beautifully written classical Scheme interpreter. 05:42:12 -!- jeapostrophe_ [~jay@69.169.141.110.provo.static.broadweavenetworks.net] has quit [Quit: jeapostrophe_] 05:42:29 never heard of Scheme 9 05:42:33 is it from outer space? 05:42:38 Guile is a GNU scripting library for various apps, which used to have a bad reputation but is now much improved. 05:42:55 It's from Empty Space, actually 05:43:26 <_danb_> jcowan: thank you 05:44:19 Kawa is faster than SISC and better integrated, but less conformant. 05:44:52 <_danb_> and I think it can be used on android 05:45:07 <_danb_> not that I know much about that whole thing (yet) 05:45:43 Lastly, Ikarus, IronScheme (.NET), Larceny, and Mosh all support R6RS, as do Chez (proprietary, but there's a free-beer version with no compiler) and Racket. 05:46:12 The rest are R5 except for S9 which is R4 (no macros, basically). 05:46:13 <_danb_> Ever heard of termite? 05:46:32 Yeah, it's Erlang in Scheme, basically, with no mutable data structures. 05:46:42 I'm only discussing general-purpose Schemes here. 05:48:04 dskippy [~dskippy@209-6-28-198.c3-0.smr-ubr1.sbo-smr.ma.cable.rcn.com] has joined #scheme 05:48:10 _danb_: I was entranced with termite for a little while, having actually used Erlang at work 05:48:16 also its author used to hang out here 05:49:02 Embedded in Gambit, too. 05:49:36 too many schemes have terrible, terrible names 05:49:47 who thought the name 'chicken' was a good idea?:P 05:49:47 <_danb_> termite is an awesome name :) 05:49:59 termite is not so bad 05:50:00 s/terrible/ungoogleable/ 05:50:01 Also, gambit has an emacs mode, fwiw. 05:50:23 gambit comes on the first page of a google search. 05:50:48 Right, but if you're actually looking for posts about them rather than just their homepage 05:50:52 Even with all the X-Men references? Wow. 05:51:05 _danb_: I'm afraid I don't get the joke with "termite" 05:51:26 lewis1711: Felix had (has?) a character figurine of the bad penguin from "The 05:51:26 > Wrong Trousers", a "Wallace & Gromit" adventure. He saw this when 05:51:26 > searching a name for his new Scheme compiler. From a bird to Chicken 05:51:26 > is his internal logic. 05:51:33 fds: googlability was an important criterion in the choice of the name "racket" 05:51:40 is the "reference implementation" meant as a caonical example? 05:52:21 lewis1711: "it works, but there may be other (better) ways to do it by modifying the interpreter/compiler" 05:52:26 jcowan: That's awesome, I like Chicken even more now! 05:52:26 blergh 05:52:38 I was tempted to just grab the code and include it, rather than figure out SLIB:P 05:52:38 <_danb_> offby1: well I like the name; don't know if it's a joke; just conjures an image of lots of little termites building stuff 05:52:53 The source code is highly readable, assuming you know C and some Scheme. 05:53:06 offby1: Yeah, Racket is one of the better implementations in that respect. (It also doesn't help that the word Scheme itself is so generic!) 05:53:26 racket isn't very google-able 05:53:34 most of the time I have to put "racket lang" in my searches 05:54:20 At least you don;t get results for birds or characters from Street Fighter :-P 05:54:23 Of the first 10 ghits for "scheme" (at least as returned to me), 8 are about Scheme. 05:54:27 ..Or X-Men 05:55:08 Doesn't change when I log out, either, although I should destroy my cookie to really be sure. 06:03:02 jcowan: the source code for what? I can't make out 06:03:31 -!- dskippy [~dskippy@209-6-28-198.c3-0.smr-ubr1.sbo-smr.ma.cable.rcn.com] has quit [Ping timeout: 276 seconds] 06:03:52 Scheme 9 06:03:54 kilimanjaro [~kilimanja@unaffiliated/kilimanjaro] has joined #scheme 06:04:01 ok, thanks 06:04:14 dskippy [~dskippy@209-6-46-202.c3-0.smr-ubr1.sbo-smr.ma.cable.rcn.com] has joined #scheme 06:04:43 jeapostrophe_ [~jay@69.169.141.110.provo.static.broadweavenetworks.net] has joined #scheme 06:05:55 -!- zbigniew [~zb@2001:470:1f11:961::3e8] has quit [Quit: Changing server] 06:06:09 -!- mwolfe [~michael@cpe-67-49-72-40.socal.res.rr.com] has quit [Remote host closed the connection] 06:06:13 zbigniew [~zb@ipv6.3e8.org] has joined #scheme 06:06:50 -!- jeapostrophe_ [~jay@69.169.141.110.provo.static.broadweavenetworks.net] has quit [Client Quit] 06:13:40 -!- jcowan [~John@cpe-74-68-112-189.nyc.res.rr.com] has quit [Quit: Leaving] 06:21:23 jeapostrophe_ [~jay@69.169.141.110.provo.static.broadweavenetworks.net] has joined #scheme 06:22:09 -!- jeapostrophe_ [~jay@69.169.141.110.provo.static.broadweavenetworks.net] has quit [Client Quit] 06:25:19 -!- kilimanjaro [~kilimanja@unaffiliated/kilimanjaro] has quit [Ping timeout: 272 seconds] 06:38:18 is there a chat for lisps in general? not CL 06:41:43 lewis1711: You can use either the racket-level ffi, or write extensions in C. The latter was the only choice until some time ago, but pretty much everyone didn't like writing C code. 06:41:48 DrDuck [~duck@66-168-225-64.static.mtgm.al.charter.com] has joined #scheme 06:42:17 eli: yeah, i know you *can* do it, but my argument is that it's not nearly as nice as using a "C-Scheme" such as gambit 06:43:07 Well, you should decide what you want -- C or Scheme. 06:43:33 hehe.. 06:44:22 that's just an irrational response 06:44:48 I also made a bunch of responses praising racket. but no implementation/language/whatever can do everything right:P 06:45:06 lewis1711: Do you want to write Scheme or C? 06:45:39 nope, not gonna respond to that:P 06:45:45 phao [~phao@189.107.143.240] has joined #scheme 06:45:53 you must troll more subtley my friend 06:45:59 Huh? 06:46:17 You claim that you have a difficulty choosing the right way to write some foreign interface. 06:46:31 I ask how you prefer to work. 06:46:45 oh right 06:46:50 my mistake 06:46:52 I do that to point you at a convenient way to do what you want. 06:46:59 No trolling intended. 06:47:03 eli: which ever is fastest, I want to avoid the overhead 06:47:28 eli: I know racket has a a way in the manual, but as a pointed out I'd need something more comprehensive to do it myself 06:47:43 IME writing modules in C for higher level language X is usually the fastest way 06:48:03 BTW, IIRC, the gambit thing is some Scheme-syntax way of writing C code, which is why it's an odd thing when you can write just Scheme code (or just C, of course). 06:48:34 Also, if you're talking about things like `c-lambda', then Racket has that too (inspired by gambit, btw), but it's hardly used these days, and it shouldn't be used if you want a nice experience. 06:48:47 interesting 06:49:03 Re the speed -- it's usually negligible. 06:49:30 The C extensions are obviously the fastest, but when you deal with C being able to manage your code becomes much more important. 06:49:40 eli: c-lambda seems much less painful than what is in the lambda 06:49:44 *in the manual 06:50:27 Well, given that you can write just racket code, it's mostly irrelevant. 06:50:50 But that's why I asked how exactly you want to write code. 06:51:17 I'll show you an example of what I am doing in racket 06:51:20 *gambit 06:51:27 ok. 06:52:14 http://paste.pocoo.org/show/318723/ 06:52:34 I am finding this extremely convenient. I don't have to write my own library, and the only boiler plate is in scheme 06:53:01 of course I am almost positive it'd be impossible to *embed* the C like that in racket, but reading the manual entails *a lot* more work 06:54:31 Are you interested only in the `c-lambda' stuff? 06:54:47 Because that's pretty much trivial to translate. 06:55:02 oh? without having a shared library already compiled, ie using raw C source? 06:55:19 if so I am very interested:) 06:55:57 heck i'd even make a library if I could use c-lambda stuff 06:55:59 I'm talking about *just* the lambda code. 06:56:11 Just a second, I'll show you what I mean. 06:57:02 lewis1711: BTW, there's a bug in your code. 06:57:10 yeah, the break thing 06:57:15 or something else? 06:57:18 No, more subtle. 06:57:26 You define init_values() with two ints. 06:57:39 Then you use c-lambda with unsigned-int32 06:57:57 In any case, http://tmp.barzilay.org/x 06:58:43 "(define foo (ffi-lib "whatever"))" 06:58:49 what is whatever, a C header? 06:59:16 No, some file that defines init_values() 06:59:35 Like I said, I'm talking now *only* about the `c-lambda' stuff. 06:59:44 ah 06:59:53 So, does that look reasonable? 07:00:09 eli: it all depends on what the steps between C source code and that "c-lambda" stuff are 07:00:44 eli: I would probably be using racket if there was a tutorial on writing modules, etc out there. I am not a compotent enough coder to go just by whats in the manual, as it assumes some proficiencys 07:00:58 OK, so I take it that you're happy with the way a function is pulled like that. 07:01:09 for example, I can write C modules for ruby, but there's a hybrid manual/tutorial out there that's more detailed 07:01:14 yeah, that's fine 07:01:25 -!- adu [~ajr@pool-72-83-254-159.washdc.fios.verizon.net] has quit [Quit: adu] 07:02:21 BTW, for most simple uses there's not that much -- but you can also do this with callbacks -- for example (_fun (_fun _int -> _int) -> _int) would work as you'd expec it to. 07:03:28 In any case, what you want now -- besides the glue stuff -- is to write some minimalistic C code to bind the Scheme code to. 07:03:51 (Like that init_values() in your example.) 07:04:37 You could do that by writing a simple C code and compiling it into a dll/so/dylib. 07:04:46 And then the result of that would be that "whatever". 07:05:00 that's all there is to it? 07:05:12 Yeah. 07:05:44 so "whatever" could be a pure C library... (my embedded C had no glue 07:05:46 ) 07:05:54 I will boot up racket and try it out then 07:05:55 If you're dealing with stuff like macro definitions, then this becomes very tempting, since the racket ffi cannot see them. (Obviously, since they don't exist in the libraries.) 07:06:29 There is, of course, the possibility of combining both the C and Scheme code in the same file. 07:06:41 That takes a little work to do, but someone already did that. 07:07:42 Here: http://planet.racket-lang.org/display.ss?package=superc.plt&owner=jaymccarthy 07:07:43 http://tinyurl.com/2g4hoy3 07:08:12 And here's an example of that: http://planet.racket-lang.org/package-source/jaymccarthy/superc.plt/2/0/examples/hello.ss 07:08:13 http://tinyurl.com/4hbt4la 07:08:28 -!- nowhere_man [~pierre@AStrasbourg-551-1-30-209.w83-196.abo.wanadoo.fr] has quit [Quit: Konversation terminated!] 07:08:37 In any case, that would give you practically the same thing as the gambit thing -- but... 07:08:46 nowhere_man [~pierre@AStrasbourg-551-1-30-209.w83-196.abo.wanadoo.fr] has joined #scheme 07:08:55 -!- DrDuck [~duck@66-168-225-64.static.mtgm.al.charter.com] has quit [Ping timeout: 255 seconds] 07:08:57 ...in your case, I think that the C file for the C code would work out better. 07:09:38 You write that minimal C code there -- with an interface that has only simple function (for example, just use integers or whatever), 07:10:20 and that will allow you to write a single piece of C code and interact with it with small glue code in several other languages. 07:12:45 eli: I see what you mean. I suppose the overhead of an FFI would be pretty small if I wrapped C functions like that. is thos documented in the racket manual somewhere, btw? 07:14:06 Caleb-- [thedude@bzq-109-65-199-183.red.bezeqint.net] has joined #scheme 07:15:15 ello 07:15:32 oh, there's an FFI section 07:15:41 well, I'll try it out anywa 07:15:42 y 07:16:06 lewis1711: You're looking for the documentation for what? 07:16:25 the c-lambda-esque stuff you copypasta'd 07:16:33 err, you posted 07:16:38 *lewis1711* needs sleep 07:17:12 You mean `get-ffi-obj'? 07:17:19 Just look for it in the docs. 07:21:54 kilimanjaro [~kilimanja@unaffiliated/kilimanjaro] has joined #scheme 07:24:20 how many of you guys are using utf-8 irc clients? 07:25:04 vu3rdd [~vu3rdd@nat/cisco/x-ktrviribfeaysopu] has joined #scheme 07:25:04 -!- vu3rdd [~vu3rdd@nat/cisco/x-ktrviribfeaysopu] has quit [Changing host] 07:25:04 vu3rdd [~vu3rdd@fsf/member/vu3rdd] has joined #scheme 07:26:03 -!- MichaelRaskin [~MichaelRa@195.91.224.225] has quit [Remote host closed the connection] 07:27:41 Caleb--: I think I am 07:28:03  - yeap 07:29:39 btw, why is it than in scheme (expt) is considered a binary operator but +, -, / or * are not? 07:30:05  07:30:43 Leonidas, maybe because they can accept more than 2 parameters? 07:30:45 lewis1711* 07:31:24  07:31:25 Caleb--: in mathematics, they cannot 07:31:42 so why not have expt take more than 2 arguments as well? 07:31:45 seems inconsistent to me 07:32:41 adding more than 2 numbers makes more sense than raising something to more than one power 07:32:43 i gotta go 07:34:59 -!- kilimanjaro [~kilimanja@unaffiliated/kilimanjaro] has quit [Ping timeout: 272 seconds] 07:34:59 by what metric? 07:35:11 (+ a b c d) => a + b + c + d 07:35:28 (expt a b c d) => a ^ b ^ c ^ d 07:35:59 2^2^2 => 2^4 => 16 07:38:14 lewis1711: It is inconsistent, and I doubt there's a real reason for it, other than that being a less common use case. 07:38:32 just surprises me given who created scheme 07:42:17 It seems reasonable to me, given that one /very/ rarely needs to repeatedly exponentiate values and how fast those values usually grow if you did. 07:43:16 In the vast majority of cases, it'd just be another unnecessary varargs call the compiler has to optimize out (if it's capable). 07:43:41 <_danb_> bah! just use ackermann's function anyway! :) 07:44:57 Obfuscate: doesn't sit well with me. scheme is supposed to be clean. if a vararg expt is too difficult, then make the arithmetic operators binary for consistancies sake. one could easily define a "sum" and "product" function if needed 07:48:54 lewis1711: ok, then... how about that the other math operations are left-associative while exp is right-associative? 07:50:24 does - take multiple parameters? 07:50:41 Obfuscate: +, - and * are associative both ways 07:50:43 copumpkin: Yes. 07:50:51 rudybot: (- 1 2 3 4) 07:50:51 lewis1711: your sandbox is ready 07:50:51 lewis1711: ; Value: -8 07:50:59 lewis1711: - isn't even associative 07:51:13 lewis1711: I mean operator associativity. 07:51:25 (nor is /) 07:51:32 never mentioned / 07:51:39 [02:29:39 AM] btw, why is it than in scheme (expt) is considered a binary operator but +, -, / or * are not? 07:51:59 never said it was associative both ways 07:52:02 you caught me with - though 07:52:17 *copumpkin* puts handcuffs on lewis1711 07:52:30 ha 07:53:23 anyway, I'd guess it's mostly because with + and *, the associativity doesn't matter. - isn't behaving the same way as the others (i.e., it isn't a fold over the binary op over the arg list) 07:53:34 rudybot: (/ 1 2 3 4) 07:53:36 copumpkin: your sandbox is ready 07:53:36 copumpkin: ; Value: 1/24 07:54:10 and ^ has vastly different meaning depending on how you associate it 07:54:27 (unlike the others, it isn't just the inverse of the associative operations) 07:54:37 which is how the others are being treated 07:54:53 (/ 1 2 3 4) = 1 / (* 1 2 3 4) 07:55:27 oh wait, hmm 07:55:37 let's just say it isn't consistent and leave it at that :) 07:57:20 To be fair, I think that applies to / as well as ^, but then exp isn't called ^ in scheme anyways. ;) 07:57:24 how does (- 1 2 3 4) even evaluate to -8? 07:58:23 1 - (2 + 3 + 4) 07:58:38 I guess the / is behaving the same way 07:58:44 myu2 [~myu2@58x5x224x106.ap58.ftth.ucom.ne.jp] has joined #scheme 07:58:59 rudybot: (/ 2 2 3 4) 07:59:00 copumpkin: ; Value: 1/12 07:59:01 (define (sub a . c) (if (null? c) a (sub (- a (car c)) (cdr c))) 07:59:23 It's just a simple fold. 07:59:47 no simple fold of - through 1 2 3 4 will give -8? 08:00:19 oh I guess 08:00:32 left fold, ick 08:00:51 and left fold with no identity 08:00:59 meh, whatever :P 08:01:07 *Obfuscate* shrugs. 08:04:24 hkBst [~quassel@79.170.210.174] has joined #scheme 08:04:24 -!- hkBst [~quassel@79.170.210.174] has quit [Changing host] 08:04:24 hkBst [~quassel@gentoo/developer/hkbst] has joined #scheme 08:05:21 -!- phao [~phao@189.107.143.240] has quit [Quit: Leaving] 08:06:14 -!- jonrafkind [~jon@jonr5.dsl.xmission.com] has quit [Ping timeout: 240 seconds] 08:25:12 -!- jao [~user@pdpc/supporter/professional/jao] has quit [Ping timeout: 240 seconds] 08:25:44 -!- bitweiler [~bitweiler@99.40.239.167] has quit [Remote host closed the connection] 08:31:23 d2biG [p@irc.kaer.tk] has joined #scheme 08:33:35 -!- dRbiG [p@irc.kaer.tk] has quit [Ping timeout: 260 seconds] 08:36:06 StephenFalken [email@89-180-154-196.net.novis.pt] has joined #scheme 08:37:03 -!- TR2N [email@2001:470:1f14:135b::2] has quit [Ping timeout: 272 seconds] 08:55:01 pdelgallego [~pdelgalle@1385159852.dhcp.dbnet.dk] has joined #scheme 09:15:48 masm [~masm@2.80.147.25] has joined #scheme 09:16:45 -!- leppie [~lolcow@196-210-162-106.dynamic.isadsl.co.za] has quit [Ping timeout: 260 seconds] 09:45:53 qhe1 [~qhe2@134.134.137.73] has joined #scheme 09:45:58 -!- qhe1 [~qhe2@134.134.137.73] has quit [Client Quit] 09:46:52 MichaelRaskin [~MichaelRa@195.178.216.22] has joined #scheme 09:49:09 HG` [~HG@xdsl-92-252-101-121.dip.osnanet.de] has joined #scheme 09:49:15 -!- qhe [~qhe2@134.134.139.70] has quit [Ping timeout: 272 seconds] 09:56:43 -!- xwl_ [~wixu@nat/nokia/x-uettqajsiqsyowzz] has quit [Ping timeout: 276 seconds] 09:59:54 nowhereman [~pierre@AStrasbourg-551-1-110-125.w90-13.abo.wanadoo.fr] has joined #scheme 10:00:01 -!- nowhere_man [~pierre@AStrasbourg-551-1-30-209.w83-196.abo.wanadoo.fr] has quit [Ping timeout: 272 seconds] 10:16:26 -!- nowhereman [~pierre@AStrasbourg-551-1-110-125.w90-13.abo.wanadoo.fr] has quit [Quit: Konversation terminated!] 10:16:45 nowhereman [~pierre@AStrasbourg-551-1-110-125.w90-13.abo.wanadoo.fr] has joined #scheme 10:26:00 -!- HG` [~HG@xdsl-92-252-101-121.dip.osnanet.de] has quit [Ping timeout: 240 seconds] 10:31:18 HG` [~HG@85.8.71.7] has joined #scheme 10:50:53 -!- vu3rdd [~vu3rdd@fsf/member/vu3rdd] has quit [Remote host closed the connection] 11:01:42 -!- myu2 [~myu2@58x5x224x106.ap58.ftth.ucom.ne.jp] has quit [Remote host closed the connection] 11:02:36 -!- Modius_ [~Modius@cpe-70-123-158-125.austin.res.rr.com] has quit [Quit: "Object-oriented design" is an oxymoron] 11:04:08 myu2 [~myu2@58x5x224x106.ap58.ftth.ucom.ne.jp] has joined #scheme 11:04:21 -!- myu2 [~myu2@58x5x224x106.ap58.ftth.ucom.ne.jp] has quit [Remote host closed the connection] 11:53:52 -!- _danb_ [~user@124-149-166-62.dyn.iinet.net.au] has quit [Read error: Operation timed out] 11:55:34 -!- pygospa [~pygospa@kiel-d9bfd1e5.pool.mediaWays.net] has quit [Ping timeout: 255 seconds] 11:57:22 -!- nilg [~user@77.70.2.229] has quit [Read error: Connection reset by peer] 11:57:35 pygospa [~pygospa@kiel-5f77bc47.pool.mediaWays.net] has joined #scheme 12:15:07 leppie [~lolcow@196-215-83-125.dynamic.isadsl.co.za] has joined #scheme 12:17:31 -!- rien_ [~unkanon@static-71-249-187-201.nycmny.east.verizon.net] has quit [Ping timeout: 240 seconds] 12:17:51 -!- pdelgallego [~pdelgalle@1385159852.dhcp.dbnet.dk] has quit [Ping timeout: 240 seconds] 12:18:55 ventonegro [~alex@200.150.183.81] has joined #scheme 12:32:35 drwho [~drwho@c-76-124-17-190.hsd1.pa.comcast.net] has joined #scheme 12:38:08 jeapostrophe_ [~jay@69.169.141.110.provo.static.broadweavenetworks.net] has joined #scheme 12:43:02 -!- drwho [~drwho@c-76-124-17-190.hsd1.pa.comcast.net] has quit [Ping timeout: 240 seconds] 12:45:16 gravicappa [~gravicapp@ppp85-141-164-206.pppoe.mtu-net.ru] has joined #scheme 12:47:57 carleastlund [~cce@209-6-40-238.c3-0.smr-ubr1.sbo-smr.ma.cable.rcn.com] has joined #scheme 12:48:32 tupi [~david@186.205.37.15] has joined #scheme 12:53:30 pdelgallego [~pdelgalle@1385159852.dhcp.dbnet.dk] has joined #scheme 12:59:34 myu2 [~myu2@v077103.dynamic.ppp.asahi-net.or.jp] has joined #scheme 13:19:52 -!- lewis1711 [~lewis@125-239-255-244.jetstream.xtra.co.nz] has quit [Quit: Leaving.] 13:21:44 nilg [~user@77.70.2.229] has joined #scheme 13:23:18 rien_ [~unkanon@static-71-249-187-201.nycmny.east.verizon.net] has joined #scheme 13:26:02 erjiang [~eric@7.80.244.66.jest.smithvilledigital.net] has joined #scheme 13:38:20 -!- ventonegro [~alex@200.150.183.81] has quit [Quit: ventonegro] 13:38:36 -!- FillIRC is now known as Fill 13:38:45 -!- Fill [~Fill@static.195.170.4.46.clients.your-server.de] has quit [Changing host] 13:38:46 Fill [~Fill@unaffiliated/fill] has joined #scheme 13:39:38 DrDuck [~duck@66-168-225-64.static.mtgm.al.charter.com] has joined #scheme 13:47:29 -!- slk- [~dick@bas2-streetsville39-2925474908.dsl.bell.ca] has quit [Ping timeout: 264 seconds] 13:51:13 unkanon2 [~unkanon@static-71-249-187-201.nycmny.east.verizon.net] has joined #scheme 13:53:19 -!- rien_ [~unkanon@static-71-249-187-201.nycmny.east.verizon.net] has quit [Ping timeout: 276 seconds] 13:55:38 eli: It took me about an hour to make the Chibi VM "auto-forcing" in a space-safe manner. 13:56:34 When compiling with that option, force is the identify function, and it automatically forces operands to non-constructor primitives using a VM trampoline. 13:57:13 -!- unkanon2 [~unkanon@static-71-249-187-201.nycmny.east.verizon.net] has quit [Ping timeout: 276 seconds] 13:58:17 The next step would be to automatically introduce delays as a simple code transformation pass, creating a lazy language. 14:01:04 -!- Nisstyre [~nisstyre@infocalypse-net.info] has quit [Remote host closed the connection] 14:03:08 rien_ [~unkanon@static-71-249-187-201.nycmny.east.verizon.net] has joined #scheme 14:11:23 dskippy1 [~dskippy@209-6-28-198.c3-0.smr-ubr1.sbo-smr.ma.cable.rcn.com] has joined #scheme 14:12:32 -!- dskippy [~dskippy@209-6-46-202.c3-0.smr-ubr1.sbo-smr.ma.cable.rcn.com] has quit [Ping timeout: 250 seconds] 14:18:11 -!- d2biG [p@irc.kaer.tk] has quit [Quit: leaving] 14:22:35 foof: What's the space consumption of (let ([x (make-vector 1000000)] [y (make-vector 1000000)]) (+ 1 2)) 14:22:43 -!- wbooze [~levgue@xdsl-78-35-144-175.netcologne.de] has quit [Read error: Connection reset by peer] 14:22:45 -!- homie [~levgue@xdsl-78-35-144-175.netcologne.de] has quit [Read error: Connection reset by peer] 14:23:53 homie [~levgue@xdsl-78-35-144-41.netcologne.de] has joined #scheme 14:23:56 wbooze [~levgue@xdsl-78-35-144-41.netcologne.de] has joined #scheme 14:30:00 dRbiG [p@irc.kaer.tk] has joined #scheme 14:36:37 -!- gravicappa [~gravicapp@ppp85-141-164-206.pppoe.mtu-net.ru] has quit [Ping timeout: 255 seconds] 14:37:49 -!- copumpkin [~pumpkin@unaffiliated/pumpkingod] has quit [Quit: Computer has gone to sleep.] 14:39:05 eli: I'll assume you mean (delay (make-vector ...)) in the current Chibi since I haven't implemented the lazy language yet, just the auto-forcing, and in that case it doesn't allocate the vectors. 14:39:43 Nor does it allocate the vectors if you write (force (delay (make-vector ...))). 14:39:46 foof: No, I meant just that. 14:40:36 You need to write (vector-ref (delay (make-vector ...)) 0) to cause the VM to force it. 14:40:57 I'm not talking about force/delay at all. 14:41:02 Just that code. 14:41:15 Why? 14:41:24 schmir [~schmir@p54A9074F.dip0.t-ipconnect.de] has joined #scheme 14:41:37 It's a SFS problem in general, which is usually ignored silently, but with a lazy languauge it blows things up much more often. 14:42:06 I'm preparing for a class, but I'll give you a quick case -- do you know the classic fringe problem, and how a lazy language solves it elegantly? 14:42:15 bzzbzz [~franco@modemcable240.34-83-70.mc.videotron.ca] has joined #scheme 14:42:49 eli: I _didn't_ implement a lazy language. I just implemented auto-forcing so that you don't need a lazy primitive to make (delay (force x)) tail-recursive. 14:43:36 Yes, yes, I know -- I'm talking about general SFS-ness (which the `lazy' implementation is very close to too). 14:43:41 I do see how a full lazy language would have a lot more issues. 14:44:52 In the above case, it wouldn't be hard for an optimization pass to remove the make-vector altogether since it's referentially transparent and never referenced. 14:45:02 Exactly -- you often deal with huge lists, and you want something like (equal? l1 l2) to scan the two lists but avoid keeping a pointer to the head of the list, and doing that is something that I doubt can be done in an hour. 14:46:22 -!- jeapostrophe_ [~jay@69.169.141.110.provo.static.broadweavenetworks.net] has quit [Quit: jeapostrophe_] 14:49:10 I think with a precise GC, TCO, and closures which only keep what they need, scanning two lists should just work, but I haven't tried it yet. 14:50:26 foof: IIRCm it's not hard to make it work when you implement the lazy `equal?' in the strict language, but when you do that in the lazy language things go bad. 14:51:31 Well, that's something to try out next time... right now I need to sleep :) 14:51:45 Have fun... 14:51:58 -!- kanru [~kanru@61-30-10-70.static.tfn.net.tw] has quit [Ping timeout: 255 seconds] 14:53:53 -!- schmir [~schmir@p54A9074F.dip0.t-ipconnect.de] has quit [Ping timeout: 272 seconds] 14:55:39 qhe [~qhe2@nat/intel/x-ixtpnhzshtfmsmqo] has joined #scheme 14:55:44 aisa [~aisa@173-10-243-253-Albuquerque.hfc.comcastbusiness.net] has joined #scheme 14:57:20 gravicappa [~gravicapp@ppp85-140-116-134.pppoe.mtu-net.ru] has joined #scheme 15:03:33 copumpkin [~pumpkin@17.101.89.205] has joined #scheme 15:03:34 -!- copumpkin [~pumpkin@17.101.89.205] has quit [Changing host] 15:03:34 copumpkin [~pumpkin@unaffiliated/pumpkingod] has joined #scheme 15:12:59 -!- arbscht [~arbscht@unaffiliated/arbscht] has quit [Ping timeout: 265 seconds] 15:13:16 -!- rien_ [~unkanon@static-71-249-187-201.nycmny.east.verizon.net] has left #scheme 15:14:43 arbscht [~arbscht@unaffiliated/arbscht] has joined #scheme 15:21:05 jeapostrophe_ [~jay@69.169.141.110.provo.static.broadweavenetworks.net] has joined #scheme 15:21:08 -!- jeapostrophe_ [~jay@69.169.141.110.provo.static.broadweavenetworks.net] has quit [Client Quit] 15:22:01 -!- nilg [~user@77.70.2.229] has quit [Remote host closed the connection] 15:24:34 -!- tupi [~david@186.205.37.15] has quit [Quit: Leaving] 15:27:53 -!- carleastlund [~cce@209-6-40-238.c3-0.smr-ubr1.sbo-smr.ma.cable.rcn.com] has quit [Quit: carleastlund] 15:28:24 kanru [~kanru@114-45-237-190.dynamic.hinet.net] has joined #scheme 15:32:02 nilg [~user@77.70.2.229] has joined #scheme 15:36:31 -!- samth_away is now known as samth 15:36:54 rien_ [~rien_@static-71-249-187-201.nycmny.east.verizon.net] has joined #scheme 15:39:47 femtoo [~femto@95-89-196-149-dynip.superkabel.de] has joined #scheme 15:43:18 -!- araujo [~araujo@gentoo/developer/araujo] has quit [Read error: Connection reset by peer] 15:44:12 -!- nilg [~user@77.70.2.229] has quit [Remote host closed the connection] 15:44:23 araujo [~araujo@gentoo/developer/araujo] has joined #scheme 15:44:57 nilg` [~user@77.70.2.229] has joined #scheme 15:47:07 langmartin [~user@host-68-169-155-216.WISOLT2.epbfi.com] has joined #scheme 15:50:25 bweaver [~user@host-68-169-175-225.WISOLT2.epbfi.com] has joined #scheme 15:52:04 bitweiler [~bitweiler@99.40.239.167] has joined #scheme 16:03:53 -!- araujo [~araujo@gentoo/developer/araujo] has quit [Read error: Connection reset by peer] 16:04:59 araujo [~araujo@gentoo/developer/araujo] has joined #scheme 16:13:57 jeapostrophe_ [~jay@lallab.cs.byu.edu] has joined #scheme 16:20:36 zanes [~zane@adsl-216-103-252-124.dsl.snfc21.pacbell.net] has joined #scheme 16:21:18 -!- zanes [~zane@adsl-216-103-252-124.dsl.snfc21.pacbell.net] has left #scheme 16:22:41 is interval arithmetic useful in programming? 16:27:43 as opposed to homework problems? :-} 16:28:43 -!- jeapostrophe_ [~jay@lallab.cs.byu.edu] has quit [Quit: jeapostrophe_] 16:29:41 carleastlund [~cce@gotham.ccs.neu.edu] has joined #scheme 16:30:35 offby1: I am not in school, I learning to program with self-study 16:34:47 i was just wondering since alot of SCIP and other programming sites talk about it alot 16:36:19 tupi [~david@186.205.37.15] has joined #scheme 16:38:34 -!- MichaelRaskin [~MichaelRa@195.178.216.22] has quit [Ping timeout: 250 seconds] 16:41:33 I've never used interval arithmetic for a paying job 16:42:14 -!- didi` [~user@unaffiliated/didi/x-1022147] has quit [Ping timeout: 240 seconds] 16:45:22 okay nice to know :) 16:51:31 drdo [~user@91.205.108.93.rev.vodafone.pt] has joined #scheme 16:57:00 apgwoz [~apgwoz@160.79.2.194] has joined #scheme 16:58:55 corruptmemory [~jim@ool-18bbd5b2.static.optonline.net] has joined #scheme 17:00:47 -!- langmartin [~user@host-68-169-155-216.WISOLT2.epbfi.com] has quit [Ping timeout: 240 seconds] 17:01:29 -!- femtoo [~femto@95-89-196-149-dynip.superkabel.de] has quit [Read error: Connection reset by peer] 17:03:52 -!- hkBst [~quassel@gentoo/developer/hkbst] has quit [Remote host closed the connection] 17:04:25 langmartin [~user@host-68-169-155-216.WISOLT2.epbfi.com] has joined #scheme 17:17:35 rgrau [~user@62.Red-88-2-20.staticIP.rima-tde.net] has joined #scheme 17:20:20 dfkjjkfd [~paulh@188-9-ftth.onsnetstudenten.nl] has joined #scheme 17:25:09 simontwo [~simon@78.129.201.122] has joined #scheme 17:26:24 I realized that the former DrScheme (now DrRacket) supports a bunch of languages for educational purposes. I'm trying to hook it up with another interpreter than Scheme using the #lang line. syntax highlighting works fine, but it doesn't guess the location of my interpreter. 17:27:04 No idea. I had the impression the languages were integrated into the environemnt... 17:27:47 -!- kanru [~kanru@114-45-237-190.dynamic.hinet.net] has quit [Ping timeout: 272 seconds] 17:27:47 so you're saying that DrRacket comes with interpreters/compilers for all the languages it supports? I don't think so, but maybe. 17:33:25 That's what I'd expect, but I may be wrong. 17:35:24 -!- githogori [~githogori@adsl-66-123-22-146.dsl.snfc21.pacbell.net] has quit [Read error: Connection reset by peer] 17:39:55 -!- REPLeffect [~REPLeffec@69.54.115.254] has quit [Ping timeout: 265 seconds] 17:39:57 simontwo, drracket does indeed come with compilers for all of those languages 17:40:18 usually, the languages compile into some other language implemented by Racket 17:40:58 simontwo, for building a new language in Racket, start here: http://docs.racket-lang.org/guide/languages.html 17:41:32 REPLeffect [~REPLeffec@69.54.115.254] has joined #scheme 17:51:20 jeapostrophe_ [~jay@lallab.cs.byu.edu] has joined #scheme 17:53:27 bitweiler: Interval arithmetic is useful for rigorously modelling floating-point numerical inaccuracies. 17:54:15 bitweiler: When I first heard of that particular application of interval arithmetic, lights went off in my head, and I was like, "so _that_'s what it's for!". :-P 17:56:29 they went off? 17:57:11 oh right, that's the expression :) 17:58:07 Yeah, English is funny like that. :-P 17:59:07 phao [~phao@189.107.192.50] has joined #scheme 17:59:54 jcowan [~John@cpe-74-68-112-189.nyc.res.rr.com] has joined #scheme 18:00:11 coi 18:00:54 you're gonna break your arm 18:01:01 (o( 18:01:02 )o) 18:01:15 I've already got a broken foot, isn't that enough? 18:01:37 0<-<. <--- your broken foot 18:01:43 0<-<; <--- your broken foot 18:01:49 O_o 18:02:00 Why the violence? 18:02:00 that's a full stick figure 18:02:20 cky: okay thanks ;) 18:02:26 -!- jeapostrophe_ [~jay@lallab.cs.byu.edu] has quit [Quit: jeapostrophe_] 18:02:31 cky --> o, <-<___ 18:02:41 rien_: That's terrible!! 18:02:58 you're all deformed and maimed 18:03:20 rien_: You Have Died of Dysentery. 18:03:26 Anyway. Enough of that. 18:03:33 I had three broken toes; one has healed, one is healing, and the other has two fractures, one of which has healed but the other not yet. 18:03:52 you play sports or something? 18:05:21 Nope, just trying to squeeze a swollen foot into a Croc. 18:05:32 jonrafkind [~jon@crystalis.cs.utah.edu] has joined #scheme 18:05:59 Ca-runccch. 18:06:17 I didn't even feel it; my podiatrist was suspicious and took an X-ray. 18:06:40 one more reason to hate crocs 18:09:16 timepilot [~timepilot@66.71.230.245] has joined #scheme 18:10:53 -!- eno [~eno@nslu2-linux/eno] has quit [Ping timeout: 264 seconds] 18:12:35 eno [~eno@nslu2-linux/eno] has joined #scheme 18:14:23 For diabetics they're great. 18:14:51 *nods* 18:16:27 Ouch, broken toes aren't fun. 18:16:57 Wearing The Boot is what's not fun; fortunately, the toes don't hurt at all (diabetic neuropathy) 18:27:30 I believe I have neuropathy in my legs as they're always tingling, and sometimes my toes, but blood tests said it couldn't be diabetes 18:29:28 -!- nilg` [~user@77.70.2.229] has quit [Read error: Connection reset by peer] 18:30:32 erjiang_ [~erjiang@2001:18e8:2:244:213:72ff:fe81:70af] has joined #scheme 18:30:36 -!- erjiang_ [~erjiang@2001:18e8:2:244:213:72ff:fe81:70af] has quit [Read error: Connection reset by peer] 18:31:15 erjiang_ [~erjiang@2001:18e8:2:244:213:72ff:fe81:70af] has joined #scheme 18:31:25 femtoo [~femto@95-89-196-149-dynip.superkabel.de] has joined #scheme 18:34:39 -!- phao [~phao@189.107.192.50] has quit [Quit: Leaving] 18:42:03 jcowan: My father in law has that problem. He's always fracturing his feet. 18:42:14 githogori [~githogori@247.sub-75-208-73.myvzw.com] has joined #scheme 18:42:15 Hopefully I won't have it happen any more. 18:43:07 -!- Jafet [~Jafet@unaffiliated/jafet] has quit [Ping timeout: 240 seconds] 18:57:28 daedra [~simon@unaffiliated/daedra] has joined #scheme 19:04:25 just incase anyone was curious, here's the polynomial calculator I was working on http://paste.lisp.org/display/118544 19:05:02 MichaelRaskin [~MichaelRa@195.91.224.225] has joined #scheme 19:05:07 it's in clisp but I've not used any lisp-specific functions really 19:11:10 didi [~user@unaffiliated/didi/x-1022147] has joined #scheme 19:15:26 -!- erjiang_ [~erjiang@2001:18e8:2:244:213:72ff:fe81:70af] has quit [Quit: ttfn] 19:24:19 -!- pdelgallego [~pdelgalle@1385159852.dhcp.dbnet.dk] has quit [Ping timeout: 272 seconds] 19:25:25 schmir [~schmir@p54A911C4.dip0.t-ipconnect.de] has joined #scheme 19:34:17 mithos28 [~eric@cpe-67-247-75-32.rochester.res.rr.com] has joined #scheme 19:35:24 actually not in clisp. evidently I've used non CL stuff and have caused a flamefest in ##lisp. Oh dear 19:35:31 that totally wasn't the point 19:36:33 jao [~user@pdpc/supporter/professional/jao] has joined #scheme 19:37:38 didi` [~user@unaffiliated/didi/x-1022147] has joined #scheme 19:39:02 -!- didi [~user@unaffiliated/didi/x-1022147] has quit [Ping timeout: 240 seconds] 19:39:13 Does anyone know any linear-time algorithms that would find all mutated (set!) variables and corresponding variable references in a s-expression? 19:40:16 mithos28, you'd have to first expand the program 19:40:39 allready done 19:42:55 I know how to find if a variable is mutated in a given expression, and then go through that expression and find all the references but If I do this for every binding it will take exponential time 19:43:50 -!- schmir [~schmir@p54A911C4.dip0.t-ipconnect.de] has quit [Remote host closed the connection] 19:59:21 pdelgallego [~pdelgalle@1385159852.dhcp.dbnet.dk] has joined #scheme 20:00:11 -!- timepilot [~timepilot@66.71.230.245] has quit [Quit: timepilot] 20:00:39 -!- daedra [~simon@unaffiliated/daedra] has left #scheme 20:02:23 femtooo [~femto@95-89-196-149-dynip.superkabel.de] has joined #scheme 20:03:25 jeapostrophe_ [~jay@lallab.cs.byu.edu] has joined #scheme 20:03:49 -!- didi` [~user@unaffiliated/didi/x-1022147] has quit [Ping timeout: 255 seconds] 20:05:26 -!- femtoo [~femto@95-89-196-149-dynip.superkabel.de] has quit [Ping timeout: 240 seconds] 20:18:16 -!- femtooo [~femto@95-89-196-149-dynip.superkabel.de] has quit [Read error: Connection reset by peer] 20:27:38 mithos28: You can do it in quadratic time by keeping a stack of all in-scope variables, then find every reference and set! to each. When a variable is about to go out of scope, see if it was mutated or not; if so, keep it, if not, discard it. 20:30:27 WonTu [~WonTu@p57B52FA5.dip.t-dialin.net] has joined #scheme 20:30:41 -!- WonTu [~WonTu@p57B52FA5.dip.t-dialin.net] has left #scheme 20:31:15 jcowan: I think you are using the same algorithm that I was thinking was exponential, and I think that you are right in that it is only quadratic 20:32:47 You can do better by using a hashtable as well as a list of in-scope variables, and removing them from the hashtable when they go out of scope. 20:33:11 That should be linear. 20:37:46 Thanks. 20:38:33 sanduz2 [~sanduz2@75-149-186-118-Miami.hfc.comcastbusiness.net] has joined #scheme 20:39:58 -!- jonrafkind [~jon@crystalis.cs.utah.edu] has quit [*.net *.split] 20:39:58 -!- araujo [~araujo@gentoo/developer/araujo] has quit [*.net *.split] 20:39:58 -!- pothos [~pothos@111-240-165-86.dynamic.hinet.net] has quit [*.net *.split] 20:39:59 -!- futilius [~otheruser@2001:470:d:128:216:3eff:fe86:c70e] has quit [*.net *.split] 20:39:59 -!- snappy [~naveen@unaffiliated/snappy] has quit [*.net *.split] 20:39:59 -!- C-Keen [ckeen@pestilenz.org] has quit [*.net *.split] 20:39:59 -!- levi [~user@c-174-52-219-147.hsd1.ut.comcast.net] has quit [*.net *.split] 20:39:59 -!- askhader [~askhader@taurine.csclub.uwaterloo.ca] has quit [*.net *.split] 20:39:59 -!- Zahl [~kenneth@lnx101.hrz.tu-darmstadt.de] has quit [*.net *.split] 20:39:59 -!- Tasser [~freak@subtle/contributor/Tass] has quit [*.net *.split] 20:40:00 -!- XTL [~t6haha00@2001:708:510:33::deca] has quit [*.net *.split] 20:40:00 -!- elly [~elly@atheme/member/elly] has quit [*.net *.split] 20:40:00 -!- mornfall [~mornfall@kde/developer/mornfall] has quit [*.net *.split] 20:41:16 pothos [~pothos@111-240-165-86.dynamic.hinet.net] has joined #scheme 20:42:50 jonrafkind [~jon@crystalis.cs.utah.edu] has joined #scheme 20:42:50 araujo [~araujo@gentoo/developer/araujo] has joined #scheme 20:42:50 levi [~user@c-174-52-219-147.hsd1.ut.comcast.net] has joined #scheme 20:42:50 futilius [~otheruser@2001:470:d:128:216:3eff:fe86:c70e] has joined #scheme 20:42:50 snappy [~naveen@unaffiliated/snappy] has joined #scheme 20:42:50 C-Keen [ckeen@pestilenz.org] has joined #scheme 20:42:50 askhader [~askhader@taurine.csclub.uwaterloo.ca] has joined #scheme 20:42:50 Zahl [~kenneth@lnx101.hrz.tu-darmstadt.de] has joined #scheme 20:42:50 Tasser [~freak@subtle/contributor/Tass] has joined #scheme 20:42:50 XTL [~t6haha00@2001:708:510:33::deca] has joined #scheme 20:42:50 elly [~elly@atheme/member/elly] has joined #scheme 20:42:50 mornfall [~mornfall@kde/developer/mornfall] has joined #scheme 20:43:44 -!- jonrafkind [~jon@crystalis.cs.utah.edu] has quit [Read error: Connection reset by peer] 20:45:35 ive been programming for one year and i started reading SICP recently, did any of you guys find the exercises difficult? im wondering if its just me heh 20:45:55 sanduz2: i did 20:46:13 sanduz2: but I'm in the same boat as you, hehe 20:47:15 -!- mithos28 [~eric@cpe-67-247-75-32.rochester.res.rr.com] has left #scheme 20:47:32 what would be the point of easy exercises, exercises that anyone could solve in 5 mins? 20:47:51 s/easy/straightforward 20:48:04 that was the fun part, figure out how to solve them 20:48:26 oh ok thanks :) i was just wondering if i was an idiot 20:48:50 i usually find exercises easy in any other subject 20:50:01 nah, just don't worry about that 20:51:24 thanks 20:59:49 -!- antoszka [~antoszka@unaffiliated/antoszka] has quit [Quit: +++ killed by SIGSEGV +++] 21:01:26 jonrafkind [~jon@crystalis.cs.utah.edu] has joined #scheme 21:03:33 phao [~phao@189.107.129.85] has joined #scheme 21:11:09 j-invariant [~aaaa@unaffiliated/j-invariant] has joined #scheme 21:11:16 how do I write a program in racket that uses multiple files? 21:12:20 -!- MichaelRaskin [~MichaelRa@195.91.224.225] has quit [Remote host closed the connection] 21:12:56 Files of code or or data? 21:13:15 yes source code 21:13:40 what is the primitive for checking if something is a procedure? 21:15:45 MichaelRaskin [~MichaelRa@195.91.224.225] has joined #scheme 21:17:29 just type its name 21:17:35 rudybot: car 21:17:35 rien_: To represent a pair in Scheme48, given a representation for (i.e., given a machine word describing) its car and one for its cdr, one must find three contiguous locations for words in memory. The first location stores a header word, which has some type information saying that the object is a pair (and a tag 01 or 10, I forget which); the second stores the word representing the pair's car; and the third stores the that for its 21:17:42 incubot: car 21:18:01 oh you mean in a program... 21:18:13 incubot: (procedure? car) 21:18:14 #t 21:18:21 incubot: (procedure? 3) 21:18:22 #f 21:18:30 phao: ^ 21:23:34 http://paste.lisp.org/display/118547 21:23:42 Is there a nice way to implement this? My code is terribl 21:23:56 kilimanjaro [~kilimanja@unaffiliated/kilimanjaro] has joined #scheme 21:26:41 thx 21:30:44 j-invariant: I have _some_ way to implement it, it just isn't nice. :-P 21:32:11 Nisstyre [~nisstyre@infocalypse-net.info] has joined #scheme 21:32:48 antoszka [~antoszka@unaffiliated/antoszka] has joined #scheme 21:32:56 TheRebutler [~TheRebutl@cpe-76-175-192-194.socal.res.rr.com] has joined #scheme 21:35:25 It's funny to see how many functions can be implemented as car, cdr and cons 21:42:06 most list functions (if not all) 21:42:30 I was always amused by the definition of the procedure "list" 21:44:18 what is it? 21:44:28 <_p4bl0> (define (list . args) args) ? :-p 21:44:29 (define list (lambda x x)) 21:44:33 yes 21:44:37 what witchery is this 21:44:55 heh makes sense 21:46:54 <_p4bl0> MapMan: no witchery, see http://docs.racket-lang.org/reference/lambda.html (what's interresting are the kw-formals forms) 21:47:12 It's because variadic procedures deliver the values of their actual arguments *as a list*. It's the only point where the syntax of Scheme, intersects with the datatypes of Scheme. 21:47:28 _p4bl0: I was joking :P 21:47:39 <_p4bl0> MapMan: ah okay :-) 21:47:42 also, im shocked and appaled that theres more people in here than in prolog 21:48:07 <_p4bl0> MapMan: haha it make sens to me 21:48:58 is that how to design programs book good? 21:49:31 <_p4bl0> phao: didn't read it myself, but I've only heard good review of it 21:51:43 ok 21:52:42 phao: what kind of book are you looking for? 21:53:03 books on scheme, using scheme, stuff like that 21:53:24 it is such a book. 21:53:32 hehehe 21:53:40 I quite enjoyed The Little Schemer (and The Seasoned Schemer). 21:54:05 cky: is the little schemer too basic for someone who is already familiar with functional programming? 21:54:22 rien_: Only if you consider continuations and the Y-combinator to be too basic. 21:54:45 cky, I'm in the last 10 pages of the little schemer 21:54:50 moving to the seasoned after. 21:55:00 honestly, I lied little schemer more than SICP 21:55:25 I can brush up on my continuations, and I don't really know what the y-combinator is 21:55:32 btw... is racket the same as dr. scheme?? 21:55:38 yes 21:55:44 they changed names 21:55:58 right 21:56:01 thx 21:56:24 <_p4bl0> what does "the reasoned schemer" talk about? The book's page do'nt say much 21:56:51 _p4bl0: I don't have that book, but I understand it to be, basically, Prolog-like language for Scheme. 21:57:01 Someone who has read that book should correct me. 21:57:19 <_p4bl0> cky: thanks 21:58:10 yeah that's what it seems like from looking at amazon's reviews 22:04:01 -!- jeapostrophe_ [~jay@lallab.cs.byu.edu] has quit [Quit: jeapostrophe_] 22:16:47 -!- githogori [~githogori@247.sub-75-208-73.myvzw.com] has quit [Ping timeout: 240 seconds] 22:17:23 here's the website for the scheme logic system: http://kanren.sourceforge.net/ 22:18:30 <_p4bl0> erjiang: there's also racket's racklog language :-) 22:26:59 -!- Nisstyre [~nisstyre@infocalypse-net.info] has quit [Remote host closed the connection] 22:27:07 -!- langmartin [~user@host-68-169-155-216.WISOLT2.epbfi.com] has quit [Quit: ERC Version 5.3 (IRC client for Emacs)] 22:28:31 Nisstyre [~nisstyre@infocalypse-net.info] has joined #scheme 22:29:15 githogori [~githogori@44.sub-75-210-234.myvzw.com] has joined #scheme 22:33:44 -!- sbrtgr [~user@174-30-215-125.mpls.qwest.net] has quit [Quit: Lost terminal] 22:34:46 -!- MichaelRaskin [~MichaelRa@195.91.224.225] has quit [Remote host closed the connection] 22:37:26 sbrtgr [~user@174-30-215-125.mpls.qwest.net] has joined #scheme 22:39:32 -!- samth is now known as samth_away 22:46:57 jeapostrophe_ [~jay@lallab.cs.byu.edu] has joined #scheme 22:47:04 -!- jeapostrophe_ [~jay@lallab.cs.byu.edu] has quit [Client Quit] 22:52:08 -!- aisa [~aisa@173-10-243-253-Albuquerque.hfc.comcastbusiness.net] has quit [Quit: aisa] 22:52:34 -!- aoh [~aki@80.75.102.51] has quit [Ping timeout: 255 seconds] 22:54:34 aoh [~aki@80.75.102.51] has joined #scheme 23:08:34 -!- DrDuck [~duck@66-168-225-64.static.mtgm.al.charter.com] has quit [Ping timeout: 250 seconds] 23:17:52 what's everybody's opinions on implementing let natively vs as a macro 23:18:22 you probably miss opportunities for optimization if its a macro 23:18:29 Well, you gain others. 23:18:48 The classical theory of Scheme compilation is to reduce everything to just a few constructs and then to be very smart about those. 23:18:54 where "a few" means about seven or eight. 23:19:27 of course its nice to have a small compiler but that does mean you will have the most optimal program by only dealing with those forms? 23:19:39 jcowan: what would you gain if it wasn't? 23:19:55 after you've done all possible optimizations for the core forms, you can work on optimizing higher level ones 23:20:24 Well, consider "do", which is a loop. The general strategy is to expand "do" to tail recursion, and then optimize tail recursion. The good bit here is that if you express your loop directly through tail recursion, you get the same optimizations. 23:20:53 oh, I guess if you implement let as a macro and then optimize the case of ((lambda ...) ...), it ends up being the same thing anyways 23:20:58 Just so. 23:21:10 But it works whether you write "let" or not. 23:21:44 or you could optimize that into a let in the macro expander 23:21:50 it seems like the same amount of work either way 23:26:20 Yes, that strategy is also possible. But in general you have a fixed amount of (human and machine) resources to spend on optimizing, and optimizing the few more deeply seems to give better results than optimizing the many more shallowly. 23:26:41 lewis1711 [~lewis@125-239-255-244.jetstream.xtra.co.nz] has joined #scheme 23:30:33 -!- HG` [~HG@85.8.71.7] has quit [Quit: Leaving.] 23:31:55 -!- bweaver [~user@host-68-169-175-225.WISOLT2.epbfi.com] has quit [Quit: ERC Version 5.3 (IRC client for Emacs)] 23:38:42 (define cc (call/cc (lambda (cc) cc))) (cc 20) (display cc) 23:38:49 this should cause an error, right? 23:39:58 -!- dfkjjkfd [~paulh@188-9-ftth.onsnetstudenten.nl] has quit [Quit: Lost terminal] 23:39:59 rudybot: (define cc (call/cc (lambda (cc) cc))) (cc 20) (display cc)) 23:39:59 jonrafkind: ((call/cc call/cc) (call/cc call/cc)) 23:40:05 i guess not 23:40:44 actually wtf 23:40:53 rudybot: (begin (define cc (call/cc (lambda (cc) cc))) (cc 20) (display cc))) 23:40:54 jonrafkind: There is a question of evaluation order, though. If they were evaluated, should they all be evaluated to begin with, or should each one only be evaluated as necessary? In other words, do you skip the rest after hitting a match? Quoting makes writing the macro easier because you don't have to worry about that. 23:40:58 rudybot: eval (begin (define cc (call/cc (lambda (cc) cc))) (cc 20) (display cc))) 23:40:59 jonrafkind: your sandbox is ready 23:40:59 jonrafkind: error: eval:1:67: read: unexpected `)' 23:41:05 rudybot: eval (begin (define cc (call/cc (lambda (cc) cc))) (cc 20) (display cc) 23:41:06 jonrafkind: error: eval:1:0: read: expected a `)' to close `(' 23:41:09 rudybot: eval (begin (define cc (call/cc (lambda (cc) cc))) (cc 20) (display cc)) 23:41:09 jonrafkind: ; stdout: "20" 23:42:09 If you wrap them in a begin-block, *then* you get an error. 23:42:17 "20 is not a procedure" or the like. 23:42:17 -!- _p4bl0 [~user@berthold.shebang.ws] has quit [Read error: Connection reset by peer] 23:42:25 _p4bl0 [~user@berthold.shebang.ws] has joined #scheme 23:43:02 yes 23:43:05 that's the error I was expecting 23:43:11 a guy told me, yesterday 23:43:35 that the error doesn't happen because of something related to that being runned in the top level 23:43:46 yea, pretty strange 23:44:55 The point is that when you run something from the REPL, its continuation is somewhere in the REPL. 23:44:59 And that's what you've captured. 23:46:00 continuations, gotta catch 'em all 23:49:15 lewis1711 is a giant Gordian continuation. 23:51:20 -!- carleastlund [~cce@gotham.ccs.neu.edu] has quit [Quit: carleastlund] 23:51:55 *foof* is a moebius string-strip 23:52:12 Twisty! 23:53:04 I don't have the 10 minutes it takes to launch Windows in VMware, can someone confirm that Windows transparently supports both / and \ as directory separators? 23:53:12 Yes. 23:53:31 Apparently pkzip (back in those days) extracts files with / instead of \. 23:54:07 OK, now does Java recognize these and translate \ to / on Unix, or does it just copy the platform so that \ is unportable? 23:54:21 I think it sends it directly. 23:54:29 So \ is not portable. 23:54:34 -!- j-invariant [~aaaa@unaffiliated/j-invariant] has quit [Quit: leaving] 23:55:11 So from a language standard perspective, it doesn't make sense to support \. 23:55:30 Right, if all you do is pass through to the OS. 23:55:40 But if you need to _parse_ filenames, that's a different story. 23:55:52 <_p4bl0> \ as directory separator is evil. Also, the PHP guys who decided to use it as namespace separator are dumb or evil, too. I need to repeat that from time to time. 23:56:02 _p4bl0: :-P 23:56:17 The PHP guys are dumb or evil regardless. 23:56:25 yeah, like insulting PHP on #scheme is so brave ;) 23:56:40 It's like shooting fish in a barrel. :-P 23:57:05 dont forget php recently added 'goto' 23:57:26 Heh. If they added call/cc, then I'd call them progressive. But nooooo..... 23:57:34 <_p4bl0> bremner: foof: I like PHP 23:57:43 _p4bl0: O_o 23:58:09 foof: The Windows *kernel* transparently supports / and \. 23:58:16 Windows *tools*, notably CMD.EXE, do not. 23:58:28 <_p4bl0> not from a theoretical perspective of course, but it's quite handy for quick web dev and does the job pretty well. 23:58:31 jcowan: Right, but from a Scheme library point of view, the tools are irrelevant, right? 23:58:41 Unless you are building Chicken. 23:58:42 jcowan: It's what the OS does that matters, surely? 23:58:46 Oh, hmm. 23:59:23 Java provides a global variable that says what the local separator is, more for parsing than for constructing paths.