FAQ

On Saturday, December 7, 2013 10:18:44 AM UTC+1, Gerard wrote:
Isn't this something for a package? Let's name it "set". (there are
probably existing packages with this functionality)
The problem is only builtins can be generic in Go. If you were to implement
this as a package you would need to either implement it for every key type,
or either use reflection and ask the user to generate the specialized type
for what they are going to use as a key.

Regards,
Alberto

--
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+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.

Search Discussions

Discussion Posts

Previous

Follow ups

Related Discussions

Discussion Navigation
viewthread | post
posts ‹ prev | 9 of 21 | next ›
Discussion Overview
groupgolang-nuts @
categoriesgo
postedDec 6, '13 at 5:46p
activeDec 7, '13 at 9:05p
posts21
users12
websitegolang.org

People

Translate

site design / logo © 2022 Grokbase