The full error is
No implementation of method: :arraySet of protocol: #'ndarray.NDArray/
ArrayProtocol found for class: ndarray.NDArray.NDArray (NDArray.clj:0)
and the code is this
(ns ndarray.NDArray
(:import java.lang.Object))
(def ... (reify Object))
(defprotocol ArrayProtocol
(fixIndex [this where axis])
(component [this axis where])
(arraySet [this indices]))
(deftype NDArray [dimensions strides strideOverwrites start data]
ArrayProtocol
(arraySet [this indices] "SET")
(fixIndex [this where axis] nil)
(component [this axis where] nil))
(defn arange [& input]
(let [data (apply range input)]
(NDArray. [(count data)] [1] [] 0 data)))
(println (arraySet (arange 20) nil))
I've been at this for a while now and while typing a small defprotocol
and small defrecord into an interpreter works putting this in Eclipse
gives me the error.
--
You received this message because you are subscribed to the Google
Groups "Clojure" group.
To post to this group, send email to [email protected]
Note that posts from new members are moderated - please be patient with your
first post.
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en