(I tried to post this to clojure-dev, but don't have permission to
post messages there)

At a repl the following works:

(defprotocol Base
 (foo [o]))

(defprotocol Base)

(defprotocol Base
 (foo [o]))

However, a file containing only those three forms, causes the
following when loaded:
loader (instance of  clojure/lang/DynamicClassLoader): attempted
duplicate class definition for name:
"clojure/test_clojure/protocols/Base"

I'm attempting to create a test for issue #353 in Assembla (see
http://gist.github.com/410416), so while it may not make sense in
general for it to be allowed for protocols to be redefined, it would
be convenient for creating a test.

It is possible to workaround this by loading two different files with
the different definitions for the protocol, but I wanted to check if
it was intended.

-- Aaron

-- 
You received this message because you are subscribed to the Google
Groups "Clojure" group.
To post to this group, send email to clojure@googlegroups.com
Note that posts from new members are moderated - please be patient with your 
first post.
To unsubscribe from this group, send email to
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en

Reply via email to