#clojure log - Feb 10 2008

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

0:30 jonathan__: anything much happening out in the world?

0:34 is irc archived? any interesting discussions recently?

11:44 Hi Rich, how is the release going?

11:47 rhickey: good, hope to get docs done today

11:48 jonathan__: wow, that's awesome, I'm only up as far as namespaces, in terms of the new stuff, I only seem to need quite a small core of things.

20:18 lnostdal: hi there .. figured i'd try out clojure in emacs, but having some problems getting started

20:19 M-x-: inferior-lisp-program reports this "java -cp ~/programming/clojure/clojure.jar clojure.lang.Repl ~/programming/clojure/src/boot.clj"

20:19 rhickey: what platform?

20:19 lnostdal: linux

20:19 rhickey: what version of Clojure?

20:19 lnostdal: and when trying to do: lars@ibmr52:~$ java -cp ~/programming/clojure/clojure.jar clojure.lang.Repl ~/programming/clojure/src/boot.clj from the terminal that works .. but inside emacs, when i do m-x run-lisp i get Exception in thread "main" java.lang.NoClassDefFoundError: clojure/lang/Repl

20:19 svn

20:20 maybe i should paste some of this .. bit hard to read .. :)

20:21 rhickey: latest svn loads boot.clj from the jar, but probably not your problem

20:22 lnostdal: ok, i just did a "svn up" (rev. 656) and an "ant jar" now .. same stuff

20:23 gonna try with absolute paths .. /home/../.. maybe that helps

20:23 and .. it did .. lol

20:23 rhickey: Great!

20:24 lnostdal: this is nice .. intresting stuff, rhickey .. maybe i can start making some guis, eventually, using clojure .. it's hard using common lisp this

20:25 rhickey: there are some small examples - look at inspector.clj

20:29 (load-file "/Users/rich/dev/clojure/src/inspector.clj")

20:30 (inspector/inspect-tree {:a 1 :b 2 :c [1 2 3 4 {:d 5 :e [6 7 8]}]})

20:31 lnostdal: yeah .. hm

20:31 clojure.lang.Compiler$CompilerException: inspector.clj:27: clojure.lang.Symbol cannot be cast to clojure.lang.IFn

20:32 think i saw something mentioned about this on the forum

20:32 ..something related

20:33 rhickey: there was a spurious export (no longer needed) I just removed, in svn now

20:34 I just ran it here

20:34 lnostdal: ok, trying

20:34 rev. 657

20:36 rhickey: I think maybe irc turned colon c into some smiley thing?

20:36 should be colon c 3

20:36 lnostdal: no, i'm using a simple client

20:37 you're pasting the stuff commented out at the bottom of the file i guess

20:37 i still get that same message about line 27

20:37 ..when calling load-file

20:39 (. javax.swing.JOptionPane (showMessageDialog nil "Hello World")) works

20:39 cool stuff

20:40 jonathan__: (657 builds and works here, for the inspect tree sample -- after adding inspector/ on front of command)

20:40 lnostdal: i'm using sun java 1.6.0_03 .. dunno if it matters

20:42 rhickey: It looks like there was a bug (excessive undo?) on the previous form, no :else I don't know why I wasn't having the same problem - in SVN if you could try again

20:43 lnostdal: ok, trying rev. 658

20:43 typing "ant jar" will rebuild everything clean, or?

20:44 rhickey: I think so, only the clj file has changed so no matter

20:44 lnostdal: ok

20:44 hm, still same thing:

20:44 user=> (load-file "/home/lars/programming/clojure/src/inspector.clj")

20:44 clojure.lang.Compiler$CompilerException: inspector.clj:27: clojure.lang.Symbol cannot be cast to clojure.lang.IFn

20:45 if you want i can paste the back trace

20:45 (on a pastebin)

20:45 rhickey: sure

20:47 lnostdal: http://paste.lisp.org/display/55712

20:49 rhickey: thanks

20:53 after the exception, what do you get if you evaluate: inspector/collection-tag

20:55 lnostdal: user=> inspector/collection-tag

20:55 inspector.collection_tag@3a6e5c

20:56

20:56 and

20:56 user=> inspector/is-leaf

20:56 java.lang.Exception: No such var: inspector/is-leaf

20:57 rhickey: (instance? clojure.lang.IFn inspector/collection-tag)

20:57 lnostdal: user=> (instance? clojure.lang.IFn inspector/collection-tag)

20:57 true

20:59 rhickey: (macroexpand '(defmulti is-leaf collection-tag))

20:59 lnostdal: user=>(macroexpand '(defmulti is-leaf collection-tag))

20:59 java.lang.ClassCastException: clojure.lang.Symbol cannot be cast to clojure.lang.IFn

20:59 rhickey: should be: (def is-leaf (new clojure.lang.MultiFn collection-tag :default))

20:59 lnostdal: more details from the last one: http://paste.lisp.org/display/55712#2

21:00 hm, what did you say earlier .. something about boot.jvm moved?

21:00 maybe i'm loading an old version or something still .. when starting clojure

21:00 (i meant boot.clj)

21:01 rhickey: could be

21:02 should be on your command line, since loaded from jar

21:02 shouldn't

21:02 lnostdal: ok, gonna try

21:03 that worked ... :)

21:03 rhickey: cool

21:04 lnostdal: oww .. very nice .. i should screenshot this .. hehe :)

21:04 swing & lisp ... :D

21:05 rhickey: lots of fun - this guys thing is really neat: http://groups.google.com/group/clojure/browse_frm/thread/ce795dd1fb646df1#

21:05 lnostdal: i guess the wiki page is still correct for the latest release

21:06 yeah, i've been reading .. but haven't bothered trying until i sat down and got emacs working with this .. gonna re-read and experiment now

Logging service provided by n01se.net