On Tue, 23 Jun 2020 at 17:33, <teeling.s...@gmail.com> wrote:

> Imagine the following function definition, under the current proposal (I
> believe this is correct):
>
>
> func (s MyMap(K, V)) DoSomething(k K, v V) (func(type K Hashable) (k K) (V, 
> error)) {...}
>
>
I don't think that's quite right. You can't have function values with type
parameters.

So I think your example could look more like this in practice:

    func (s MyMap(K, V)) DoSomething(k K, v V) func(K) (V, error) { ... }

That doesn't seem too unreasonable to me FWIW. It reads nicely from left to
right, and everything except that first (K, V) declaration is just as
things are today.

  cheers,
    rog.

-- 
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.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/golang-nuts/CAJhgachc9jF8R7H5TuA5v2OZMpVCd53v7HsNQ9fAJ_%2Bb6XNv8g%40mail.gmail.com.

Reply via email to