Thanks for the clarification Stuart! I think I see how to think about
protocols ... and not as an interface, in the java sense. I think it
makes sense to me now.
Love your book, btw!
-Travis
On Jun 21, 12:31 pm, Stuart Halloway
wrote:
> Hi Travis,
>
> The choice of "extend" follows from this r
Hi Travis,
The choice of "extend" follows from this reasoning:
(1) Create a protocol. At this point there are no implementations. Protocol
functions will fail regardless of arguments passed.
(2) Extend the protocol to a String. The protocol has been *extended* to work
with one type, Strings.
I notice that there is a "satisfies?" method to determine if something
satisfies a protocol. Also, I see that "extend-protocol" doesn't
actually let one create a protocol which is an extension of another
protocol. Rather, "extend-protocol" really means "implements", in the
Java sense.
When I first