On Tue, Oct 16, 2018 at 5:44 AM Eric Raymond <e...@thyrsus.com> wrote:

> On Tuesday, October 16, 2018 at 6:34:10 AM UTC-4, Patrick Smith wrote:
>>
>> Yet another generics discussion at
>> https://gist.github.com/pat42smith/ccf021193971f6de6fdb229d68215302
>>
>
> I think it fails Ian Lance Taylor's smoke test.
>

I think this shows that it passes the smoke test:

type Order(type T) interface {

Less(T, T) bool

}

func Min(type T)(a, b T, o Order(T)) {

if o.Less(a, b) {

return a

}

return b

}


Yes, there's an extra parameter o, but that's verbosity, not a failure of
the smoke test.


> I also dislike the verbosity.
>

As do I. Again, this isn't so much a recommendation as a "what if?"
scenario.

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