#clojure log - Apr 02 2010

The Joy of Clojure
Main Clojure site
Google Group
IRC
List of all logged dates

0:00 _ato: because foo is *ns*/foo

0:00 if that makes any sense

0:02 ,(require '[clojure.contrib.seq-utils :as foo])

0:02 clojurebot: nil

0:02 _ato: ,foo

0:02 clojurebot: java.lang.Exception: Unable to resolve symbol: foo in this context

0:02 _ato: ,foo/partition-by

0:02 clojurebot: #<seq_utils$partition_by__707 clojure.contrib.seq_utils$partition_by__707@112de47>

0:02 _ato: ,`foo

0:02 clojurebot: sandbox/foo

0:02 _ato: ,`foo/partition-by

0:02 clojurebot: clojure.contrib.seq-utils/partition-by

0:03 psykotic: ,`foo/flatten

0:03 clojurebot: clojure.contrib.seq-utils/flatten

0:05 _ato: ,(ns-unmap *ns* 'foo)

0:05 clojurebot: nil

0:05 _ato: ,`foo/partition-by

0:05 clojurebot: clojure.contrib.seq-utils/partition-by

0:05 _ato: ,(ns-unalias *ns* 'foo)

0:05 clojurebot: nil

0:05 _ato: ,`foo/partition-by

0:05 clojurebot: foo/partition-by

0:05 _ato: eh...

0:05 oh right, yep

0:06 ,foo/partition-by

0:06 clojurebot: java.lang.Exception: No such namespace: foo

0:12 riddochc: Okay, looks like the change in clojure that breaks clj-peg is 332a5a. (I know, clj-peg needs fixing, not clojure.)

0:13 So, I could use a little help in narrowing down where to look...

0:13 The code is: (ns bughunt (:use (com.lithinos.clj-peg core string-wrapper)))

0:13 That works in versions of clojure before 332a5a.

0:14 cemerick: whew, that's a doozy

0:15 riddochc: Specifcally, this is the kind of error I'm seeing:

0:15 _ato: I wonder if that's just the usual restfn error due to incompatible AOT-compile?

0:15 riddochc: java.lang.NoSuchMethodError: clojure.lang.RestFn.<init>(I)V (NO_SOURCE_FILE:1)

0:15 _ato: yeah

0:15 cemerick: yup

0:15 riddochc: Okay, what should I be looking for?

0:15 cemerick: riddochc: probably just need to re-AOT-compile

0:16 try running against sources

0:16 if only we had hiredman's fantasy ABI

0:17 riddochc: Well, there's an issue... clj-peg doesn't come with any build.xml or whatever the maven equivalent is, or *any* sort of build system, as far as I can tell. o.O

0:18 _ato: it's just pure clojure isn't it? you don't actually need to build it

0:18 cemerick: riddochc: unless you need AOT compilation, you don't need it ;-)

0:18 _ato: try just sticking the clj-peg.zip (the source zip) on your classpath

0:18 20623 2010-02-15 22:44 com/lithinos/clj_peg/core.clj

0:18 you probably don't even have to unpack it, as the paths are right ;-)

0:18 riddochc: That should work? Weird. New to java, as you can tell.

0:19 cemerick: riddochc: yes, unless gen-class, etc. is used

0:19 AOT compilation is a tradeoff that a lot of use cases don't require

0:20 _ato: ah damn

0:20 it does use gen-class

0:20 custom exceptions :(

0:20 technomancy: boo

0:21 _ato: how goes?

0:21 school keeping you busy?

0:21 riddochc: Well, I should be able to narrow this down better, since I can just use the zip... (which I'm trying now)

0:24 Hmmm. java.lang.ClassNotFoundException: com.lithinos.clj_peg.PegError (core.clj:9)

0:24 _ato: yeah.. that's it wanting gen-class

0:25 technomancy: finished school, now work's keeping busy, heh. Don't get to use Clojure enough at work, but _mst's managed to sneak in a couple of minor bits and pieces in it. ;-)

0:25 technomancy: nice =)

0:26 secret lisp!

0:27 _ato: riddochc: unpack it somewhere and do this: java -cp clojure.jar:clojure-contrib.jar:. -Dclojure.compile.path=. clojure.main -e "(compile 'com.lithinos.clj-peg.PegError)(compile 'com.lithinos.clj-peg.CyclicalError)"

0:27 (need to change the paths to your clojure and contrib jars)

0:28 riddochc: _ato: Thanks, I'll try that.

0:28 technomancy: also: submit a bug to the author

0:28 cemerick: riddochc: alternatively, you *could* try putting the source jar first in the classpath, with the binary jar second (hoping everything except for the gen-class classes get picked up from the second).

0:28 technomancy: because honestly. =)

0:28 * cemerick throws a hail mary :-P

0:33 _ato: ugh.. looks like core needs compiling as well

0:33 it uses get-interface

0:33 err gen-interface

0:33 riddochc: _ato: Okay, that output two lines: com.lithinos.clj-peg.PegError and com.lithinos.clj-peg.CyclicalError. Looks like I have some .class files in the same place as the .clj files, then.

0:34 Okay, I'll add something to build core, too.

0:35 Spewed lots of lines starting with "No defn for processing "... when I added (compile 'com.lithinos.clj-peg.core)

0:36 But there's more .class files. Doesn't *look* quite like an error?

0:36 _ato: hmm.. don't think I've seen that before

0:36 guess you could give it a go

0:36 just add the directory you unpacked it to to your classpath (or create a jar: jar -cvf ../peg-clj-fixed.jar *)

0:37 riddochc: Okay, how do I get from here to either a .zip or .jar I can put on the classpath? Or is there another way to use...

0:37 Ah, thanks.

0:41 Awesome. (ns bughunt (:use (com.lithinos.clj-peg core string-wrapper))) works now.

0:41 Or, at least, it returns 'nil' instead of erroring out.

0:41 So, when I use a newer version of clojure, I should be rebuilding clj-peg's jar?

0:43 (Assuming I've accounted for other things changing in clojure that would cause source-level incompatibilities?)

0:44 dualp: i'm getting a problem on the line (require 'swank-clojure-autoload) while following the guide at http://riddell.us/ClojureWithEmacsSlimeSwankOnUbuntu.html

0:45 cemerick: riddochc: that'd be safest, yeah

0:45 dualp: File error: Cannot open load file, swank-clojure-autoload

0:46 cemerick: riddochc: I'd recommend setting up either maven (google clojure-maven-plugin) or lein so rebuilding clj-peg is less painful next time.

0:47 riddochc: cemerick: I was experimenting with lein the other day. Haven't touched maven, I've been trying to avoid the Java side of things.

0:48 cemerick: Which would you recommend?

0:48 cemerick: riddochc: maven isn't Java, anymore than lein is, anyway

0:48 riddochc: I'm on record. :-) http://muckandbrass.com/web/pages/viewpage.action?pageId=5570562

0:49 _ato: dualp: I think that guide is out of date

0:49 dualp: try http://www.assembla.com/wiki/show/clojure/Getting_Started_with_Emacs

0:49 cemerick: riddochc: whoa, odd raw URL; I meant http://muckandbrass.com/web/display/~cemerick/2010/03/25/Why+using+Maven+for+Clojure+builds+is+a+no-brainer

0:49 tho it doesn't matter

0:50 * riddochc reads...

0:51 cemerick: riddochc: I should mention that there's hardly unanimity around build tools in clojure-land at the moment. I suspect clojure-flavored polyglot maven will settle the issue in due course, tho.

0:54 riddochc: cemerick: I'd kinda gathered that from various blogs I've been following. I'lll add this to my list...

0:55 absalom: I'm trying to figure something out here.. and I think maybe I am just being stupid, but...

0:56 I see examples using lazy-seq that would blow the stack if you wrtoe them without the macro...

0:57 I'm trying to figure out how that works.

1:09 AntonyBlakey: Anyone know how to add compiler metadata in a macro - when I macroexpand the #^{...} is gone

1:10 cemerick: AntonyBlakey: The reader is gone by the time macroexpansion happens. You need to use with-meta on the symbols you emit from your macro.

1:11 AntonyBlakey: That's what I thought, but Stuart's book says that with-meta isn't for compiler metadata e.g. type annotation.

1:12 The with-meta appears in the macroexpansion. Or should I be manafacturing my own symbols and annotating that?

1:13 cemerick: AntonyBlakey: That's what I've always done. e.g. (with-meta some-symbol {:tag symbol-of-classname}), etc

1:13 AntonyBlakey: e.g. ~(with-meta "v" {:tag klass})

1:14 cemerick: no, you can't add metadata to a string

1:15 AntonyBlakey: sorry (symbol "v")

1:16 cemerick: AntonyBlakey: that should work. Note that the value of :tag must be a symbol of the classname, *not* a class object.

1:16 That's tripped me up a number of times.

1:16 AntonyBlakey: OK, done that. Do you have any suggestion for how to verify that the metadata is there. It doesn't appear in macroexpand-1 output (as I thought it wouldn't)

1:16 good tip

1:17 cemerick: well, you can macroexpand it, and then get the meta of the symbol you expect to be hinted or whatever

1:17 the meta you add in your macro is not going to turn into reader syntax for meta tho

1:17 _ato: hmm

1:18 ,(binding [*print-meta* true] (println (with-meta 'v {:hello :world})))

1:18 clojurebot: v

1:18 _ato: guess it doesn't work

1:19 cemerick: you want

1:19 ,(binding [*print-meta* true] (prn (with-meta 'v {:hello :world})))

1:19 clojurebot: #^{:hello :world} v

1:19 cemerick: but that's not the point -- macroexpand doesn't print, it returns symbols

1:19 I guess it doesn't matter if you're just tinkering :-)

1:20 _ato: right, but you can print the result of macroexpand

1:20 AntonyBlakey: That did it, although it would be nice to get pretty-print + *print-meta* = true

1:20 Still, good enough for verifying that it works, thanks.

1:21 cemerick: a good repl will pretty print for you

1:21 and there's pprint otherwise

1:21 AntonyBlakey: Yeah, but the pretty printer doesn't honour *print-meta*

1:23 cemerick: hrm, I wonder what enclojure is doing, then

1:25 AntonyBlakey: Well, contrib pprint prints meta, but the standard enclojure pprinter doesn't

1:26 Ah, yes it does, if I (set! *print-meta* true) rather than binding. Still I thought the binding was dynamic scoping

1:27 cemerick: enclojure's printing happens after your binding form pops off

1:27 brian__: i'm trying to use "append-spit" to write data returned as a lazyseq to a file, I know its there because I can println it out, I've tried (doll line), but doesnt work

1:27 cemerick: or, I'd presume

1:27 g'night all :-)

1:28 brian__: doalli mean

1:31 dualp: speaking of enclojure, i'm trying it out and running into a problem. I create a new Clojure project, type a name and namespace and hit Finish, but no project files appear after that. If i try loading the same project again it can't be loaded either. Using the latest march release.

1:33 hm scratch that, somehow i've created one this time around.

2:00 nteon: so i have a function that returns a seq. how can I force it to be evaluated at macro-expansion time when its passed as an arg to a macro of mine?

2:00 hiredman: you can't

2:01 functions don't run until runtime

2:02 nteon: hiredman: makes sense :) thanks

2:18 is the binding macro thread-local?

2:18 hiredman: have you read the docs?

2:19 http://clojure.org/vars

2:20 nteon: hiredman: I'd read (doc binding), I hadn't read that. that answers iot

2:34 okay. so if I have a macro '(defmacro mac-test [] (let [s (gensym "s")] `(let [~s *x*] ~s))))' in the nteon.a namespace, and I use that namespace from nteon.b (where *x* is valid) and call the macro, I get 'no such var: nteon.a/*x*'

2:34 I would have thought that the code would be executing in the nteon.b namespace?

2:36 hiredman: nteon: have you read the docs?

2:37 nteon: hiredman: http://clojure.org/Namespaces didn't really help. I've read programming clojure. anything in particular you can point me to?

2:38 hiredman: http://clojure.org/reader#The%20Reader--Macro%20characters

2:43 nteon: hiredman: "syntax-quote resolves the symbol in the current context". So it seems that when I call (foo/bar) from namespace baz, for the duration of the call to bar, *ns* is rebound to foo?

2:43 hiredman: no

2:47 nteon: hiredman: then I don't understand why (defmacro mac-test-2 [] `*x*) in ns nteon.a, would return nteon.a/*x* when called from namespace nteon.b

2:49 Chousuke: nteon: ` is expanded before the macro is even called

2:49 nteon: Chousuke: oh! that makes much more sense.

2:51 I would suggest changing the reader docs from "For Symbols, syntax-quote resolves the symbol in the current context" to "For Symbols, syntax-quote resolves the symbol in the namespace in which it was defined"

2:52 but my brain has started turning to mush, so maybe it doesn'

2:52 t need clarification

2:53 Chousuke: what do you mean by "in which it was defined"? :/

2:54 syntax-quote fully qualifies even symbols that don't refer to anything

2:54 ,`foo

2:54 clojurebot: sandbox/foo

2:55 hiredman: the qualification happens at read time

2:55 it has nothing to do with def

2:55 `(foo 1) is read in as (sandbox/foo 1)

2:55 nteon: Chousuke: my edit wasn't much better, you're right. I didn't understand when I read the docs that 'in the current context' meant

2:55 'in the current context at read time'

2:55 hiredman: it just happens `(foo 1) may be the body of a macro

2:56 Chousuke: the "read time" might be just and implementation detail though

2:56 hiredman: sure...

2:57 Chousuke: ` can be implemented as a macro (ostensibly, anyway)

2:58 hiredman: do you have such an implementation?

2:59 Chousuke: hiredman: I tried to write one, but I ran into trouble with nesting and genyms

3:00 hiredman: :P

3:00 Raynes: ,(System/getProperty "user.dir")

3:00 clojurebot: java.security.AccessControlException: access denied (java.util.PropertyPermission user.dir read)

3:01 LauJensen: Disregarding Pulpcore and Processing, are there any interesting 2D libs for Java which are worth looking into?

3:05 nteon: LauJensen: cairo is interesting, and apparently has java bindings: http://www.cairographics.org/cairo-java/

3:07 LauJensen: Gives me some bad CL associations

3:08 I have a simple Java 2D thing which emits a ton of polygons, with Swing it takes between 30 and 100 ms, with Slick2D it took 200 ms - Can Cairo beat Java u think ?

3:12 nteon: LauJensen: no idea :) Its suppose to be moderately fast, especially if you're rendering to an image surface

3:28 defn: auto-complete + clojure = very nice

3:33 Raynes: I've never used auto-complete for anything.

3:34 LauJensen: I have it, but I must admit I rarely use it

3:35 Raynes: I find it unnecessary.

3:49 LauJensen: Is it really expected, that to draw 75000 (300x250) rects on a BufferImage (600x500) and then flip that unto a canvas will take between 60 and 100 ms in Java?

5:36 lpetit: nosé

5:37 dunno

5:39 zmila: dead calm after april the fool

5:58 bsteuber: zmila: everyone is catching up on learning scala, I suppose ;-)

5:59 zmila: ho! does redirect planet-clj to planet-scala still work? :)

6:01 LauJensen: Scala is where the money is though

6:04 Borkdude: money?

6:05 LauJensen: Yea. If I was pitching a project to a customer who wanted an extended on-demand warranty after the 6 months period had passed, we would agree on something like 200$ per bug fixed after warrenty expiration. If such a deal was in play, I'd prefer to code in Scala instead of Clojure

6:07 Raynes: Hehe, get paid to fix bugs you yourself introduced.

6:07 Borkdude: do you have a lot of experience with scala in production environments?

6:07 Raynes: Borkdude: I'm pretty sure he was making a joke.

6:08 LauJensen: Borkdude: No - I'm building a company based on the dismissmal of imperative langauges like Scala, for the reason of quality and _not_ bug fixing

6:08 Borkdude: hehe...

6:08 Raynes: He is implying that there would be more bugs in Scala code.

6:08 defn: LauJensen: I just turned it on -- I think it's sort of novel and interesting to code with it, but it kind of kills my train of thought every little fn i add...

6:08 Borkdude: yes I get it was a joke, but I was seriously wondering ;-)

6:08 defn: (auto-complete, that is)

6:09 LauJensen: Raynes: We're beyond implying. The argument for functional code, is the reduction in bugs

6:09 Borkdude: so immutability is not something Scala embraces?

6:09 LauJensen: Borkdude: Yes but mixed with mutability, which roams freely

6:09 Raynes: It has immutable data structures. That's about it, afaik.

6:10 LauJensen: In fact the major argument for Scala is that you can take a Java dev, and he'll be productive immediately

6:10 defn: LauJensen: for sake of argument, it feels even worse when you find a big disgusting bug and have to live with the fact that it's the "purest" bug possible

6:10 Borkdude: Sound like F#

6:10 Chousuke: I don't think it's fair to say scala is imperative :P

6:10 LauJensen: I dont think so

6:10 defn: LauJensen: i mean that tongue-in-cheek

6:11 LauJensen: Chousuke: It is though, I dont think they deny it themselves?

6:11 Chousuke: LauJensen: I admit I don't know much about it but to me it seems like it mixes both imperative and functional approaches

6:11 LauJensen: "Scala is a general purpose programming language designed to express common programming patterns in a concise, elegant, and type-safe way. It smoothly integrates features of object-oriented and functional languages. It is also fully interoperable with Java."

6:12 If Scala was functional, they would have said so. Scalas objective was to bring some functional goodness and updated type system into the OO world, ie an incremental improvement over Java in some ways

6:12 And thats fair, and I think they are doing at good job of that, but its not functional

6:13 Raynes: "Not this shit again."

6:14 nteon_: hah

6:14 LauJensen: http://gist.github.com/352998

6:14 Thats a quicksort from "Scala by Example" - Looks functional? :)

6:15 Raynes: Let's call up Robert Fischer and have a "SCALA ISN'T FUNCTIONAL" party.

6:15 Chousuke: well, obviously not because it's the imperative algorithm :P

6:15 you can do that in clojure too

6:16 albeit it'll be nasty ;(

6:16 LauJensen: Chousuke: No you cant since Clojures data structures are immutable, so theres not i += 1

6:16 The whole point is, you have to mangle the system to get near that kind of mutability

6:16 Chousuke: I suppose you're right.

6:17 array indexing as a function call somehow looks really weird to me

6:17 bsteuber: I think Scala does a good job in the same way Java did - driving the C crowd in the Lisp direction (though not nearly halfway as they stated)

6:18 Chousuke: even though it's the most natural thing to do in clojure... Just doesn't look right in an algol-style language :P

6:19 LauJensen: I think Odersky said that Clojure was between Scheme and Java, where Scala was between Haskell and Java and I think thats wrong. Scala is something between C++ and Java, while Clojure its more like Haskell, imo

6:19 _ato: depends what you're looking at

6:19 Chousuke: Scala is something between CL and java

6:19 _ato: I think his comment was more referring to the type-system there

6:19 Chousuke: with heavy leanings to the java side

6:19 LauJensen: oh - It was a tweet so I figured that he was talking about the entire languages

6:20 bsteuber: but why should Clojure be between Scheme and Java? It has Java interop, yes - but it is much more pure than Scheme

6:20 LauJensen: although my impression is that Scala is really just Java on Steroids, ie an incremental upgrade, albeit a big one

6:21 Chousuke: bsteuber: I dunno, Scheme has immutable stuff as well.

6:21 bsteuber: yeah, but not as heavy as clojure

6:21 Chousuke: I should really learn Racket or something someday

6:22 LauJensen: I gotta admit I dont seem more Scheme/Clojure resemblance than with any other dialect

6:22 Chousuke: just to experience all the cool stuff they have.

6:22 dsop: why not just use whatever does the job best...

6:23 Chousuke: I think Scheme is more like Clojure than CL is.

6:23 LauJensen: Chousuke: In what way ?

6:23 Chousuke: CL supports the functional style well because it's a lisp, but imperative code in CL is just as idiomatic

6:23 while with Scheme the focus is more on functional style

6:24 Raynes: I think J resembles the result of giving a small child hundreds of tiny stickers with symbols and letters and numbers on it and letting him arrange them all over the wall in any way he likes.

6:24 Unrelated, but true story.

6:25 Borkdude: Clojure is Lisp-1, like Scheme

6:25 but I don't really know Scheme that well

6:25 bsteuber: Borkdude: good point

6:25 LauJensen: True

6:26 Raynes: J is beautiful and organized

6:26 Raynes: LauJensen: If you know the language.

6:26 LauJensen: Raynes: And if you restrict yourself to one-liners

6:26 bsteuber: but therefore it has dirty CL Makros (despite its auto-gensym-syntax)

6:26 LauJensen: (which then, add up to about 20 - 25 lines of Clojure)

6:26 bsteuber: so for me, Clojure just has about the best features of all languages mixed :)

6:26 Chousuke: bsteuber: accidental name capture is almost never a problem though :/

6:27 bsteuber: true

6:27 Borkdude: Chousuke: why write a program with almost no errors, if you can write a program with NO errors

6:27 bsteuber: "the most hygienic unhygienic macros ever seen" xD

6:28 Chousuke: heh. indeed

6:30 Borkdude: Chousuke, "Why write programs with small bugs when you could write programs with no bugs?" -> http://letoverlambda.com/index.cl/guest/chap3.html#sec_5

6:32 webwanderer: hi, how do I send EOF to the REPL. I can't get out of (read)

6:33 _ato: webwanderer: Ctrl+D usually

6:33 mikem: webwanderer: does CTRL+D not work?

6:33 webwanderer: mikem: nope.. i'm on swank-clojure

6:34 mikem: webwanderer: in the REPL launched from the console, a newline gets out of (read)

6:35 webwanderer: Doesn't work for me.

6:35 Not for slime-repl that is

6:35 Raynes: webwanderer: Input is taken from the inferior lisp buffer.

6:35 Go there and enter your input.

6:36 How can one copy a file to a new location?

6:36 webwanderer: Yep.. worked.

6:36 Thanks..

6:37 Raynes: webwanderer: Yeah, it's a bug. It's well-known, not sure why it hasn't been fixed yet.

6:37 mikem: is there something like (read) in clojure, but which exits on the first keypress? currently, I need to press enter to dispatch my character to read

6:37 Borkdude: Where can I find more about the x# notation in macro's ?

6:38 _ato: mikem: try (.read *in*)

6:39 repl input might be buffered anyway though

6:39 mikem: yeah, the REPL requires the enter key

6:39 Chousuke: Borkdude: clojure.org/reader I think

6:39 mikem: but I think that's exactly what I'm looking for.

6:39 _ato: thanks :)

6:41 webwanderer: Raynes: CTRL+D on the inferior lisp buffer killed my session

6:41 aargh

6:42 Raynes: The inferior lisp buffer is kind of important. ;)

6:42 _ato: Raynes: one of the things Java lacks in its standard library is methods for moving/copying files. If I'm doing lots of file manipulation I usually pull in commons-io: http://commons.apache.org/io/api-release/index.html

6:43 check out the FileUtils class

6:43 but if you just want a simple copy you could just implement it yourself (open the source and destination files, read in chucks of 64k or so from one, writing them to the other)

6:43 Raynes: Well, I already have 38 jars worth of deps, what's a few more. ;)

6:45 nteon_: heh

6:46 Borkdude: Then what does x# in a macro mean

6:48 _ato: Borkdude: are you familiar with gensym?

6:48 Raynes: (doc gensym)

6:48 clojurebot: "([] [prefix-string]); Returns a new symbol with a unique name. If a prefix string is supplied, the name is prefix# where # is some unique number. If prefix is not supplied, the prefix is 'G__'."

6:48 Raynes: ,`x#

6:48 clojurebot: x__6957__auto__

6:49 Borkdude: ok great

6:49 _ato: so when using x# you won't accidentally override a symbol called x in the code that calls the macro

6:50 and you can safely nest macros etc

6:51 ,`(let [x# 5] (do-something-with x#))

6:51 clojurebot: (clojure.core/let [x__6961__auto__ 5] (sandbox/do-something-with x__6961__auto__))

6:51 _ato: ,`(let [x# 5] (do-something-with x#))

6:51 clojurebot: (clojure.core/let [x__6965__auto__ 5] (sandbox/do-something-with x__6965__auto__))

6:51 _ato: each time you get a new one

6:52 but within the syntax-quote (`) it refers to the same symbol

6:52 Borkdude: ok, I'm trying to grasp if this is the same kind of thing that this guy from Let over Lambda is trying to solve with his defmacro/g! macro

6:53 nteon_: is there a way to get the seq from ether a var or a symbol? I have a function that works perfectly when called on its own, but falls on its face when called from a macro

6:54 _ato: Borkdude: yeah, I think it's basically the same idea

6:54 Borkdude: so then what is his point with Lisp-1 being a danger to macro's, if you have this?

6:55 _ato: ah

6:55 that's fixed by clojure's syntax-quote resolving symbols

6:56 his point is that you could do:

6:56 (let [inc #(+ % 10)] (some-macro))

6:56 and then if some-macro depended on inc, it'd get messed up

6:57 but that doesn't happen due to this:

6:57 ,`(inc 2)

6:57 clojurebot: (clojure.core/inc 2)

6:57 _ato: syntax-quote namespace qualifies the inc symbol

6:57 so it always refers to the one you mean (unless you explicitly monkey-patch it with binding)

6:58 Borkdude: ok

6:59 ,(let [inc #(+ %10)] `(inc 2))

6:59 clojurebot: (clojure.core/inc 2)

6:59 Borkdude: ,(let [inc #(+ %10)] (inc 2))

6:59 clojurebot: java.lang.IllegalArgumentException: Wrong number of args passed to: sandbox$eval--6998$inc

6:59 _ato: ,(let [inc #(+ %10)] (eval `(inc 2)))

6:59 clojurebot: DENIED

6:59 _ato: or right

6:59 heh

7:00 nteon_: could you rephrase that, not sure what you mean by getting a seq from a var or symbol?

7:01 ,(let [inc #(+ % 10)] (inc 2))

7:01 clojurebot: 12

7:01 _ato: ,(let [inc #(+ % 10)] (clojure.core/inc 2))

7:01 clojurebot: 3

7:07 _ato: so in that way Clojure does a reasonable job of getting the best of everything: the elegance and simplicity of lisp-1, with the power of unhygienic macros and yet is still reasonably safe due to auto-gensym and the symbol resolution. It's not fool-proof and you still need to know what you're doing when writing macros, but it's at least pretty easy to do things the right way

7:08 Borkdude: so if you have a macro that generates code with inc in it

7:08 and you surround the macro call with a let and bind inc to some other function, what happens?

7:09 _ato: if you used syntax-quote (`), which is what you almost always want to do when writing a macro, then the macro uses the original inc function from clojure.core

7:10 it'll be this case: (let [inc #(+ % 10)] (clojure.core/inc 2))

7:10 Borkdude: ok... and when you do want to call the let-bound inc in the macro?

7:10 _ato: then you do this:

7:11 ,`(~'inc 2)

7:11 clojurebot: (inc 2)

7:11 _ato: unquote (~) and then normal quote (') to get the raw, unresolved symbol

7:11 Borkdude: ok

7:13 ,(defmacro foo [] `(inc 2))

7:13 clojurebot: DENIED

7:13 Borkdude: ah can't def macro's here... ok

7:14 Raynes: ,`(inc 2)

7:14 clojurebot: (clojure.core/inc 2)

7:15 Borkdude: (defmacro foo1 [] `(inc 2)) (defmacro foo2 [] `(~'inc 2)) (let [inc #(+ % 10)] (println (foo1) (foo2)))

7:15 => 3 12

7:18 thanks for explaining, _ato

7:18 _ato: :)

7:20 Borkdude: gtg now, later

7:26 imran_sr: Hello everyone. Just starting on clojure. Ok to ask some really dumb newbie questions here?

7:27 I'm running into namespace issues (my own lack of understanding here)

7:27 I want to use str-join. Everything fine when I do: (use '[clojure.contrib.str-utils :only (str-join)])

7:28 but how do I refer to that function if I don't map str-join into my current namespace

7:28 (clojure.contrib.str-utils/str-join ....) doesn't work

7:28 ?

7:29 _ato: ,(require 'clojure.contrib.str-utils)

7:29 clojurebot: nil

7:30 _ato: ,(clojure.contrib.str-utils/str-join "." ["b" "c" "d"])

7:30 clojurebot: "b.c.d"

7:30 imran_sr: _ato: ah, thanks

7:30 _ato: also:

7:30 ,(require '[clojure.contrib.str-utils :as str])

7:30 clojurebot: nil

7:30 _ato: ,(str/str-join "." ["b" "c" "d"])

7:30 clojurebot: "b.c.d"

7:31 imran_sr: _ato: got it. I didn't realise that I needed a (require) before using the fully qualified name

7:40 defn: ooo, this clj-refactoring tool looks neat

7:40 http://github.com/tcrayford/clojure-refactoring

7:40 imran_sr: _ato: I've got a little file with some testing code. The code works (without changing namespaces). Once I added namespaces, I'm getting some issues. Would value your (or anyone elses) opinion

7:41 http://clojure.pastebin.com/err0xjpZ

7:42 on line 15, I switch namespace to imran.learning-2

7:42 on line 61, I switch back to the user namespace

7:43 but I can't refer to a function from imran.learning-2 (line 68)

7:43 wait .... is that (require ...) needed every time I switch out of, and then back into a namespace?

7:44 hmm, nope, that isnt it :(

7:46 basically, the functions are all for use inside the repl. But there is one multimethod, which I want to segregate into its own namespace (lines 14 - 59)

7:48 when I (load-file ...) that script, I get java.lang.Exception: Unable to resolve symbol: str-join in this context (learning-2.clj:69)

7:49 any ideas?

7:49 :)

7:49 Chousuke: you shouldn't switch around namespaces like that:P

7:50 if you have repl-only functions in the file, put them inside a comment form

7:50 imran_sr: Chousuke: agreed. Im just filling out some test funcs as I go along, and thought about adding in namespaces afterwards.

7:51 comment form?

7:51 Chousuke: (comment ....)

7:52 it evaluates to nil, but if you use slime or something that can evaluate interactively, you can easily manually evaluate the forms inside it

7:52 imran_sr: without namespaces, everything in that file works from the repl. But why is it breaking if, in the middle, I segregate a multimethod (and its child functions) into its own namespace?

7:53 on line 68, the call to (imran.learning-2/show ...) seems ok, but its choking on (str-join) again ??

7:53 * licoresse looking for good names

7:54 imran_sr: Chousuke: (not arguing with your advice btw. I'm just trying to figure out why this isn't working. ie: what dumb syntax mistake I'm making)

7:55 hamza: gents, since compojure is divided in multiple projects, i am thinking about not using hiccup to generate html but rely on prxml. are there any down sides for this approach?

7:55 Chousuke: imran_sr: ns changes require you to import the needed stuff

7:55 imran_sr: btw, you should prefer dashes to underscores

7:56 licoresse: only problems with them damn underscores

7:56 Chousuke: imran_sr: (use 'clojure.contrib.str-utils) after (ns user) should work

7:57 imran_sr: aha!

7:57 thanks

7:57 Chousuke: mind if I walk through this, so I figure out whats going on (the whole point of it all, anyway) ?

7:58 Chousuke: line 2 has (require 'clojure.contrib.str-utils)

7:58 oh silly me. I just answered my own question

7:59 in (inspect-object ) I used the fully qualified path to str-join, but on line 68, I wasn't. So the original (require) on line 2 didn't help

7:59 thats it?

8:01 licoresse: ,(doc ::)

8:01 clojurebot: Invalid token: ::

8:01 licoresse: ?

8:01 ,(doc @::)

8:01 clojurebot: Invalid token: ::

8:01 licoresse: ,(doc '::)

8:01 clojurebot: Invalid token: ::

8:01 licoresse: ok

8:02 imran_sr: chouser: & _ato : thanks for your patient help gents :)

8:04 nteon_: related to a question I had above, is there a way to have a macro defined in one ns to reference an unqualified var that will be valid in the namespace of the caller?

8:04 licoresse: is only possible through a funcall?

8:05 Chousuke: nteon_: macros don't care about vars. they work with symbols

8:05 nteon_: do you mean you want to force a capturing expansion? :/

8:06 if so, you can use ~'foo within `

8:06 nteon_: Chousuke: what is a capturing expansion?

8:06 licoresse: chouser: is this a bad idea?

8:06 Chousuke: that will produce the symbol foo instead of somens/foo

8:06 * licoresse cannot spell today

8:06 Chousuke: and it will refer to whatever foo refers to in the expansion environment; could be a local, or a global var

8:06 licoresse: Chousuke: ^

8:06 Chousuke: licoresse: often it is

8:07 not always, though. sometimes it's useful

8:07 licoresse: and what is a capturing expansion?

8:07 Chousuke: but you need to document any captured names carefully so that people's code won't break

8:07 licoresse: Yeah, I see that

8:08 * licoresse wonders how you define a libspec

8:08 licoresse: ,(doc require)

8:08 clojurebot: "([& args]); Loads libs, skipping any that are already loaded. Each argument is either a libspec that identifies a lib, a prefix list that identifies multiple libs whose names share a common prefix, or a flag that modifies how all the identified libs are loaded. Use :require in the ns macro in preference to calling this directly. Libs A 'lib' is a named set of resources in classpath whose contents define a library of Cloju

8:09 Chousuke: (defmacro foo [& body] `(let [~'x 3] ~@body)) -> (let [x 6] (foo (+ x 1))) -> 4

8:09 licoresse: the comments are very terse

8:10 Chousuke: but now I must hurry away... later.

8:10 licoresse: Chousuke: thanks

8:11 nteon_: Chousuke: thanks! that is what I've been looking for for longer than I'd like to admit

8:12 licoresse: capturing expansion: when a let definition shadows a var with the same name

8:12 (inside a macro)

8:13 nteon_: I'm working on a runtime for a DSL, and all the DSL files are output from a compiler of sorts that I also have control over. So im not too worried about some of the dangers of capturing expansion

8:14 all you folks rock, thanks for the help

8:15 raek: gensym'ed symbols (foo#) are always safe, though

8:20 nteon_: raek: yea, but they don't do what I want. I have DSL files which specify a simulation, and each file has the same structure (they all have a number of vars that are the same) but is loaded into a unique namespace (based on the file's sha1-hash)

8:21 so when I call load-string on that file, I can guarantee that symbol will be defined & won't be clobbered by anything else in the meantime

8:22 its a little weird, but it seems to be working well

8:27 licoresse: nteon: sounds cool

8:29 * licoresse learning emacs: C-M-g slime-eval-print-last-expression, now I am almost inside the workspace concept of Smalltalk

8:30 webwanderer: Anybody know where I can find Clojure's grammar? I know it's pretty simple but is there a BNF somewhere?

8:33 defn: Is there a way to magically set the slime-set-default-directory when you start a swank-clojure-project

8:33 It is always very unnerving to me that I need to manually do this every time I run swank-clojure-project

8:33 am i missing something obvious?

8:33 licoresse: defn: same here

8:34 bsteuber: defn: I have emacs lisp functions starting a specific project for me

8:34 licoresse: but I am lazy

8:34 defn: bsteuber: care to share?

8:35 licoresse: bstephenson: please share

8:35 defn: im sure it's not too difficult, but i dont know if im motivated enough to actually do anything about it :)

8:37 bsteuber: http://pastie.org/900217

8:37 that's all :)

8:38 defn: hahaha, that's it!?

8:38 oh man i feel silly now

8:38 bsteuber: wenn, not sure if emacs desktops are the best

8:38 well

8:38 but at least they do the job for me

8:38 licoresse: :)

8:38 defn: ive never used desktops

8:39 bsteuber: well, you don't really need to combine both

8:39 I'd like a command that opens all _relevant_ files for a project on its own

8:39 but I'm also too lazy :)

9:02 raek: webwanderer: the readed documentation (http://clojure.org/reader) is probably the closest you get to a grammar

9:03 *reader

9:03 webwanderer: Saw that. Thanks..

9:03 raek: the clojure language is defined in terms of the data structures, not character sequences

9:04 so there is no special syntax for things like ifs and declarations

9:14 avar: raek: Those data structures have a plain-text representation. Which is what a BNF covers.

9:18 dnolen: I think I'm having a deftype inference issue: http://gist.github.com/353121

9:19 how do I return a boxed number from a deftype method?

9:20 LauJensen: dnolen: I dont think you can return any number except a boxed one

9:20 dnolen: LauJensen: I need to type hint it, I think it assumes I'm going to return a vec2 instance

9:21 I know what I wrote is wrong, but w/o the type hints I get: vector-math.core.vec2__3954.length_squared()Ljava/lang/Object;

9:21 [Thrown class java.lang.AbstractMethodError]

9:21 chouser: dnolen: since those particular methods are defined a protocol, it's the protocol that controls what type it will return

9:21 defn: ,{+ 1 2}

9:21 clojurebot: java.lang.RuntimeException: java.lang.ArrayIndexOutOfBoundsException: 3

9:21 dnolen: chouser: so just hint the protocol?

9:22 chouser: dnolen: but default protocol methods take and return Object

9:22 s/but/by/

9:22 defn: {reduce + {map inc {list 1 2}}} <<--interesting

9:22 dnolen: chouser: I know if I have no type hints and try (length-squared v), I get the ^ exception

9:23 defn: Any suggestions for profiling tools with clojure? I've tried yourkit and jvisualvm, but they are not very helpful...

9:23 Is there anything being worked on?

9:26 dnolen: defn: never used any real profiling tools but I'm surprised that YourKit isn't helpful since Rich Hickey uses it himself, and Zachary Tellman has used it to fine tune Penumbra.

9:27 defn: dnolen: it is probably very useful to someone who knows the language much better than me (aka they wrote it) ;)

9:28 dnolen: defn: heh, true enough. I used "time" _a lot_. Tho that doesn't help much for whole program profiling.

9:30 defn: yeah id just like to get to know some profiling tools better -- ive run into some performance problems with some stuff ive been working on and i can watch the profiler make a big red graph for IPersistentFn (is that right?)

9:30 but when it comes to looking at my code and saying "oh! there it is!"

9:31 im pretty much clueless

9:32 * fogus fun fun fun http://www.pawfal.org/dave/index.cgi?Projects/Scheme%20Bricks

9:33 defn: fogus: that is very cool

9:33 fogus: btw, did you see xkcd now has a CLI? I thought about your CLI on your blog when I saw it. They seem awfully similar

9:34 dnolen: chousre: so no thoughts about that exception?

9:34 chouser: ^

9:34 fogus: defn: It's actually a direct fork of my CLI code... but sadly no attribution. :p

9:34 defn: fogus: you know, i thought so

9:34 that's not cool

9:35 well i mean, it's very cool, and also not cool

9:35 fogus: it's not worth fussing about. I actually talked to the guy who did it and he said he would merge back the changes. so that's cool

9:35 mikem: how can I get at an array's length? (. my-arr length) doesn't work. my-arr is an instance of [B

9:37 fogus: ,(count (into-array [1 2]))

9:37 clojurebot: 2

9:37 defn: yeah -- if i were you i'd say something along those lines also, but if i was in that guy's position I would have given credit where it was due because that's just fairness and recognition, the community aspect

9:37 fogus: Well he did give credit to the original author, so maybe he wasn't aware that I took that over years ago. It's no biggy

9:37 defn: but *shrug*

9:37 mikem: fogus: ok, so (. my-arr length) doesn't work because my-arr is Java Array, not an instance of a Java class?

9:38 defn: fogus: im on a crusade to fight the evils of covert forking

9:38 fogus: btw, any word from manning on when the new content is gonna pop up?

9:39 i just got a snazzy ebook reader and am excited for some more JoC

9:39 fogus: defn: it wasn't covert, the history of the source is in tact. I think it was just a matter of

9:39 misunderstanding

9:39 defn: I'm hoping today... but I'm an eternal optimist

9:40 defn: same here, same here

9:40 fogus: those code blocks are very cool

9:40 "blocks"/"boxes"

9:44 fogus: have you looked into overtone at all?

9:45 fogus: defn: this? http://github.com/rosejn/overtone

9:45 defn: *nod* -- they have a pretty active list going -- i havent had a chance to play much with it, but it looks pretty cool

9:47 * fogus has almost no musical talent

9:48 defn: if you can do math you can make music :)

9:49 esj: i used to think that about pool, but it aint so, for the same reason

9:50 webwanderer: why can't I attach metadata to lists?

9:50 ,'foo

9:50 clojurebot: foo

9:51 webwanderer: ,#^{:a 1} (1 2)

9:51 clojurebot: java.lang.ClassCastException: java.lang.Integer cannot be cast to clojure.lang.IFn

9:51 defn: esj: i really hope that's not true -- i studied music in college and loved CS in the background (when i wasnt practicing i was tinkering)

9:51 webwanderer: ,#{:a 1} [1 2]

9:51 clojurebot: #{1 :a}

9:51 defn: esj: i often hear people who are gifted in math or CS say they're "not musical" and it reminds me of the same thing people who are good at music say about math "im not a math person"

9:52 it's learned helplessness

9:53 esj: in my case, I can do maths, and understand music, but the dexterity required to actually produce it, and the the decoupling between theory and practice required to produce 'soulful' music still evade me.

9:53 defn: i heard rich used to be a musician -- stuart h said that in one of his talks

9:53 chouser: ,'#^{:a 1} (1 2)

9:53 clojurebot: (1 2)

9:53 fogus: Well, it's not like I never tried music... I tried for a long time. In my case, it's a recognition of my limitations. ;-)

9:53 lpetit: > ,(meta (with-meta (list 'hello) {:foo :bar} ))

9:53 ,(meta (with-meta (list 'hello) {:foo :bar} ))

9:53 clojurebot: {:foo :bar}

9:53 chouser: ,(meta '#^{:a 1} (1 2))

9:53 clojurebot: {:a 1}

9:54 esj: as a kid I drove out 4 music teachers, one from the city, one from the country, one to the priesthood and the final one comitted suicide - no exageratiton.

9:54 defn: esj: i can produce some soul i think - im a much better musician than i am a programmer I think, but I refuse to allow that to preclude me from tackling something "soulful" in CS or math

9:54 lpetit: webwanderer: you create lists with (list ...)

9:54 defn: esj: whoa. maybe you've got some serious skills!

9:54 webwanderer: ah

9:54 lpetit: (type (list 1 2))

9:55 ,(type (list 1 2))

9:55 clojurebot: clojure.lang.PersistentList

9:55 lpetit: ,(type '(1 2))

9:55 clojurebot: clojure.lang.PersistentList

9:55 lpetit: woops

9:55 esj: I practice blues/funk guitar almost daily, and am gaining in ability, but its not easy !

9:55 defn: esj: nor is programming :)

9:55 esj: truedat !

9:55 lpetit: ,(meta (with-meta '('hello) {:foo :bar} ))

9:55 clojurebot: {:foo :bar}

9:55 lpetit: it works too

9:56 defn: esj: i learn a lot by osmosis i think -- the more you listen (really listen), the more you internalize the "feelings" and "textures" (to use a couple of cliches) of the subject

9:57 of course it's not really a subject at a certain point -- it is just your life

9:58 esj: defn: oh yeah, I was in New Orleans at the end of last year and the inspiration from those guys alone has kept me going since

9:58 defn: i try to live and breathe jazz, hacking, and inventing -- i try to live my life with attention to those things first, and everything else second

9:58 if you do that long enough i think you eventually end up somewhere you aren't right now :)

9:59 esj: still struggle to make my riffs sound like anything other than catfood though :(

10:00 luckily my coding is improving rapidly, so thats all good.

10:01 defn: esj: i think what really opened up my mind was the feeling that i didn't need to play "thoughts", i needed to play inside of the thought -- that is probably sounding really pretentious on your end, but truly, there was a moment where i realized that i needed to allow my hearing guide my thinking, sort of like i wasn't thinking at all

10:02 esj: i get what you're driving at, its an enlightenment.

10:03 defn: *nod* -- but i think that moment took me a solid 11 years, some of those years were 2-6 hours a day playing my instrument

10:03 a lot of time, but in the end i think we are all capable of being mathematician musicians with soul :)

10:05 esj: perhaps that's the commonality - both endeavours require a serious investment of time and detemination.

10:08 defn: yeah i tend to have a mindset (which has put me in some awfully terrible positions) where i feel a need to prove something, i suppose

10:08 i will disregard other things in my life and be practically manic about a subject

10:08 esj: hahaha, ditto that.

10:09 it's almost as powerful and it is dangerous :)

10:09 defn: have you ever read the bipolar lisp programmer?

10:09 http://www.lambdassociates.org/blog/bipolar.htm

10:10 esj: no, and I fear you've just disrupted my R programming !

10:11 defn: i sometimes wonder if it's just chance that i somehow ran into that article on the internet, or if there is actually a majority of people interested in lisp who are like that, because the person he describes in that article is me, to a T

10:11 i want to hand it out as my business card: "this story will tell you exactly who i am."

10:12 esj: here's something more silly: http://i.imgur.com/1gF1j.jpg

10:12 defn: agh -- sorry for all the o/t everyone watching or reading this portion of the log

10:13 sorry to my bot, for making you parse this useless line

10:13 esj: heh yes that's pretty good

10:13 esj: it has a friend: http://kvardek-du.kerno.org/2010/01/how-common-lisp-programmer-views-users.html

10:14 they came up in a recent clojure meetup

10:14 defn: esj: have you heard: http://www.catonmat.net/download/the_eternal_flame-god_wrote_in_lisp.mp3

10:14 * esj listens...

10:18 defn: esj: heh, it's surprisingly good for a parody

10:19 esj: agreed

10:19 "He had 6 days to work so he wrote it all in LISP"

10:20 defn: "Yes, God had a deadline. So he wrote it all in Lisp."

10:20 haha

10:21 anyway -- im gonna try to write some cheat codes for clojure, nice talking to you esj

10:21 esj: likewise, defn, catch you later.

10:21 defn: ciao

10:48 underdev: how do i build a map out of a sequence returned by a function?

10:49 ,(map (range 4))

10:49 clojurebot: java.lang.IllegalArgumentException: Wrong number of args passed to: core$map

10:49 cemerick: ,(apply hash-map (range 4))

10:49 clojurebot: {0 1, 2 3}

10:50 cemerick: there's also...

10:50 ,(into {} [[1 2] [3 4]])

10:50 clojurebot: {1 2, 3 4}

10:50 cemerick: depends on what your data's like

10:51 defn: underdev: what do you get back from the function?

10:51 underdev: cemerick: okay, my first attempt was apply map, which doesn't work, but apply hash-map does

10:51 cemerick: ty

10:51 defn: [1 2 3 4], {:foo 1 :bar 2}

10:51 etc

10:52 cemerick: underdev: map has little to do with hash-maps

10:52 though the latter are often referred to as maps

10:52 underdev: and knowing is half the battle :)

10:52 defn: underdev: you might also just be able to return the return of function inside {}

10:52 cemerick: yeah. This is chouser's nightmare.

10:53 and mine, too, really, but it's damn hard to un-overload a name

10:54 esj: and then there ns-unmap.....

10:54 defn: I think there should be "adumbrate" in clojure

10:54 hiredman: when push comes to shove you can always check the docstring and notice map's says nothing about maps

10:55 defn: to produce a faint image or resemblance of; to outline or sketch., to foreshadow; prefigure., to darken or conceal partially; overshadow.

10:55 LauJensen: defn: RE profiling, did you see my Fluid Dynamics post ?

10:55 cemerick: hiredman: people don't read documentation until they're absolutely forced to, regardless of domain

10:55 defn: LauJensen: i havent read it yet -- you did some profiling in there i take it?

10:55 * defn looks it up

10:55 LauJensen: Its mostly about profiling, the fluid sim is just a bonus :)

10:55 defn: ah :)

10:56 hiredman: cemerick: "push comes to shove"

10:56 cemerick: yeah

10:56 defn: that doesn't guarantee the documentation is any good

10:56 of course

10:56 hiredman: ,(doc map)

10:56 clojurebot: "([f coll] [f c1 c2] [f c1 c2 c3] [f c1 c2 c3 & colls]); Returns a lazy sequence consisting of the result of applying f to the set of first items of each coll, followed by applying f to the set of second items in each coll, until any one of the colls is exhausted. Any remaining items in other colls are ignored. Function f should accept number-of-colls arguments."

10:57 cemerick: Trouble starts when there's a forest of names that makes it feel like one needs to swallow the world to know how to do things.

10:57 forest of similar* names, I should say

10:57 defn: to you that is brilliant, inspired documentation which captures the essence of the form's being -- but to someone else it's a bunch of gibberish that should be extracted by someone who speaks esperanza

10:58 hiredman: all you need to be able to do is to recognize noun context and verb context

10:58 cemerick: rigor is demanded, but scarce

10:58 defn: that division of language is a very explicit way in which you're reading

10:58 hiredman: do something to a map, do a map

10:59 underdev: map is both, actually

10:59 defn: or rather, a very implicit way

10:59 hiredman: underdev: that is why I said context

10:59 cemerick: I'm getting happier and happier with the deftype/defrecord (near?) decision, in part because of stuff like this.

11:00 underdev: hiredman: your point stands though, this is an exception

11:00 good hueristic

11:00 cemerick: especially when I came across a macro I wrote a long time ago called defrecord that defines...domain-specific models! :-P

11:00 hiredman: ,(let [map 1] map)

11:00 clojurebot: 1

11:00 hiredman: there map is neither

11:01 defn: cemerick: is it deft/deftype?

11:01 i thought that was what rich had decided on

11:02 cemerick: no, deftype/defrecord last I saw

11:02 stuartsierra: So defrecord will be like deftype, with auto-generated impls for keyword lookup, metadata, map-like functions? deftype will then have no auto-generated impls?

11:02 hiredman: because I threatened to sue over the use of deft

11:02 cemerick: stuartsierra: that's my understanding

11:02 defn: hiredman: was your band's name in high school "deft leopard"?

11:03 hiredman: nope

11:03 defn: ...

11:03 underdev: pour some symantic sugar on me...

11:03 stuartsierra: You can't own a real word.

11:04 defn: touché

11:04 that being said, i own defn, and you all owe me *a lot* of money

11:04 stuartsierra: heh

11:05 hiredman: stuartsierra: I have prior art

11:05 ericthorsen: I see there have been some archetypes created for clojure projects on github. How do/can/are these archetypes get into the main maven repo?

11:06 I'd love to see them show up in the Java IDEs when people look for project archetypes

11:06 stuartsierra: ericthorsen: time, commitment, ...

11:06 I made an archetype ages ago, wanted to get it into Maven central, but wanted swank-clojure in there too. Still waiting on that one...

11:06 defn: hiredman: mid 15th century prior art?

11:07 ericthorsen: stuartsierra: how does one get an archetype into Maven central?

11:07 hiredman: defn: I'll have to check the date on my gist

11:07 defn: hiredman: haha

11:07 stuartsierra: ericthorsen: Same as any other Maven project, as far as I know. Put it in a public repository somewhere, request sync to central.

11:08 As for adding to the default list, not sure.

11:09 ericthorsen: stuartsierra: So none of these Clojure archetypes have been put into a public repl I take it?

11:09 defn: LauJensen: this post is fantastic. thank you

11:09 stuartsierra: ericthorsen: not that I am aware

11:09 I never finished mine.

11:09 ericthorsen: stuartsierra: ...default list...perhaps that is on the IDE side .

11:09 LauJensen: defn: Thanks! :)

11:09 stuartsierra: ericthorsen: There's a list that Maven shows at the command line, that was what I Was thinking.

11:10 archetype:generate or something like that

11:11 ericthorsen: stuartsierra: ok. I did look at yours. I wanted to have a few archetype available for people who are not familiar with maven. one for 1.0, 1.1, snapshot, etc. If putting them into a public repo eventually gets them synced to maven central, that may be all I need.

11:12 stuartsierra: Yes, that should be all that's needed. We'd need contrib in central too, I think.

11:12 One archetype with a config parameter for different Clojure versions would probably work.

11:12 ericthorsen: stuartsierra: Is Clojure in central

11:12 ?

11:12 stuartsierra: yes

11:13 but not officially synched from build.clojure.org yet

11:14 ericthorsen: stuartsierra: The user experience I was looking for was create project with "Clojure 1.0", "Clojure 1.1", "Clojure 1.1 w/Compujure"...just a few to get started. The user can use the IDE to add dependancies and never have to learn anything about Maven.

11:15 stuartsierra: I might be able to do some of that with parameters in the IDE. I will look into that

11:15 stuartsierra: Yeah, that sounds more like an IDE wizard than purely Maven territory.

11:15 ericthorsen: stuartsierra: forgive my ignorance here but what does "officially synched" mean?

11:16 stuartsierra: The Maven central repository (repo.maven.org) has a list of "official" public repositories that they mirror (via rsync). To get your public repository added to the list, you have to send a request to the Maven central administrators.

11:17 Once you're on the list, anything you deploy to your repo gets copied to central in 1-2 days.

11:17 cemerick: I hear things go much faster if your repo exposes indexes, etc. via http (as artifactory, nexus, etc) do.

11:17 ericthorsen: stuartsierra: Why not publish to an existing public repo? Is that a simple thing to do?

11:17 cemerick: That avoids key exchange and such.

11:18 stuartsierra: ericthorsen: yes, sonian.net maintains free repos for open-source projects; that's where the Clojure Maven plugin resides.

11:18 ericthorsen: stuartsierra: great

11:18 stuartsierra: technomancy: ping

11:21 ericthorsen: cemerick: Have you tried to add the clojars.org to Netbeans? I was not able to do it (as a maven repo anyway) but did not spend much time there

11:22 cemerick: ericthorsen: No, but I know that the repository root is not obvious, or linked to anywhere. I think you'd have to go looking in lein's source to see where it is.

11:22 or, ask technomancy or _ato :-)

11:22 stuartsierra: It's documented now on clojars.org

11:22 cemerick: ah, good

11:23 stuartsierra: http://clojars.org/repo

11:23 cemerick: there it is -- never thought to try repo.

11:24 stuartsierra: ericthorsen: By the way, just making a public Maven repo is easy: all you need is a web server. I wrote about it here http://stuartsierra.com/2009/09/08/run-your-own-maven-repository

11:24 ericthorsen: cemerick: Netbeans was looking for the index which is not there (I don;t think)

11:24 cemerick: ericthorsen: yeah, if there's no index, then you won't get any of the IDE goodness

11:24 otherwise, it'd have to crawl the thing

11:24 ericthorsen: cemerick: that is a huge bummer!

11:25 cemerick: ericthorsen: Not sure there's any alternative. You can't have thousands and thousands of IDE users DOS'ing basic mvn repos :-)

11:26 ericthorsen: cemerick: hmm...so how difficult is it to add an index to clojars?

11:26 stuartsierra: Probably would require running a real Maven repo server rather than whatever technomancy & co. have hacked up with scp

11:26 cemerick: ericthorsen: it's a lucene index AFAIK, so it'd be a pain to duplicate what nexus etc do

11:26 stuartsierra: cemerick: Really? I assumed it was just another XML file.

11:28 cemerick: stuartsierra: I don't think so. Unless I've gone nutty, it's a lucene index that contains all of the info about the poms as well as all files in all jar/zip/war/ear artifacts, etc.

11:28 that's what makes it possible to search for artifacts in NetBeans et al. by classname

11:28 stuartsierra: wow, ok

11:28 ah

11:28 * cemerick loves tools for stuff like that

11:28 stuartsierra: I assume it's tied to a specific Lucene version, then?

11:29 cemerick: the index files are of a particular version, but likely an older one to maximize compatibility

11:29 lucene has excellent support for reading older index files

11:29 ericthorsen: cemerick: Agreed. I'm trying to avoid the maven vs. lein conversation but what clojars stuff to be easily accessible to maven tools...I guess I've entered that conversation :) I'll post a note on the group about this.

11:29 want

11:29 stuartsierra: IDE support is a strong argument in favor, I think.

11:30 cemerick: stuartsierra: yup, just confirmed that the indexes are lucene

11:30 ericthorsen: stuartsierra: Especially if your argument is that maven is too complicated. I was happy to see the ployglot project move Clojure up on the supported list

11:30 stuartsierra: yes

11:31 cemerick: ok

11:31 cemerick: ericthorsen: If I can climb out of the hole I am in now, I may have a screencast/post demoing clj polyglot maven next week.

11:32 ericthorsen: cemerick: Great! That is where I want to be...clojure scripts with all the power of maven behind it.

11:33 cemerick: That is something I would want to add support in for Enclojure for sure

11:33 cemerick: ericthorsen: % the tooling issues, which we've already discussed. I'm sticking with my pom.xml's :-)

11:33 ericthorsen: cemerick: lol, yes, I won't move until I have tool support either

11:34 stuartsierra: cemerick: thanks guys!

11:34 stuartsierra: np, anything to help Maven take over the world :)

11:35 cemerick: ericthorsen: is that even possible, though? Close-enough is good enough for things like symbol completion while programming, but close-enough gets mighty frustrating while trying to complete artifact version numbers.

11:36 ericthorsen: cemerick: The symbol completion has been helpful enough for me on the pom side of things. That is all I was thinking of replicating

12:11 tufflax: I'm on windows, and in emacs that I got from clojure box, I don't have a meta key, how can I set the windows key to be the meta key?

12:12 lithper2_: try ESC at the meta key

12:12 stuartsierra: tufflax: not sure, that might be a question for #emacs

12:12 lithper2_: as*

12:12 tufflax: #emacs

12:12 ops

12:30 rhickey: so, I'm thinking about going back to explicit 'this' first arg to reify/deftype/defrecord methods

12:31 setting recur issues aside I've found 2 things:

12:31 people are confused by the difference between the protocol def, and extends, and the internal defs

12:32 second, without that there is an issue for mixins needed to know the :as binding in order to do self-reference, making them less modular

12:32 needing

12:34 * rhickey guesses everyone is out to lunch, or otherwise stunned

12:35 rhickey: :)

12:36 programble: or otherwise dont know enough about clojure to understand a word you just said :P

12:36 drewr: rhickey: I like the explicit `self` in python, so I'm fine with that decision :-)

12:38 pjstadig: rhickey: i was confused at first by the difference in arguments, and i think having an explicit argument for this or self makes sense

12:38 people could still name it what they want

12:38 rhickey: right, they can

12:38 or _ when not used

12:39 * programble names it frank

12:39 dakrone: seems very reasonable

12:39 programble: lol i wanna do that in my python code

12:40 class foobar: def __init__(frank, x): frank.x = x

12:41 cemerick: rhickey: I'm fine with that. I've come to find :as to be a little odd. Almost a wart, actually.

12:42 npoektop: hi! i have an existing project in eclipse. Is there any manual how to make it work with repl in slime?

12:42 cemerick: that is, I'd rather have implicit or explicit this, and the former now seems impolite given the rest of the language.

12:42 Chousuke: npoektop: can eclipse run a swank server?

12:43 cemerick: npoektop: you can use clojure-maven-plugin, which provides a direct REPL as well as swank and nailgun support.

12:44 npoektop: cemerick, thank you, i will try it

12:44 rhickey: neglecting the this arg is a frequent mistake with gen-class though

12:45 has everyone reconciled themselves to defrecord?

12:47 oh, and one more name game - there may be another factory fn that takes keyvals, a la struct-map, but can't have same name as record type

12:47 e.g. (defrecord Foo [a b c]) (Foo 1 2 3) (??? :a 1 :c 2 :d 42)

12:48 Chousuke: rhickey: I don't think it *generally* matters much whether this is implicit or explicit, as long as the approach chosen is consistent with the "feel" of the rest of the language

12:48 rhickey: people will just have to learn to remember the this argument

12:48 rhickey: Foo-rec, Foo-record, record-Foo

12:48 drewr: programble: `self` is only a convention

12:50 cemerick: rhickey: it's just a matter of acclimation. Python folk get along just fine with self. Most fns will just have a first _ arg.

12:51 rhickey: how about a generic fn instead of another specific def, e.g. (record Foo :a 1 :b 2)

12:52 or, if all defrecords supported a no-arg ctor, then we could just use existing map fns

12:53 rhickey: cemerick: you mean by successive conjing? that would create a full new Foo for each arg

12:53 (record Foo ...) might be possible

12:54 cemerick: rhickey: yeah, just like into, etc. If you're purposely not aligning your args, you're probably not too worried about perf anyway. *shrug*

12:55 rhickey: derived top-level names are always kludgey. If (record Foo ...) is doable, that's overwhelmingly preferable to an oddly-named, magically-defined thing.

12:55 chouser: the recur issue seems like a big ont ot just set aside (re: explicit this)

12:56 rhickey: chouser: ?

12:56 ah, one to

12:56 chouser: heh. yeah, sorry.

12:56 rhickey: well, it moves the wart

12:57 so now recurring to the method head will take one fewer args than the method sig

12:57 (foo [this x y] ... (recur newx newy))

12:58 bitti: hm

12:59 rhickey: cemerick: would you prefer (record Foo ...) for positional as well? Structs had (struct Foo ...) and (struct-map Foo ...)

12:59 bitti: rhickey: why (defn bound ...) in your ants.clj? you didn't had mod back than?

13:00 rhickey: bitti: probably not

13:01 bitti: rhickey: ic, thx :)

13:01 Chousuke: rhickey: can you cheat a bit and make recur take the explicit this argument in that case and just ignore it? :P

13:01 rhickey: Chousuke: I doubt it

13:02 chouser: see, I thought we might want 'record' to mean something besides 'defrecord'. :-)

13:02 I like (record Foo :a 1 :b 2), depending I suppose on the amount of magic required.

13:03 the amount of magic required to implement it, I mean.

13:03 Chousuke: if it's usable with apply I'm all for it

13:03 rhickey: chouser: there's plenty of overhead to the named args, but the positional case is an interesting one for cemerick's thesis about toplevel names

13:04 it might be (record ::Foo ...)

13:09 bitti: if opinions are aksed for: I like if things are implicit, even tough I don't understand the mentioned function yet...

13:09 cemerick: rhickey: being able to use Foo in function position is important, I think

13:10 Chousuke: yeah, that's the sort of thing I want to be able to do to. Throw args around, type ctor fns, mix as required.

13:10 chouser: being able to use 'record' as a real function is also important, as Chousuke mentioned. (apply record Foo myseq)

13:10 cemerick: obviously not in perf-critical sections

13:10 I think (Foo ...) and (record ::Foo ...) are a very reasonable pair, if the latter is what's required.

13:11 The keyword, that is.

13:12 rhickey: the keyword will be required if (Foo ...) is to work

13:12 and record is a fn

13:13 cemerick: are there any other circumstances where one would have to use ::Foo?

13:14 rhickey: extend, extend-type

13:14 cemerick: oh, right, nm

13:14 rhickey: extend-protocol

13:14 * cemerick still hasn't used protocols much

13:15 cemerick: right, in that case, (record ::Foo ...) is pretty natural

13:15 rhickey: protocols rock

13:16 cemerick: or at least congruent with other usage

13:16 defn: rhickey: can i quote you on that?

13:16 chouser: I hope my section on protocols will make that point sufficiently, though I don't actually use the work "rock"

13:17 cemerick: I plan on giving them a hard look when I get back to data model stuffs. Still finishing up webby things now.

13:17 chouser: ...and I have this minor problem of the dang things changing their syntax while I'm trying to write about them.

13:17 rhickey: chouser: I'm seriously working on this stuff now in order to stabilize it for 1.2 and all the books

13:17 cemerick: chouser: maybe halloway can recommend whatever brand of scotch got him through.

13:18 defn: chouser: i saw go whole hog; use the word "rock" and "awesome" exclusively

13:18 s/saw/say

13:18 rhickey: cemerick: stuart got similar support, a flurry of changes to get things in order pre-book

13:18 cemerick: defn: they'll have to get the heads first publisher to pick the book up ;-)

13:18 rhickey: defn: rock is a technical term

13:18 cemerick: rhickey: I know, I'm just screwing with chouser :-)

13:19 defn: rhickey: haha, cemerick: well played :)

13:19 rhickey: I do want all the books to be great, and correct

13:20 but big features like this need time to percolate. No one saw the churn that preceded Clojure's release

13:20 cemerick: uh-huh

13:20 ;-)

13:20 chouser: rhickey: I'm not really complaining. I have actually spent zero time so far fixing datatype or protocol example syntax.

13:20 wooby: i ran into jfli the other day and pondered that

13:21 * fogus is glad he's working on a section about stable functionality

13:21 chouser: rhickey: I'm hoping one or two simple passes later will be sufficient

13:23 fogus: hmmm, maybe stable was not the correct term. :(

13:23 quidnunc: Why does "lein-stable deps" give me "Your Leiningen development checkout is missing its dependencies", even after doing "lein-stable self-install"?

13:24 defn: quidnunc: are you building from source?

13:25 quidnunc: defn: The first part is to bootstrap in any case isn't it?

13:25 defn: (leiningen, i mean)

13:25 quidnunc: just curious what you're running lein-stable deps and then lein-stable self-install on

13:25 quidnunc: defn: I had checked out the source and was intending to but I'm fine with the sable

13:25 stable*

13:26 defn: I downloaded the "stable" script. No previous install

13:26 defn: quidnunc: ah

13:26 quidnunc: ?

13:26 defn: quidnunc: just saying "ah" -- acknowledging you

13:27 quidnunc: you could try blowing away ~/.m2 and then running lein-stable self-install again

13:27 quidnunc: defn: Does .m2 contain anything non leiningen related?

13:27 defn: if you don't know, it won't hurt you :)

13:28 quidnunc: seriously, likely the answer for you is no

13:29 quidnunc: defn: No dice

13:30 defn: still complaining, eh?

13:31 quidnunc: http://groups.google.com/group/leiningen/browse_thread/thread/3f2fce02bbdc325e/3b7b4d7354fae72c?show_docid=3b7b4d7354fae72c

13:31 ^^ are you running leiningen from your checkout?

13:31 (where is lein on your $PATH)

13:32 quidnunc: defn: I put the checkout in my path but I am running the lein-stable from temp.

13:32 I guess I should remove it from my path

13:33 defn: quidnunc: per the above URL don't put the checkout on your path, take the script you wget'd and put it in ~/bin/lein

13:34 then run lein self-install, cd ~/myprojectdir/ && lein deps

13:35 er, or in your case, you want to put the lein script somewhere outside of the checkout

13:36 quidnunc: defn: Thanks, that works

13:36 defn: np, thanks technomancy -- he's the guy who wrote it :)

13:36 thank*

14:00 ipostelnik: is there a way to view the dependency tree in lein?

14:01 I would like to know why certain transitive dependencies are included

14:01 SynrG: win 2

14:01 ups

14:03 cemerick: ipostelnik: I don't think lein provides that. If you dump the project file to a pom file, you can use any of the dependency graph tools available for maven. *shrug*

14:06 ipostelnik: oh, actually, there's the dependency:tree maven goal, which will dump the dep tree as text

14:07 ipostelnik: otherwise, both eclipse and netbeans have nice graph visualizations, e.g. http://wiki.netbeans.org/wiki/images/3/3c/Exclude_dep_NewAndNoteworthyNB68.jpg

14:30 erikcw1: I'm using a package that has a dep on commons-codec-1.3. I've added commons-codec-1.4 to my project.clj file. When I (import) from the REPL, it seems like 1.3 is being loaded. How can I specify which version of the jar I want to use?

14:33 defn: shouldn't the package you're using have the commons-codec-1.3 in its' project.clj or dependencies?

14:33 s/its\'/its

14:34 erikcw1: defn: I need 1.4 for my code, but one of my deps uses 1.3...

14:35 defn: erikcw1: ah i see -- sorry i don't know the answer :\

14:36 liebke: erikcw1: there is an exclusion option in lein for the dependencies of your dependencies. Use that to exclude the 1.3 version

14:37 defn: liebke: thanks again for your help with incanter last week -- it is working very nicely

14:37 liebke: defn: glad to hear it :)

14:46 stuartsierra: Hi all, updated documentation for lazytest, now with 15% more BDD! http://github.com/stuartsierra/lazytest

14:52 chouser: still working toward full feature merge with circumspec?

14:54 fogus: stuartsierra: It looks really nice.

14:55 stuartsierra: chouser: yes

14:56 I've got ANSI colored reports, only things missing from circumspec are 1) namespace discovery and 2) continuous testing

14:56 fogus: thanks

14:56 fogus: Any chance we'll see a discussion of this in the book?

14:56 defn: stuartsierra: very cool

14:57 stuartsierra: fogus: no, book has no library chapters

14:57 defn: thansk

14:57 chouser: stuartsierra: will one or the other go away then?

14:57 bmason: with inspect-table on a set of maps, I'm getting column headers but no data

14:57 any idea why?

14:57 stuartsierra: chouser: circumspec might go away, but that's up to the other Stu

14:58 chouser: :-) ok

14:58 bmason: I created this as a test: #{{:foo "stuff" :bar "stuff"}{:foo "more stuff" :bar "more stuff"}}

14:58 all I see in the inspector is columns 'foo' and 'bar'

14:59 nteon: why would (print "hi!") produce no output, but (println "hi!") output what I want?

15:00 stuartsierra: nteon: output buffering?

15:02 bitti: so the idea of '->' is to support chaining in a readable way?

15:02 or there is more to it?

15:02 chouser: bitti: that's pretty much it.

15:03 bitti: ic :)

15:03 bmason: are the inspect functions commonly used?

15:03 chouser: bmason: intersting -- I just get an exception and a blank window

15:04 UnsupportedOperationException: nth not supported on this type: PersistentHashSet

15:04 bmason: different version maybe?

15:05 chouser: (inspect-table (vec #{...})) seems to work

15:05 nteon: stuartsierra: holy crap thats annoying

15:05 stuartsierra: bmason, chouser: inspect-table requires a sequential thing, sets don't count

15:05 chouser: nteon: just use (flush) if you want to flush output

15:05 nteon: stuartsierra: so apparently if I don't (.flush *out*), stdout never gets written

15:05 bmason: aaah

15:06 stuartsierra: nteon: That's typical of of I/O, regardless of language.

15:06 nteon: (apparently (println ...) calls flush)

15:06 bmason: now, in Stuart Holloway's book I thought we had an example of a set of maps being used to represent a table

15:06 stuartsierra: nteon: actually the output stream flushes automatically on a newline

15:06 clojurebot: thanks; that was delicious. (nom nom nom)

15:06 chouser: nteon: when *flush-on-newline* is true

15:06 ,*flush-on-newline*

15:06 nteon: stuartsierra: eh, I guess I've gotten use to python and bash

15:06 clojurebot: true

15:07 bmason: that seemed like a logical way to represent it, as you have things like (select pred set) working on sets

15:07 nteon: stuartsierra: thanks

15:07 stuartsierra: nteon: actually, chouser's right, I'm not

15:07 chouser: bmason: I don't know how often clojure.inspect is used, but it's pretty rarely updated. Might predate clojure.set

15:08 erikcw1: Is there a clojure idiom for converting a byte array into a string, or is (String. byte-aray) the way it is done?

15:08 stuartsierra: aww, inspect-tree doesn't work on datatypes

15:08 bmason: k

15:08 what do you guys use to find out what's in stuff?

15:08 stuartsierra: bmason: prn

15:08 bmason: e.g. if you're exploring some libraries

15:09 stuartsierra: prn? assuming that's not pr0n, do you have a link?

15:09 nteon: bmason: I've found the API docs to be quite nice

15:09 stuartsierra: bmason: prn is just println but formatted like normal code, e.g. strings are quoted

15:10 bmason: stuartsierra: k

15:10 chouser: bmason: I use 'show' to look at methods of a class

15:10 bmason: is that what you're asking?

15:11 bmason: chouser: that's half of it... that works for java stuff

15:11 chouser: hm, maybe show on a namespace should list public vars

15:11 bmason: hah

15:11 yeah that's what I just tried

15:12 ,(show (first (all-ns)))

15:12 clojurebot: === public clojure.lang.Namespace === [ 0] static all : ISeq () [ 1] static find : Namespace (Symbol) [ 2] static findOrCreate : Namespace (Symbol) [ 3] static remove : Namespace (Symbol) [ 4] name : Symbol [ 5] addAlias : void (Symbol,Namespace) [ 6] alterMeta : IPersistentMap (IFn,ISeq) [ 7] equals : boolean (Object) [ 8] findInternedVar : Var (Symbol) [ 9] getAliases : IPersistentMap () [10] getClass : Class () [11] get

15:12 bmason: I got an error on mine though

15:12 chouser: ,(keys (ns-publics 'clojure.inspector))

15:12 clojurebot: java.lang.Exception: No namespace: clojure.inspector found

15:12 chouser: well, that one worked for me :-)

15:12 hiredman: ,(require 'clojure.inspector)

15:12 clojurebot: nil

15:12 chouser: ,(keys (ns-publics 'clojure.inspector))

15:12 clojurebot: (is-leaf get-child-count list-provider inspect old-table-model inspect-tree atom? get-child collection-tag table-model inspect-table tree-model list-model)

15:12 bmason: oh yeah

15:12 needed require

15:13 chouser: but without arg or return types, I'm not sure what else 'show' would show

15:13 arglists I guess. *shrug*

15:13 stuartsierra: first line of the doc?

15:13 chouser: yeah, maybe

15:14 hiredman: what if you actually want to inspect a namespace object?

15:14 bmason: yeah, good info

15:14 chouser: hiredman: there's already a similar problem when trying to inspect Class instead of a class.

15:15 hiredman: not that I actually use show

15:15 bmason: what lib is show in?

15:15 chouser: maybe an optional (show :class *ns*) vs. (show :ns *ns*)

15:15 hiredman: what do you use? javadocs?

15:15 hiredman: yes

15:15 chouser: bmason: clojure.contrib.repl-utils.

15:16 hiredman: and (->> foo class .getMethods (map #(.getName %)))

15:16 bmason: sounds like a good ns for me to read up on :)

15:16 chouser: oh, I see -- wrote your own. :-)

15:17 hiredman: but yeah, I javadoc all the time

15:17 bmason: javadocs is a website?

15:18 nvm, found the wiki article

15:18 chouser: yeah, though you can get there through repl-utils too. (javadoc obj) or (javadoc Integer)

15:18 hiredman: there are a few websites

15:18 clojurebot: see Subject Computing, Inc

15:18 hiredman: clojurebot: bzzt!

15:18 clojurebot: It's greek to me.

15:18 bmason: ah nice

15:18 hiredman: ~jdoc String

15:19 licoresse: is elisp a lisp1 or 2?

15:20 stuartsierra: lisp1

15:21 bmason: thanks for all the info guys

15:21 you've been quite helpful

15:22 nteon: if I've got a keyword, :abc, whats the easiest way to derive the string "abc" from it?

15:22 ,(.substring (str :abc) 1)

15:22 clojurebot: "abc"

15:22 nteon: anything more clojure-y?

15:22 hiredman: ,(doc name)

15:22 clojurebot: "([x]); Returns the name String of a symbol or keyword."

15:22 nteon: ,(name :abc)

15:22 clojurebot: "abc"

15:22 nteon: fantastic

15:23 bmason: doesn't substring take a start position and a length?

15:23 chouser: optional length

15:23 optional end index, actually

15:24 hiredman: ,(doc subs)

15:24 clojurebot: "([s start] [s start end]); Returns the substring of s beginning at start inclusive, and ending at end (defaults to length of string), exclusive."

15:33 bitti: rhickey: your 'Western Mass.' talk is very nice. One has the feeling your're sitting next to me going over your ants program

15:34 better than any book :)

15:34 lancepantz: bitti: link?

15:34 bitti: http://blip.tv/file/812787

15:35 the ants part is in the 2nd half tough

15:35 lancepantz: oh yeah, that one

15:35 it is great

15:36 bitti: but one has the advantage over the life participants to be able to pause when it's going too fast...

15:36 nteon: what would people think of changing (time ...) to print its output to *err* instead of *out*?

15:42 drewr: rhickey: any interest in a select-keys modification that takes nested associations?

15:43 nteon: i've had to just copy the time macro in my program, since I'm writing clojure scripts that read *in* and write to *out*, but I would like to see interesting stats like the time several method calls took

15:44 drewr: i.e., (select-keys {:foo 1 :bar 2 :baz {:quux 27 :quizzle 34}} [:bar [:baz :quux]]) => {:bar 2 :baz {:quux 27}}

15:45 hiredman: (defmacro time´ [& body] `(binding [*out* *err*] (time (binding [*out* ~*out*] ~@body))))

15:45 bleh

15:45 you need to do all the '~' stuff

15:46 nteon: hiredman: eesh :)

15:47 hiredman: *shrug*

15:48 binding is horrible and I hates it

15:48 vagif: Hello, anyone familiar with clojure swank-slime knows a way to jump to a function definition by typing (part) of its name ? I'm tired searching everytime

15:49 hiredman: changed fn A's arity, and fixed all the calls to A, and then everything blew up because someone was binding A to a fn with the old arity somewhere

16:02 stuartsierra: hiredman: avoiding binding was one motivation for lazytest

16:02 bitti: rhickey: all these talks are great, but to really hook up people you probably should make a "Creating a concurrent App in 15 minutes" talk ;)

16:09 ipostelnik: vagif, slime-apropos does something like what you want

16:09 vagif, but no auto-completion

16:12 in lein, is there a way to separate production dependencies and dev-dependencies? it appears to throw everything into lib/

16:13 div_: vagif, what about C-c C-d d ?

16:14 or M-/ for autocompletion ?

16:20 ska2342: div_: sorry, missed the beginning. M-/ sounds like dabbrev in Emacs, not autocompletion

16:22 div_: ska2342, yes you are right, i was answering vagif's question: "Hello, anyone familiar with clojure swank-slime knows a way to jump to a function definition by typing (part) of its name ? I'm tired searching everytime"

16:23 M-/ might not be optimal :)

16:27 ska2342: div_: you seem to be mixing completion of known symbols at point with jumping to the defintion of the function. Alternatively I seem to be missing the beginning of the discussion ;-)

16:31 div_: ska2342, i'm not mixing them, i was just confused by the original question (which i pasted) so i gave options for both completion and jumping to definition

16:32 but since vagif appears to have gone afk, i suppose the point is moot :)

16:33 carkh: hum btw what's the emacs extension that allwos to auto-complete "w-o-s" to "with-out-str" ?

16:34 i think it's slime related, but never managed to make it work

16:34 ska2342: carkh: fuzzy-complete in SLIME. IIRC that's not delivered with standard clojure-mode installation via ELPA

16:35 carkh: ah, and it works on pressin M-enter ?

16:36 ska2342: cark: it works with just TAB in the REPL and M-TAB in source code; the usual completion bindings. I don't know what M-Enter is bound to

16:37 carkh: ah indeed i have it working already in repl =/

16:38 ska2342: so it *does* ship with clojure mode these days?

16:38 carkh: oh i don't know, my install is a custom home made mess =P

16:39 ska2342: carkh: OK, story of my life :)

16:40 carkh: hum ok it's working with tab in repl, but not in code window ... M-tab on windows is kind of already taken

16:40 ska2342: carkh: hit and release ESC, then TAB...

16:40 carkh: yes !!

16:41 thanks a lot, this is a great improvement to my everyday life =)

16:41 ska2342: standard fallback for all the poor users using crappy window-managers

16:42 carkh: now there should be a way to bind this to some sensible key

16:42 pd: is there already a more idiomatic form of (= (string/take 2 s) "AB"), something like (string/starts-with? "AB") ?

16:43 ska2342: carkh: there is another alternative: C-c TAB

16:45 carkh: ska2342:thanks

16:47 lancepantz: pd: (.startsWith "ab" "abba")

16:48 kotarak: I don't get string/take.

16:48 ,(subs "abba" 0 2)

16:48 clojurebot: "ab"

16:51 pd: kotarak / lancepantz : ty

17:29 kotarak: ,(.index "ABCD" "C")

17:29 clojurebot: java.lang.IllegalArgumentException: No matching method found: index for class java.lang.String

17:29 kotarak: ,(.indexOf "ABCD" "C")

17:29 clojurebot: 2

18:05 vagif: sorry, stepped out. Yes i know about autocompletion and fuzzy completion and appropos

18:05 MrEvil: what's the equivlient in clojure of the compound or boolean statement?

18:05 vagif: appropos does not jump to function, only shows its doc string

18:06 Chousuke: MrEvil: compound or... what? :/

18:06 vagif: i remember there was a function that would return list of declarations in particular namespace

18:06 MrEvil: the equivlent of if( a || b)

18:06 vagif: i wonder if that can be used for findind a function

18:06 kotarak: vagif: ns-interns

18:06 Chousuke: MrEvil: (or a b) of course

18:06 MrEvil: oh

18:07 Chousuke: or actually, for that example (if (or a b) ...)

18:23 pd: i've a map {:a 1 :b 2} with all the keys for use in a struct-map (but unordered), but how can i call struct-map to use it? i thought maybe (apply ...) but haven't been able to get that to work

18:25 kotarak: pd: (apply struct-map your-struct (mapcat identity prototype-map))

18:25 hiredman: apply concat

18:25 actually

18:26 kotarak: ,(let [my-struct (create-struct :a :b)] (apply struct-map my-struct (mapcat identity {:b 1 :a 2})))

18:26 clojurebot: {:a 2, :b 1}

18:26 hiredman: you can use into

18:26 pd: kotarak: thanks again

18:26 kotarak: ,(let [my-struct (create-struct :a :b)] (apply struct-map my-struct (apply concat {:b 1 :a 2}))

18:26 clojurebot: EOF while reading

18:26 hiredman: ,(struct :a :b)

18:26 clojurebot: java.lang.ClassCastException: clojure.lang.Keyword cannot be cast to clojure.lang.PersistentStructMap$Def

18:27 hiredman: ,(create-struct :a :b)

18:27 clojurebot: #<Def clojure.lang.PersistentStructMap$Def@dceebf>

18:27 hiredman: ,(into (create-struct :a :b) {:a 1 :b 2})

18:27 kotarak: ,(let [my-struct (create-struct :a :b)] (apply struct-map my-struct (apply concat {:b 1 :a 2})))

18:27 clojurebot: java.lang.ClassCastException: clojure.lang.PersistentStructMap$Def cannot be cast to clojure.lang.IPersistentCollection

18:27 {:a 2, :b 1}

18:27 kotarak: ,(into (struct (create-struct :a :b) nil nil) {:b 2 :a 1})

18:27 clojurebot: {:a 1, :b 2}

18:28 rhickey: I can make array-maps throw an error when duplicate key is supplied. Seems people want that check, but means the behavior will differ from hash-map, which just takes last value of key

18:29 user=> (array-map :a 1 :b 2 :a 42)

18:29 java.lang.IllegalArgumentException: Duplicate key: :a (NO_SOURCE_FILE:0)

18:29 user=> (hash-map :a 1 :b 2 :a 42)

18:29 {:a 42, :b 2}

18:29 * kotarak thinks duplicate keys in literals are a non-issue...

18:30 rhickey: also, literal maps of different sizes will have different behavior when given dupe keys

18:30 :(

18:30 hiredman: :(

18:30 kotarak: ,(get (array-map :a 1 :b 2 :a 42) :a)

18:30 clojurebot: 1

18:31 rhickey: what I pasted was possible new behavior

18:31 user=> {:a 1 :b 2 :a 42}

18:31 java.lang.IllegalArgumentException: Duplicate key: :a

18:31 kotarak: ,(get {:a 1 :b 2 :c 3 :d 4 :e 5 :f 6 :g 7 :h 8 :i 9 :a 42} :a)

18:31 clojurebot: 42

18:31 qbg: Why not have array-map mirror hash-map?

18:31 kotarak: They seem to have already different behaviour.

18:32 arohner: has anyone here used parenscript in CL?

18:32 rhickey: kotarak: yes, but in your first case the resulting map isn't a proper map, undetected

18:32 ,(array-map :a 1 :b 2 :a 42)

18:32 clojurebot: {:a 1, :b 2, :a 42}

18:33 kotarak: rhickey: yes, I know. But here we get 1 with more than 9 literals we get 42.

18:33 rhickey: kotarak: that is after the fact of creating a non-map

18:33 so, a secondary effect

18:35 I'm not disagreeing they are different now, but since you have created a broken map, what behavior can you expect? In the new behavior, one will throw an error and the other not, but no bad maps

18:36 I wonder if people are relying on the last-wins behavior of hash-map

18:37 arohner: rhickey: I do, when using merge

18:37 kotarak: *shrug* I'm not aware that I do. But I also have no problem with duplicate keys in array-maps....

18:37 qbg: arohner: merge works on array-maps just fine

18:37 rhickey: arohner: merge is a different thing than attempting to create a map with dupe keys in source pairs

18:41 kotarak: no problem with them conceptually, or no problem accidentally creating them?

18:41 kotarak: rhickey: creating them. Not intentionally and not by accident in two years Clojure

18:42 Conceptually it should probably be an error, I guess.

18:43 rhickey: certain book authors want to highlight that behavior

18:44 qbg: To me it seems like (array-map & args) should be like (assoc (array-map) & args), but then again I haven't used array-maps explicitly much

18:44 rhickey: which looks bad, even though I am in complete agreement it is a non-problem in practice

18:44 qbg: that would be needlessly slow

18:44 kotarak: qbg: you do with every {} with less than 9 k-v pairs

18:45 qbg: kotarak: I know

18:46 If you can detect a duplicate key, couldn't you provide last-wins behaviour at about the same expense?

19:04 rhickey: qbg: no

19:07 kotarak: (doc get-in)

19:07 clojurebot: "([m ks]); returns the value in a nested associative structure, where ks is a sequence of keys"

19:08 dnolen: rhickey: btw, defprotocl and deftype rock. it's amazing the perf you get and you don't need to bother with type-hinting in code that uses them.

19:08 rhickey: dnolen: great!

19:09 kotarak: ah, btw. I had a problem with interface having something like "Object method(X, Comparable); Object method(X, int);" It would always call the Comparable method.

19:09 Also type-hinted as int.

19:10 Licenser: hmm can I make a seq from an java.util.Enumeration?

19:10 evening by the way :)

19:10 qbg: Speaking of deftype, why is it that in (methodName [args*] body)* you can't use the destructuring syntax for args?

19:10 rhickey: kotarak: what do you mean by always call?

19:10 kotarak: (doc enumaration-seq)

19:10 clojurebot: Excuse me?

19:11 kotarak: rhickey: I have a deftype implementing this interface. (.method some-x 5) will always call the comparable version. Even with (.method some-x (int 5)).

19:12 rhickey: I can't remember the details right now. Can check on Tuesday.

19:12 Licenser: ah no doc but it exists :) thanks kotarak

19:12 kotarak: Licenser: wenn man's richtig schreibt, findet man's auch. ;)

19:12 rhickey: (doc enumeration-seq)

19:12 clojurebot: "([e]); Returns a seq on a java.util.Enumeration"

19:12 Licenser: kotarak: details details :P

19:16 * kotarak wants get-in with a not-found default...

19:40 devinus: where is all the recent clojure development taking place ?

19:40 underdev: cleveland?

19:43 github is the prefered hosted MVCC for clojure it seems, if that's what you were asking.

19:43 but spacially, its a world-wide thing

19:44 flavorjones: it's a web. that's world-wide.

19:51 riddochc: Hm. The version of clojure that leiningen wants to use is a version that another library triggers a known bug that's since been fixed. Leiningen is seeming to cause me more problems than it solves. :(

19:53 Anybody have comments on whether polyglot maven is worth trying yet?

19:56 Or suggestions for an appropriate clojure build system for someone with xml allergies, that runs on clojure's current master and doesn't impose any particular version of clojure on the application?

20:00 underdev: just an impression i'm getting from the channel- the upper echelons are moving to pure maven

20:02 riddochc: underdev: How very javaesque.

20:02 danlarkin: that's some nice FUD you've got there

20:04 quidnunc: When I try to start slime I keep getting "NoClassDefFoundError: clojure/main". Google says that others have experienced the problem. One solution was to add swank-clojure.jar to ~/.swank-clojure. I have tried that with no success. What could be wrong?

20:06 Licenser: hmm is there a simple method to copy a file in clojure?

20:07 15SAAM03B: test

20:08 quidnunc: test successful

20:08 underdev: riddochc: yeah. i don't bring recent java experience to the table, so i've been learning maven a little at a time

20:08 riddochc: danlarkin: I simply don't *know* java anywhere near as well as I know lisp. I'm trying to stay to the lisp side of clojure when I can.

20:09 underdev: riddochc: someone tweeted this: "everyone is looking for the perfect clojure build system. It must be no less than maven 2, no greater than maven 2, and not maven 2"

20:10 brian__: quidnunc , I'm a beginner to clojure and emacs, if thats you, I have used "Clojurebox" (only) windows though

20:11 quidnunc: brian__: Thanks, but I don't use windows. And I think this automagic stuff is the source of most of my problems.

20:11 riddochc: underdev: Found any decent introductions to maven from the point of view of clojure?

20:11 danlarkin: riddochc: I was responding to underdev, not you :)

20:11 underdev: riddochc: no. not really.

20:12 there are a couple maven books available online from the maven website

20:12 qbg: quidnunc: Did you get SLIME & swank-clojure from ELPA?

20:12 dullard: quidnunc: I got up and running using elpa

20:12 underdev: someone earlier said they were going to blog about polyglot maven and clojure

20:12 earlier today, that is

20:12 riddochc: Licenser: I'd look in the java api, I don't think there's anything clojure-specific last I looked.

20:13 Licenser: *nods* thanks riddochc

20:13 I feared it was that :P

20:13 quidnunc: qbg: Yes, elpa

20:13 qbg: Licenser: You could use slurp and spit, but that could be too inefficient

20:13 underdev: quidnunc: i can't recommend emacs starter kit enough

20:13 Licenser: I wonder if (spit file (spulr file)) is working

20:13 :) qbg

20:14 underdev: quidnunc: if you install all the clojure stuff from elpa included with the emacs starter kit, it "just works"

20:14 riddochc: I haven't been able to make sense of the documentation for polyglot maven. Probably because I don't really know anything about maven.

20:14 underdev: people trying to pull slime from HEAD and whatnot report a lot of problems, it seems

20:14 quidnunc: I have been using emacs for many years. emacs-starter-kit seems way too intrusive.

20:15 "The Starter Kit should provide a saner set of defaults than you get normally with Emacs." == Heresy to a long-time emacs user.

20:15 underdev: okay, cool

20:15 quidnunc: thanks anyway

20:29 riddochc: So, leningen commit 41fd74 from ~2 weeks ago dropped clojure back to 1.1.0 because of problems in 1.2.0, but doesn't say what those problems are. Whatever they are, it doesn't look like clojure has bugfix commits since then. Does anyone know what the issue is?

20:31 qbg: Has anyone had success running the penumbra examples?

20:32 underdev: riddochc: no idea, but i see plenty of alerts about problems in lein from planet clojure. you might want to look there.

20:34 riddochc: underdev: Planet clojure? What a good idea. URL?

20:34 devinus: underdev: i meant on the web. the github repo only sees updates sporadically and they're usually small. i was wondering if i was missing something?

20:34 underdev: planetclojure.in, i think

20:35 i just get the feed, so i'm not sure :)

20:35 qbg: planet.clojure.in

20:35 underdev: yeah, sorry. i just get the feed on my igoogle page. subscribed a long time ago :)

20:36 devinus: http://www.assembla.com/spaces/dashboard/index/clojure

20:36 you might take a look there

20:39 but seriously, i'm just trying to help because there doesn't seem to be anyone else here. don't take me seriously, i'm just here for teh lulz

20:39 riddochc: underdev: thanks anyway.

20:40 qbg: riddochc: What library is causing your problem with leiningen?

20:45 riddochc: qbg: I've been trying to use clj-peg... last night, I fixed it so it'll work on both clojure 1.0 and current master, but somehow the 1.1 version of clojure lein wants to use causes an error when :use-ing clj-peg that more recent versions of clojure seems to have no problem with.

20:46 So, I have no combination of lein and clj-peg that will work on the same version of clojure.

20:46 Fun, huh?

20:46 qbg: Are you trying to run your program from lein repl or lein swank?

20:47 riddochc: repl.

20:47 qbg: Use lein swank

20:47 arohner: riddochc: or just replace clojure 1.1 with clojure 1.2 in lib/, and start clojure from the command line:

20:47 riddochc: It would make a difference? The error, by the way, is: java.lang.VerifyError: class com.lithinos.clj_peg.core$loading__4946__auto____15 overrides final method meta.()Lclojure/lang/IPersistentMap; (NO_SOURCE_FILE:1)

20:48 arohner: java -cp lib/*.jar clojure.main

20:48 riddochc: you're using a jdk6, right?

20:48 riddochc: arohner: Yup.

20:49 qbg: And works okay in Clojure 1.2?

20:49 riddochc: qbg: It does, in fact.

20:49 qbg: Then have your project that uses it depend on clojure 1.2 and use lein swank for the repl

20:50 riddochc: qbg: I haven't really used swank before. Isn't it for emacs?

20:51 qbg: Yeah, this advice is only helpful if you are using slime

20:52 riddochc: qbg: Hm. I haven't been able to get emacs to play nice with clojure yet. That's another issue altogether...

20:53 qbg: I find it is easier with lein swank than a normal slime setup actually...

20:53 All you need is slime, and not swank-clojure

20:56 underdev: *cough* <elpa> *cough* esk

20:57 qbg: That part that almost always screws up when setting slime in emacs is the launching and connecting to clojure. lein swank makes that part just work (tm) in my experience.

20:57 underdev: also, the project.clj that is used in the labrepl has some of teh hotness in it

20:58 riddochc: I've been trying to avoid emacs, honestly... I've had RSI. Long story.

20:59 I'd really rather prefer just a repl. It would work a lot better with some of the accessibility tools I use.

21:00 underdev: like what, may i ask?

21:00 i type about 30% of my clojure code. seriously.

21:00 qbg: The java -cp lib/*.jar clojure.main mentioned above should also work then

21:01 underdev: the tab key reads my mind and does what i mean

21:01 qbg: (actually, you probably want src on the classpath also)

21:02 riddochc: qbg: I suppose, then, that I might as well replace lein with a 3-line shell script, for all it's doing for me. ;)

21:02 qbg: Don't underestimate the power of shell scripts

21:03 riddochc: underdev: It's a strange setup, involving dragon naturallyspeaking in a VM, dasher, cellwriter, easystroke, and a wacom tablet.

21:03 underdev: so cool.

21:03 im unfamilar with some of those

21:04 riddochc: underdev: It's often a little slower than typing would be, but sometimes quite a lot faster, depending on what I'm doing.

21:05 underdev: rt, i use dns, x6 macro keyboard, autohotkey, and a emacs setup that's easy on the hands, with lots and lots of tab completion

21:06 w/ ubuntu hosted on windows

21:06 googling your aps

21:06 apps

21:06 riddochc: underdev: Dasher is a predictive text entry thing, cellwriter is handwriting recognition, and easystroke is gesture recognition. All free software, dasher's been widely ported.

21:07 underdev: riddochc: ty

21:07 qbg: Random thought: Using emacs with a QWERTY layout feels so weird

21:08 riddochc: I avoid using a keyboard at pretty much all costs, anymore. I'm a hobbyist now, planning on taking my linguistics background to do speech pathology instead of software dev work.

21:09 tomoj: I loved dasher, but it was too slow :(

21:10 maybe if I lose my hands

21:11 riddochc: Short version: RSI + burnout = time for a career change. Dasher's not bad, when you've trained it with everything you've ever written. ;)

21:12 tomoj: I wonder how well it can write code

21:12 riddochc: Though it's a really hideous codebase. Spaghetti code in C++. What method's being called here?

21:12 It honestly sucks for code.

21:12 tomoj: I believe my friend's sister's fiancee worked on dasher

21:14 riddochc: My version of dasher is several years old. More recent versions broke some really important features, notably auto-copy-to-clipboard.

21:18 Warning: I am empirical evidence that too much emacs and not enough typing breaks causes RSI.

21:21 But that was 5+ years ago. It's better, so long as I don't do anything stupid, like program full-time. Regression is way too easy. Take breaks, use workrave to remind you, and you'll probably avoid this fate.

21:23 underdev: i don't suffer from rsi, but i suffer from finger memory calcified to commodare 64 keyboard. i've tried dvorak and everything. i programmed in tcl for a long time because its alphanumeric + 3 sets of syntax delimiters

21:24 #(foo'()) is murder on me

21:24 but i've macro keyed all the sytactic sugar]

21:24 and paredit does the rest :)

21:26 +hippie-expand +yasnippets

21:27 riddochc: "I have gestures for a lot of syntactic sugar. Some scripts so my gestures take parameters from extra input before spitting it into the kernel's uinput module so it looks like it came from a keyboard.

21:28 I really ought to get around to releasing some of this code. I'm a perfectionist. *sigh*

21:28 underdev: im hoping that bottom-up programming will get me to the point that dragon will helpful

21:30 okay, enough spamming, back to list comprehensions :)

21:30 riddochc: Yup.

21:42 * riddochc is momentarily confused by the most recent 'full disclojure' at vimeo. Right, braces. So we use parens for maps? ;)

21:42 qbg: Fool Disclojure is awesome

21:43 tomoj: hmm

21:43 '5 days ago' doesn't sound right

21:44 riddochc: Yeah, I think the server's clock must be 4 days slow.

21:44 qbg: Or it is an excellent prank

21:44 riddochc: So much for NTP.

21:45 It's definitely clever...

21:50 Licenser: good greif :(

21:55 for the reocrd slurp spit doesnot work with non text files

22:36 underdev: im having trouble groking the difference between apply and map...

22:39 tomoj: ,(map + [1 2 3] [4 5 6])

22:39 > [5 7 9]

22:39 ,(apply + [1 2 3])

22:39 clojurebot: (5 7 9)

22:39 tomoj: > 6

22:39 clojurebot: 6

22:41 tomoj: er, a seq, yeah :)

22:41 map is for transforming the elements of a list

22:41 or applying a transformation to elements of more than one list in parallel

22:42 so the transformation you give is called n times where n is the length of the shortest list you pass

22:43 (map f [1 2 3] [4 5 6]) == [(f 1 4) (f 2 5) (f 3 6)]

22:43 (apply f [1 2 3]) == (f 1 2 3)

22:43 underdev: okay, i get it

22:44 tomoj: I am glad to see another person who groks "grok"

22:44 I get many weird looks

22:44 underdev: stranger...

22:45 tomoj: I think equivalencies like that would be useful in defn's doc project

22:45 underdev: that last bit was very helpful, yeah

22:45 tomoj: it can be easier to understand an example when you don't see the result, but some intermediate form

22:46 ,is

22:46 clojurebot: java.lang.Exception: Can't take value of a macro: #'clojure.contrib.test-is/is

22:46 underdev: rt, that completely models the results i was getting from the repl, but i couldn't see it like that

22:47 tomoj: ,(is (= (map f [1 2 3] [4 5 6]) [(f 1 4) (f 2 5) (f 3 6)]))

22:47 clojurebot: DENIED

22:47 tomoj: darn

22:47 * underdev is not smarter than the average bear

22:47 tomoj: I love that github easily allows me to look up a project by a person instead of by name

22:47 I suck at remembering names

22:48 I guess walton looks for clojurebot examples?

22:54 underdev: like Pres. Clinton before me, i don't know what "is" is, but given a def for f, that evaluates to true

22:54 super, ty tomoj

22:55 tomoj: ah, hmm

22:55 of course

22:55 the problem is that we don't want to bother coming up with such definitions

Logging service provided by n01se.net