Thanks Luc and Stuart for your answers.
I will try to make my protocols more orthogonal than hierarchical in order to
make them fit this philosophy.
On 2011-08-28, at 3:43 PM, Stuart Sierra wrote:
> Hi Alexandre,
>
> Clojure Protocols do not support inheritance. This was a design choice.
> P
On 2011-08-28, at 2:27 PM, Luc Prefontaine wrote:
> On Sun, 28 Aug 2011 14:19:46 -0400
> Alexandre Patry wrote:
> Some reading:
>
> http://david-mcneil.com/post/1475458103/implementation-inheritance-in-clojure
Thanks for the quick answer.
>From what I understand, this a
Hi,
I would like to define a protocol as a super set of another. For example:
(defprotocol P1
(f [this]))
(defprotocol P1WithExtras
;; something like :extends P1
(g [this]))
;; P1WithExtras should now contain f and g.
I may have missed, but I did not find how to do it from the documentat
On 11-02-17 10:33 AM, pba wrote:
Not quite, the queue size needs to be passed in at instantiation time
for example you may want to have a 10 or 100 element queue depending
on the element type. What I'm looking for is to somehow decorate the
queue (or some other object) with behavior constraints (
On 10-12-07 01:37 AM, Alex Baranosky wrote:
Hello Alexandre,
This code makes my tests pass:
(defn distances [origin & locations]
(map #(dist-in-miles origin %) locations))
(defn map-of-distances [origin & locations]
(apply hash-map (interleave locations (apply distances origin
locations))
On 10-12-07 12:44 AM, Alex Baranosky wrote:
Here is the code I'm working on. The first function is wanted. The
second is not. (and the duplication is waiting to be factored out
somehow...)
Is there an idiomatic Clojure way to use map-of-distances on the "Line
of Note" below, instead of map-o
Le 2010-05-11 13:45, Heinz N. Gies a écrit :
On May 11, 2010, at 19:39 , Alexandre Patry wrote:
I am trying to call a java method using apply, like :
(apply .println [System/out "hello" "world"])
But I get an error: "Unable to resolve symbol: .println in th
I am trying to call a java method using apply, like :
(apply .println [System/out "hello" "world"])
But I get an error: "Unable to resolve symbol: .println in this context"
Am I missing something?
Thanks,
Alex
--
You received this message because you are subscribed to the Google
Groups "Cloj
Frank Hale wrote:
clojure + native = clotive
or clo-jive, like clojure dancing with another language.
Alex
--
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 mem
On Wed, Mar 17, 2010 at 3:08 AM, mac wrote:
After just a little more test and polish I plan on calling clj-native
1.0. But clj-native is a *really* boring name so I want to change it
before 1.0 and I don't have very good imagination when it comes to
these things.
So I need your help.
It d
Hi,
yvan wrote:
Hello Clojure group
I am testing Clojure and I have an error parsing thix XML excerpt
below.
Is this a SAX bug ou a Clojure bug .. or my mistake ?
thank's for help
IN REPL
(ns x (:require [clojure.xml :as xml]) )
x=> (try (xml/parse "exampleSortieXML.xml")(catch E
11 matches
Mail list logo