Ian Denhardt <i...@zenhack.net>:
> What would code making use of a `Sortable` type look like? If you can't
> actually use "implements <" to overload `<`, it's not clear to me what
> it would actually do?

Be available to a Sort function.  That is, the requirement "Have a Less()"
would be replaced by "Have an implements-< method".

How this is specified at the callsite is a separate question.  I can't
see any simpler way to do it than writing '<', but if anyone hates
overloading enough to invent a syntax they can do it ab nd
I won't complain.

I'm saying I'd prefer that future to heavyweight contracts.  Surface
overloading is *not* the important thing about "implements"; having a
lightweight way to refer to typeclasses like "Sortable" is.
-- 
                <a href="http://www.catb.org/~esr/";>Eric S. Raymond</a>

My work is funded by the Internet Civil Engineering Institute: https://icei.org
Please visit their site and donate: the civilization you save might be your own.


-- 
You received this message because you are subscribed to the Google Groups 
"golang-nuts" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to golang-nuts+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to