00:17 (quit) bro_grammer: Ping timeout: 260 seconds
00:17 (quit) axe_wielder: Ping timeout: 260 seconds
00:17 (quit) jrslepak: Quit: What happened to Systems A through E?
00:57 (quit) jacius: Quit: Leaving
00:58 (quit) jeapostrophe: Ping timeout: 246 seconds
01:09 (join) dented42
01:12 (quit) jao: Ping timeout: 260 seconds
01:45 (quit) stchang: Read error: Operation timed out
01:47 (join) stchang
02:08 (join) kreol[Ukr]
02:16 (quit) lebro: Read error: Connection reset by peer
02:24 (quit) kreol[Ukr]: Ping timeout: 246 seconds
02:44 (join) kreol[Ukr]
02:52 (quit) antithesis: Quit: Yes leaving
02:53 (join) antithesis
03:00 (quit) jonrafkind: Ping timeout: 265 seconds
03:06 (join) __rahul__
03:35 (quit) Kaylin: Quit: Leaving.
03:38 (join) Kaylin
03:49 (join) cdidd
04:20 (join) wahjava
04:29 (join) ivan\
04:37 (join) dzhus
04:49 jyc: so is the primary use for begin grouping things?
04:50 jyc: the 'begin' expression*
04:51 (quit) antithesis: Quit: Yes leaving
05:13 (join) molbdnilo
05:14 (quit) jyc: Read error: Connection reset by peer
05:19 (join) Dennis-
05:19 (quit) Croms: Read error: Connection reset by peer
05:22 (join) bitonic
05:30 (join) mceier
05:33 (quit) sstrickl: Quit: sstrickl
05:36 (quit) Kaylin: Quit: Leaving.
05:37 (join) Kaylin
05:45 (join) masm
06:17 (quit) molbdnilo: Quit: molbdnilo
06:53 (join) antithesis
06:57 (join) nilyaK
07:06 (join) bluezenix
07:20 (join) jesyspa
07:37 (quit) Kaylin: Quit: Leaving.
07:42 (quit) nilyaK: Quit: Leaving.
07:44 (quit) bitonic: Quit: WeeChat 0.3.7
07:53 (quit) dzhus: *.net *.split
07:53 (quit) sizz_: *.net *.split
07:53 (quit) bro_down: *.net *.split
07:53 (quit) Guest7666: *.net *.split
07:53 (quit) bremner: *.net *.split
07:53 (quit) jrslepak_neu: *.net *.split
07:53 (join) bremner
07:53 (join) sizz
07:53 (join) cipher
07:53 (join) bro_down
07:54 (nick) cipher -> Guest38569
07:55 (join) Shvillr_
07:55 (quit) Shviller: Disconnected by services
07:55 (nick) Shvillr_ -> Shviller
07:56 (quit) karswell: Read error: Connection reset by peer
07:57 (quit) Shvillr: Ping timeout: 246 seconds
08:05 (join) getpwnam
08:06 (quit) __rahul__: Quit: Leaving
08:06 (join) hash_table
08:07 (join) karswell
08:11 (join) netrino
08:16 (join) 16SAA9X76
08:16 (join) dzhus
08:16 (join) jrslepak_neu
08:22 (quit) karswell: Read error: Operation timed out
08:28 (join) karswell
08:39 (quit) kreol[Ukr]: Ping timeout: 246 seconds
08:43 (join) anRch
09:42 (join) jrslepak
09:48 (join) vu3rdd
09:48 (quit) vu3rdd: Changing host
09:48 (join) vu3rdd
10:06 (join) MayDaniel
10:07 (join) bluezenix1
10:09 (quit) anRch: Read error: Connection reset by peer
10:09 (join) anRch
10:10 (quit) bluezenix: Ping timeout: 244 seconds
10:17 (quit) anRch: Quit: anRch
10:24 (quit) MayDaniel: Ping timeout: 246 seconds
11:00 (quit) bluezenix1: Quit: Leaving.
11:07 (join) RacketCommitBot
11:07 RacketCommitBot: [racket] plt pushed 2 new commits to master: http://git.io/amDCIA
11:07 RacketCommitBot: [racket/master] racket/draw: background and text colors in `record-dc%' - Matthew Flatt
11:07 RacketCommitBot: [racket/master] more error-message conversion - Matthew Flatt
11:07 (part) RacketCommitBot
11:29 (join) netrino_
11:29 (join) Fare
11:30 (quit) ssbr: Ping timeout: 246 seconds
11:31 (quit) netrino: Ping timeout: 244 seconds
11:36 (join) bluezenix
11:39 netrino_: Hi. Have a question. Does vector-drop on immutable vector creates new vector or just return a slice of an old vector?
11:39 offby1: netrino_: ideally, there's no way to tell those two cases apart :)
11:42 netrino_: offby1: =(
11:43 netrino_: looks like it create a new vector. a bit silly, what the benefit of immutable-vector then?
11:49 chandler: The same as the benefit of an immutable anything else - that you can depend on it not being mutated.
11:50 (join) ssbr
11:50 asumu: netrino_: maybe you're talking about persistent data structures rather than immutable ones?
11:52 offby1: netrino_: how can you tell that it's creating a new vector?
11:52 netrino_: chandler: well, yes. but immutability guaranty gives us a possibility to perform some optimizations.
11:53 netrino_: asumu: does they really differs in that context?
11:54 asumu: Yes. Immutable data structures are not necessarily persistent.
11:54 netrino_: offby1: documentations states that vector-drop returns a 'fresh' vector
11:54 asumu: Racket's vectors, for example, are not persistent.
11:54 asumu: Clojure's are. They're both immutable though.
11:56 netrino_: asumu: so racket immutable vectors can be changes after creation?
11:57 asumu: No, they cannot.
11:58 asumu: I'm saying the optimizations you want sounds like what you get from persistent data structures.
12:01 netrino_: asumu: what lacks immutable vectors that forbids that kind of optimization? And what the difference between immutable and persistent which gaves only for persistent data structures those optimizations?
12:02 bremner: persistent and immutable are completely orthogonal (independent) concepts afaiu
12:06 netrino_: it seems that i'm really don't understand those terms. can someone explain me, please?
12:08 friscosam: immutable means you cannot change it. I can't remember a proper definition of persistent, but I know it when I see it.
12:09 friscosam: netrino_: http://en.wikipedia.org/wiki/Persistent_data_structure
12:09 (join) jeapostrophe
12:09 (quit) jeapostrophe: Changing host
12:09 (join) jeapostrophe
12:10 netrino_: friscosam: reading that right now. it seems, that any immutable is persistent, but not all of persistent are immutable
12:11 friscosam: other way around
12:12 (join) __rahul__
12:14 bremner: well, immutable datastructures are trivially persistent, if you want to push things. but not in a useful way
12:14 friscosam: true :D
12:15 bremner: and I'm pretty sure one can have persistent data structures that are not immutable; the original ones were not by FP people.
12:16 bremner: i.e. with fat-nodes, updating pointers to add on new information.
12:18 (join) bitonic
12:22 (join) sstrickl
12:42 (join) snearch
12:46 (quit) sizz: Read error: Connection reset by peer
12:46 (join) sizz
12:49 (quit) bluezenix: Quit: Leaving.
12:49 (join) jonrafkind
13:00 (quit) vu3rdd: Quit: ERC Version 5.3 (IRC client for Emacs)
13:01 (quit) jeapostrophe: Ping timeout: 246 seconds
13:19 (join) bluezenix
13:25 (join) zyoung
13:45 (quit) bluezenix: Quit: Leaving.
13:55 (join) rahul_
14:21 (quit) bitonic: Ping timeout: 246 seconds
14:22 (join) bluezenix
14:34 (join) bitonic
14:35 (join) jyc
15:01 (quit) rahul_: Ping timeout: 244 seconds
15:01 (quit) __rahul__: Ping timeout: 240 seconds
15:06 (quit) dsantiago: Quit: Computer has gone to sleep.
15:11 (join) sindoc
15:14 (join) sindoc1
15:15 (quit) sindoc: Ping timeout: 244 seconds
15:17 (quit) Fare: Ping timeout: 252 seconds
15:17 (nick) hyko- -> hyko
15:28 Shambles_: There seems to be 3 different ways of writing macros in Racket, syntax-rules, syntax-case, and syntax-parse. I'm trying to understand 'the point' in them. It looks like syntax-case lets you evaluate arbitrary code, and syntax-rules doesn't. I haven't figured out what syntax-parse does specially, though perhaps it's better error messages. Can someone explain?
15:32 jonrafkind: if you want to determine that a pattern variable matches an identifier in syntax-case you must do (if (identifier? #'x) ...) in the body of the syntax-case, but in syntax-parse you can write x:id in the pattern itself
15:32 jonrafkind: syntax-parse is thus more declarative than syntax-case
15:39 (quit) snearch: Quit: Verlassend
15:48 (join) rahul_
15:48 (join) __rahul__
15:56 Shambles_: jonrafkind: Was the difference between syntax-rules and syntax-case what I thought it was?
16:01 Guest4858: Is there an xexpr for something like "" ?
16:02 Shambles_: Guest4858: http://docs.racket-lang.org/xml/index.html search for "comment" should see it near the top of the page.
16:03 Shambles_: Guest4858: There is also make-comment http://lists.racket-lang.org/users/archive/2003-August/003286.html
16:06 (quit) sindoc1: Quit: Leaving.
16:08 (join) sindoc
16:08 (join) untrusted
16:09 Guest4858: Shambles_: unfortunately that doesn't work.
16:09 Guest4858: The html is rendered as blah blah .
16:10 (quit) karswell: Remote host closed the connection
16:11 Guest4858: Shambles_: wait, I forgot to unquote.
16:11 (quit) anonus: Quit: WeeChat 0.3.7
16:12 Shambles_: Guest4858: This works for me: (require xml) (write-xml/content (make-comment " test "))
16:12 (join) anonus
16:14 Cryovat: I have a question regarding Scribble
16:15 Cryovat: Can you use it Javadoc-style?
16:15 Cryovat: As in inline documentation
16:15 Cryovat: Or would you have to do it it separately?
16:16 (quit) untrusted: Remote host closed the connection
16:16 Shambles_: Cryovat: Is this not what you're looking for? http://docs.racket-lang.org/scribble/lp.html
16:17 (join) nilyaK
16:18 (quit) sindoc: Quit: Leaving.
16:18 Cryovat: I guess it kinds of achives it, but I would want something that's more "code first"
16:19 Shambles_: You want the documentation inside the code, rather than the code inside the documentation?
16:20 Cryovat: Exactly
16:21 (join) random_malice
16:22 (join) bro_grammer
16:22 offby1: You got your chocolate in my peanut butter
16:23 Shambles_: Cryovat: What you want is called "docstrings" in most Lisp's, but Googling for "Racket docstrings" (without the outer quotes) only shows people saying it doesn't exist, so I'm guessing it's only literate programming style. I think the argument for literate programming is it lets you include graphics and fancy formatting you can't get in just ASCII.
16:23 Cryovat: Like, in C# (my "native" language), I'd write like this: https://gist.github.com/a4f2aeae94d30f5179f8
16:23 Guest4858: Let me ask my question more directly: is there an easy way to convert from Scribble to xexpr?
16:24 Cryovat: I would prefer to be able to write Scribble documentation in a similar manner
16:24 (quit) hash_table: Ping timeout: 245 seconds
16:24 (quit) getpwnam: Ping timeout: 245 seconds
16:25 Guest4858: Cryovat: the answer is yes.
16:26 Guest4858: It's Section 4.6 of the Scribble documentation. "In-Source Documentation."
16:26 Cryovat: Ah, thanks
16:26 Cryovat: Sorry for missing that
16:27 Shambles_: Guest4858: Good find.
16:27 Shambles_: I wonder why it uses the term JavaDoc rather than the older, more Lisp related, and more widespread (even Python has docstrings, and calls them that), docstrings.
16:28 Guest4858: So, back to my question: is there an easy way to convert Scribble to xexpr?
16:32 Shambles_: Guest4858: Is there a way to get the tree structure of a document? I can't seem to find it if there is. If so, you aught to be able to spew out xexprs for it pretty easily.
16:33 Shambles_: Guest4858: I'm finding mention of tree traversal in the documentation, but not where you can do that in the API.
16:34 Cryovat: Hmm
16:35 Cryovat: I see one "problem" with using the in-source documentation like it's presented
16:35 Cryovat: I'm using Typed Racket
16:35 Cryovat: And writing type annotations for every function
16:35 Cryovat: Looking at these functions, I'd essentially have to write everything twice :|
16:39 Shambles_: Guest4858: Is this what you need? http://docs.racket-lang.org/scribble/renderer.html
16:40 Shambles_: Guest4858: I think you could write a renderer to produce the XML you want.
16:41 (join) RacketCommitBot
16:41 RacketCommitBot: [racket] plt pushed 2 new commits to master: http://git.io/55RZhQ
16:41 RacketCommitBot: [racket/master] more error-message conversions and repairs - Matthew Flatt
16:41 RacketCommitBot: [racket/master] racket/serialize: fix for submodules - Matthew Flatt
16:41 (part) RacketCommitBot
16:41 Guest4858: Shambles_: Yes, I've already looked into those, but they're not "easy". I just found the 'file-response' web-server responder, which seems promising.
16:41 Guest4858: Thanks for helping.
16:41 Shambles_: Cryovat: Would a macro work?
16:43 Cryovat: It might, I don't know if it's possible to turn type annotations into contracts
16:43 jonrafkind: Shambles_, syntax-rules just has a pattern and a template, you cannot do any processing on the input in between
16:44 jonrafkind: syntax-case lets you do arbitrary processing. syntax-parse also lets you do arbitrary processing but it has more features for pattern matching too
16:44 jonrafkind: so there is essentially no reason to use syntax-case in the face of syntax-parse, except for possibly performance reasons
16:44 Shambles_: jonrafkind: Okay, so my understanding was right except syntax-parse. There's no other difference?
16:45 jonrafkind: difference between what, case and rules?
16:45 Shambles_: jonrafkind: The 3 macro systems.
16:45 jonrafkind: well syntax-parse has a whole bunch of features that you can read about
16:45 Shambles_: jonrafkind: rules is just template replacement, case lets you do arbitrary processing, parse lets you do better pattern matching?
16:46 jonrafkind: i suppose thats a fair summary
16:47 Shambles_: jonrafkind: Is there some more... digestible, description of at least syntax-parse than the Reference? I'm finding the macro section of the guide pretty rough going, even with the macro stepper (which is great), and it doesn't even mention syntax-parse.
16:47 jonrafkind: if you're wondering which one to use, then just use whatever you can. it will become clear once you get more experience with macros
16:48 jonrafkind: i dont know of any tutorial on syntax-parse
16:48 jonrafkind: its a pretty large system that definitely deserves one
16:49 Shambles_: jonrafkind: Since it seems to be rather difficult to understand one of the systems I was hoping to just get a good handle on whichever one is considered to be best. Looks like that's syntax-parse. syntax-rules didn't seem to do much to me that I couldn't do better with a function. I can at least understand how executing code at compile time would do things I couldn't do with functions.
16:49 jonrafkind: syntax-rules is mostly for getting rid of duplicated code
16:51 friscosam: Shambles_: Ryan Culpepper's dissertation has some good parts about syntax-parse http://www.ccs.neu.edu/racket/pubs/dissertation-culpepper.pdf
16:52 friscosam: also more details about macro stepper
16:52 Shambles_: friscosam: Thanks.
16:53 Shambles_: jonrafkind: Maybe it's just the examples in the Guide, but it seemed like the macros using syntax-rules were mostly 'good for' introducing a lot of bloat to the executable by duplicating code that you could have just put in one function (to remove the duplication).
16:55 (join) jeapostrophe
16:55 (quit) jeapostrophe: Changing host
16:55 (join) jeapostrophe
16:59 friscosam: for me the progression is: simple rewriting -> use syntax-rules; need to run code at expand time -> use syntax-case; have complex ast that needs to be parsed -> syntax-parse
17:05 jonrafkind: Shambles_, maybe just those examples. functions fundamentally cannot do things that macros can do like define a bunch of variables at the same time
17:05 jonrafkind: basically anything at all to do with binding a function cannot deal with
17:06 jonrafkind: and of course macros are good at writing domain specific languages
17:17 (quit) jeapostrophe: Read error: Operation timed out
17:19 (join) sindoc
17:23 (quit) netrino_: Quit: Ave!
17:23 Shambles_: I'm pretty sure I'm going to have to reread this a bunch to understand it, but even after rereading I don't know what problem this is trying to solve: http://docs.racket-lang.org/guide/stx-certs.html
17:24 Shambles_: It seems to be saying 'if you export a macro that uses a function only intended to be used inside your function, and someone rummages around inside your exported function and gets ahold of it, they could hurt themselves with it, and this stops that". Seems to me if someone is 'rummaging around in' the internals of something undocumented they can expect to hurt themselves?
17:25 Shambles_: "only intended to be used inside your macro" rather.
17:25 Shambles_: and "inside your exported macro".
17:25 (quit) bluezenix: Quit: Leaving.
17:27 jonrafkind: there is no clear distinction in syntax that is the result of a macro between things that are internal to the macro and things that are external
17:28 jonrafkind: taints put a distinction in place by making an error if you try to cross that boundary
17:28 (join) bluezenix
17:30 (quit) sindoc: Quit: Leaving.
17:30 (join) sindoc
17:33 (join) sindoc1
17:34 (join) sindoc2
17:34 (quit) sindoc: Ping timeout: 240 seconds
17:35 (quit) sindoc2: Read error: Connection reset by peer
17:36 Shambles_: jonrafkind: Since everything is lexically scoped, how would you 'get at' the internals of a macro?
17:37 (quit) sindoc1: Ping timeout: 246 seconds
17:38 jyc: how do you define a macro that can accept an identifier without resolving it?
17:41 Shambles_: jyc: Would a 'box' variable or "delay" (http://docs.racket-lang.org/reference/Delayed_Evaluation.html) work?
17:41 jonrafkind: (foo (bar x)) ; if 'foo' and 'bar' are macros then foo can call local-expand on its argument to get the expansion of bar, then the input to 'foo' will be the output of the 'bar' macro basically, so foo can inspect the output of bar because its just syntax
17:43 Shambles_: jonrafkind: local-expand returns something like a list, that you can just screw around with as you please? I always thought that in the situation of (stuff-out-there (stuff-in-here)) that stuff out there can't get at stuff in here. The communication was purely through arguments and return values.
17:43 (quit) antithesis: Quit: antithesis
17:44 jonrafkind: macros are expanded outside in, so first 'stuff-out-there' will get (stuff-in-here) as its argument
17:44 jyc: Shambles_, I don't think so - with that, doesn't the caller have to wrap the argument in delay? (I'm new to Racket, so pardon me if I'm wrong...)
17:45 Shambles_: jyc: I think you'd need to make some sort of agreement with the caller on the interface yeah, since normally arguments are evaluated.
17:46 jyc: Shambles_, ah, so I couldn't define something like define myself?
17:46 jonrafkind: jyc, macros get its arguments unresolved by default
17:46 Shambles_: jyc: I'm not sure. I'm in the process of learning macros myself.
17:46 jonrafkind: so you can do whatever you want
17:46 jonrafkind: (define-syntax-rule (my-define x v) (define x v))
17:48 Shambles_: jonrafkind: So taints are for defending the internals of your macros from people that want to do stuff like local-expand to macros they took as arguments, who might poke around in the result and try to call a function you never thought anyone else would see outside your module?
17:48 jonrafkind: right
17:48 jonrafkind: fwiw I never use taints, i never care if people poke around in my macros
17:48 Shambles_: jonrafkind: Do people really do that kind of thing, and is defending yourself against it really considered good practice?
17:49 jonrafkind: i dont know that anyone cares about protecting their macros
17:49 Shambles_: jonrafkind: It seems kind of like trying to defend your C++ code from someone using OS-provided debugging calls to get at your private variables (i.e. really over the top 'defense', for something just meant to be "don't depend on this", not some security system).
17:50 jonrafkind: well yes but you can imagine someone actually cares and without a system like this it wouldnt be possib;e
17:50 jonrafkind: although i agree there isnt a real motivation for it to exist, like there is no real attack that was done against drracket or something that I know of
17:51 jyc: jonrafkind, I'm getting "refenerence to an identifier before it's definition"
17:51 jonrafkind: can you paste your code
17:51 jonrafkind: in pastebin
17:51 jyc: wait a second, I'm able to send the value into define, but not anything else
17:52 jyc: alright
17:52 jyc: thanks for the help, btw!
17:53 jyc: https://gist.github.com/2816037
17:53 Shambles_: jonrafkind: Thanks for clearing that up. Seems the guide made some really strange decisions on what to cover, and not cover, in the macro section, since it doesn't even mention syntax-parse, and it has this blurb on something I would consider too obscure to bother implementing. I have a feeling I'll have a lot more questions as I try to get a handle on this stuff.
17:53 jonrafkind: i've been working on understanding the macro system for ~7 years and im still learning new things..
17:54 Shambles_: jonrafkind: Oddly, I didn't find getting used to continuations that bad after getting past some confusion about 'prompt's.
17:54 jonrafkind: jyc, you have to define 'a' somewhere
17:55 jyc: jonrafkind, so I can't do that?
17:55 jonrafkind: well what did you expect to happen
17:55 jonrafkind: what does (printf "~a" a) mean when there is no a?
17:55 jyc: to get the name of the identifier, somehow
17:55 jyc: I don't know, I'm trying to get used to macros
17:56 jonrafkind: put a ' in front of a
17:56 jonrafkind: (printf "~a" 'a)
17:56 jyc: jonrafkind, that works, thanks a bunch!
18:07 (quit) dzhus: Ping timeout: 240 seconds
18:32 jesyspa: Is it me, or does Racket not have a not-equal function (equivalent to (negate =))?
18:34 jonrafkind: not builtin I think
18:35 jesyspa: Hm, how come?
18:36 (quit) rahul_: Ping timeout: 248 seconds
18:36 (quit) __rahul__: Ping timeout: 265 seconds
18:37 jonrafkind: i dunno
18:41 Guest4858: Is there a more natural way to do this: (define (id x) x) @id{These words are automatically concatenated into a string.} ?
18:42 bremner: you could use values, I think
18:42 bremner: rudybot: init racket
18:42 rudybot: bremner: your sandbox is ready
18:42 Guest4858: bremner: yes, but I'd rather not use anything.
18:42 Guest4858: ie., not use anything in front of @.
18:42 bremner: oh, dunno.
18:43 Guest4858: Put another way: how does one toggle readers?
18:43 Guest4858: '#reader some-reader some-lexeme' allows only one lexeme.
18:45 Guest4858: How do I just start writing several paragraphs of Scribble code in the middle of a Racket file?
18:46 jonrafkind: i asked for the same behavior, @{a b c} should just be a string but I was shot down
18:46 Guest4858: I want more than that.
18:46 jonrafkind: like what
18:47 Guest4858: I want to be able to write several paragraphs of Scribble in the middle of Racket source.
18:47 Guest4858: @{a b c} is not good enough.
18:47 Guest4858: I want to be able to do: @{a @italic{b} c}
18:47 jonrafkind: well anyway writing @id{...} is almost as good
18:47 Guest4858: Furthermore, I want the Scribble source to be converted to an xexpr.
18:48 Guest4858: @id{...} will not permit recursive Scribble markup, as in the previous line.
18:48 jonrafkind: why not
18:48 Guest4858: hmmm...let me try again
18:49 Guest4858: OK, looks like it might. But the problem of xexprs remains.
18:50 Guest4858: Basically, we should be able to write web pages with Scribble.
18:50 jonrafkind: you would need some @xexpr{...} thing that somehow produces xexprs
18:50 Guest4858: perhaps string->xexpr?
18:50 jonrafkind: oh yea maybe that, but you have to write @id{...} right
18:51 Guest4858: Does Scribble render HTML via xexprs under the hood?
18:51 jonrafkind: im not sure
18:51 Guest4858: That would obviously be ideal.
19:13 (quit) bluezenix: Quit: Leaving.
19:18 (join) bluezenix
19:27 (join) yoklov
19:37 (quit) bitonic: Ping timeout: 246 seconds
19:44 Shambles_: tauntaun: I'm curious what you're up to with the documentation.
19:45 (quit) dented42: Quit: Computer has gone to sleep.
19:46 (join) dsantiago
19:46 tauntaun: Shambles_: I just want to be able to write sections of free-form prose.
19:47 Shambles_: tauntaun: Can't you already do that?
19:47 Shambles_: tauntaun: My cursory glance at it made it look a lot like a regular flat text file with some code jibblets strewn around.
19:50 (join) jeapostrophe
19:50 (quit) jeapostrophe: Changing host
19:50 (join) jeapostrophe
19:56 (join) bitonic
19:59 (join) kvda
20:03 (quit) bluezenix: Quit: Leaving.
20:05 (quit) nilyaK: Quit: Leaving.
20:05 tauntaun: Shambles_ and jonrafkind: I found a solution: just use the xexpr head-forms as @ functions, e.g., @p{This is a paragraph with an @i{italicized} word.}
20:06 (quit) mceier: Quit: leaving
20:06 (quit) em: Ping timeout: 244 seconds
20:08 Shambles_: Is it possible to do something like read from a file in a macro to be expanded at compile time? Say reading in a image, decompressing it, and turning it into an array to be used for things like icons?
20:08 jonrafkind: yea you can turn anything into syntax
20:08 Shambles_: jonrafkind: I wasn't sure if you could do I/O or have side effects, but that seemed like one good use of macros if it was possible.
20:09 jonrafkind: you can run all of drracket from a macro
20:09 jonrafkind: macros have some special properties but really they are just another instantiation of the racket system
20:09 jonrafkind: so there is nothing fundamentally different about phase 1 (macro expansion) vs phase 0 (normal runtime)
20:09 Shambles_: jonrafkind: When I can get my head around this I should be able to have some fun with it.
20:22 (quit) masm: Quit: Leaving.
20:37 (quit) jyc: Ping timeout: 252 seconds
20:44 (join) nilyaK
21:00 (quit) ssbr: Remote host closed the connection
21:00 (join) ssbr
21:18 (quit) nilyaK: Quit: Leaving.
21:24 (join) RacketCommitBot
21:24 RacketCommitBot: [racket] plt pushed 1 new commit to master: http://git.io/jiCqMQ
21:24 RacketCommitBot: [racket/master] change `impersonate-struct' to require evidence that a field is mutable - Matthew Flatt
21:24 (part) RacketCommitBot
21:42 asumu: jesyspa: putting a (not ...) around an equality is the usual way to check "not equal"
21:43 jesyspa: asumu: Hmm, okay, but why is this so? Something with types?
21:43 asumu: What would you call the not equality function? If it's (not-equal? x y) then it doesn't really save anything over (not (equal? x y))
21:44 asumu: You'd also have to define not-eqv?, not-eq?, so it's not really worth it.
21:44 jesyspa: Well, at least for numbers, I'd expect /=. I agree not-equal? doesn't make much sense.
21:44 (join) dented42
21:46 asumu: Yeah, I don't know why /= isn't there. The (not (= x y)) (/= x y) difference doesn't seem significant though.
21:47 jesyspa: Yeah, I guess I'm just not used to it.
21:49 asumu: Shambles_: A good macro "big picture" guide is indeed missing.
21:49 asumu: As for what to use, I always use syntax-parse unless it's a very simple macro (syntax-rules) or when I work on an existing codebase.
21:53 (join) manu3000
21:55 Shambles_: asumu: I admit I'm having a hard time understanding this part. Once I got past the confusing page on prompts, continuations weren't a big problem. So far the main thing I've gotten out of studying macros is some excitement about what I aught to be able to do when I can use them correctly, and a impression of how much thought went into designing it.
21:58 Shambles_: Also, a greater appreciation of the macro stepper. :P
21:59 asumu: Shambles_: Ryan also had a neat talk on designing macros at RacketCon last year. I dont' know if they will help, but here: http://www.cs.utah.edu/~ryan/talks/racket11-macros.pdf
21:59 asumu: s/here/here are the slides/
22:00 Shambles_: I'll give it a shot. Thanks.
22:06 (join) emma
22:07 (nick) emma -> em
22:13 (quit) jeapostrophe: Ping timeout: 252 seconds
22:14 (quit) ssbr: Ping timeout: 246 seconds
22:15 (quit) bitonic: Quit: WeeChat 0.3.7
22:15 asumu: (slide 4 of that presentation has a neat figure showing all the languages in Racket)
22:15 asumu: (that I think Robby made a few years back)
22:23 (quit) jesyspa: Quit: leaving
22:34 (quit) dented42: Quit: Computer has gone to sleep.
22:50 (join) Fare
22:55 (quit) Fare: Ping timeout: 246 seconds
22:55 (join) Kaylin
23:00 (join) ssbr
23:06 (join) jeapostrophe
23:11 (quit) ssbr: Read error: Operation timed out
23:17 (join) dented42
23:22 (join) Fare
23:23 (quit) jeapostrophe: Ping timeout: 244 seconds
23:52 (join) jesyspa
23:57 asumu: Hmm. Is there any reason that immutable? returns #f on lists?