The support for Native Client sounds interesting, but the distinction that it's not portable native client makes me wonder what you might use this for. What would one use the native client support for? Could I use it to allow developers to make plugins for a product in Go and C++ in a secure way, instead of using say Lua?
Go 1.3 beta 1 released
11–20 of 131 posts
Re: Go 1.3 beta 1 released
#12Re: Go 1.3 beta 1 released
#13generics please? contains no language changes
Re: Go 1.3 beta 1 released
#14Random question, why would someone use gccgo over the standard go compiler?
gccgo is also supposed to produce better code for certain computationally heavy workloads.
Re: Go 1.3 beta 1 released
#15I'm open to suggestions.
Re: Go 1.3 beta 1 released
#16I'm not asking for generics, but I really want an equivalent to Python's set data type for strings and numbers at the leas built-in. I'm aware of golang set on GitHub and the gen project as well, but I'm shocked that Go doesn't have an equivalent to the set data type yet. I'm open to suggestions.
Re: Go 1.3 beta 1 released
#17I'm not asking for generics, but I really want an equivalent to Python's set data type for strings and numbers at the leas built-in. I'm aware of golang set on GitHub and the gen project as well, but I'm shocked that Go doesn't have an equivalent to the set data type yet. I'm open to suggestions.
s := make(map[string]struct{})
s["foo"] = struct{}{}
if _, ok := s["foo"]; ok {
// exists
}
There are varying amounts of fluff you can put on top of this, but that's the basic approach. Wrap it up in a type with methods if you're using it a lot in a program.Perhaps you also want built-in union, intersection, difference, etc. I personally find I need a set with simple membership testing about 10x as often as I need more advanced set operations, so from my perspective it's fine to leave those to third-party libraries.
Re: Go 1.3 beta 1 released
#18I'm not asking for generics, but I really want an equivalent to Python's set data type for strings and numbers at the leas built-in. I'm aware of golang set on GitHub and the gen project as well, but I'm shocked that Go doesn't have an equivalent to the set data type yet. I'm open to suggestions.
I tend to use map[string]interface{} when I need a set. It works okay.