2011/6/30 Brian Marick <mar...@exampler.com>:
>
> On Jun 30, 2011, at 7:54 AM, Stuart Sierra wrote:
>
>> Recently the received wisdom has been: protocols are a low-level 
>> implementation detail. Actual APIs should be built with normal functions 
>> that call the protocol methods.
>
>
> Interesting. So I'm not encouraged to think "protocols" except when I care 
> about efficiency or Java interop?

I don't think so. I see it more that the design of your lib should not
be centered around expecting the user to extend and call protocol
functions all over the place.
But rather provide classic hof leveraging internally polymorphic parts
via protocols, and exposing those hof as APIs.

If required, the user may extend some of your librarie's protocols to
his own types or to types he doesn't own (at the risk of shadowing
your librarie's own extension).
But still, the functions of the protocol(s) the user will extend will
not be those which will be called in his code.

HTH,

-- 
Laurent

-- 
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