[Fwd: Re: [go-nuts] Re: Generics false dichotomy]

Ziad Hatahet hatahet at gmail.com
Thu Feb 20 10:45:12 PST 2014


On Thu, Feb 20, 2014 at 10:21 AM, Russel Winder <russel at winder.org.uk>wrote:

> The thing here is that those people who are actually using Go for real
> problems, are finding ways of using the interface{} construct to achieve
> polymorphism for the problems they are solving,


The downside to doing that; however, is taking a performance hit, correct?
There would always be an indirection when accessing methods via an
interface, as opposed to having generics. Compare the Sort package to how
C++ is able to inline the custom sorting routine.

--
Ziad
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.puremagic.com/pipermail/digitalmars-d/attachments/20140220/800fe39f/attachment-0001.html>


More information about the Digitalmars-d mailing list