Comment on Toward Go 1.3parentComments−jbert12yI'm not arguing the point that generics are unuseful.But imho the method should not be named for the compiler-type of it's return value (unless it's a type converter like int2string or similar).It should be named for the bizlogic/semantic type:So..not "getURIs()", but better "getBackendPoolMembers()" or "getBackendPoolMemberURIs()" if you have more than one way of representing them.Long method names are fine. Everyone uses autocomplete. Choose good names and rename them often as the meaning of the code changes over time.−AlisdairO12yThat's fair enough - I'm always happy to have descriptive methods names. I still want to know the compiler type of what I'm getting back though.
Comments
I'm not arguing the point that generics are unuseful.
But imho the method should not be named for the compiler-type of it's return value (unless it's a type converter like int2string or similar).
It should be named for the bizlogic/semantic type:
So..not "getURIs()", but better "getBackendPoolMembers()" or "getBackendPoolMemberURIs()" if you have more than one way of representing them.
Long method names are fine. Everyone uses autocomplete. Choose good names and rename them often as the meaning of the code changes over time.
That's fair enough - I'm always happy to have descriptive methods names. I still want to know the compiler type of what I'm getting back though.