duck!
JimBob
jim at bob.com
Fri Oct 15 15:25:30 PDT 2010
I'd get used to Jimmy!, and thats a nice name too.
"Jimmy Cao" <jcao219 at gmail.com> wrote in message news:mailman.635.1287179560.858.digitalmars-d at puremagic.com...
It doesn't matter if it sounds unintuitive to you right now,
eventually if you keep using it, the word will stick.
duck! is a nice name, so I'm fine with the idea.
On Fri, Oct 15, 2010 at 4:46 PM, JimBob <jim at bob.com> wrote:
"Andrei Alexandrescu" <SeeWebsiteForEmail at erdani.org> wrote in message
news:i9ae2n$k9g$1 at digitalmars.com...
>I was talking to Walter about Kenji's adaptTo. We both think it's a very
>powerful enabler, but adaptTo is a bland name. After discussing a few
>marketing strategies, I proposed "duck". It's short, simple, and evokes
>"duck typing".
>
> class C
> {
> int draw(){ return 10; }
> }
> interface Drawable
> {
> long draw();
> }
> ...
> auto c = new C;
> auto d = duck!Drawable(c); // awes
>
> Kenji, I'll be looking forward to your submission :o). Would be great to
> allow structs to duck, too!
duck doesnt convey much meaning imo so.. why not "adapt!"
Ties in with the Adaptor design pattern.. which i'm guessing is what it
actualy does.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.puremagic.com/pipermail/digitalmars-d/attachments/20101015/1b334839/attachment.html>
More information about the Digitalmars-d
mailing list