[Bcc: drchase] On Wed, 12 Sep 2018 10:55:26 +0200 "Wojciech S. Czarnecki" <o...@fairbe.org> wrote:
> func Min(a, b T) T { `func Min(a, b type T) type T` of course. Late correction but needed. > for type switch { > case T func(T) Less(T) T: > return a.Less(b) > } > if a < b { > return a > } > return b > } The `func Min(a, b T) T ` was valid at first hours of CGG proposal life. Then, there, both compiler and user were directed to line below with `for type` construct to differentiate between generic/non generic. It would be bad for compiler though. And for reader, as in the next step contract scope emerged. TC, -- Wojciech S. Czarnecki << ^oo^ >> OHIR-RIPE -- 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.