3 ms·
> As much as I'd like to use a pragmatic language like golang, I can't live without generics (many folks feel the same way.) Feels like I'm better off learning
by Zababa 5y ago
> As much as I'd like to use a pragmatic language like golang, I can't live without generics (many folks feel the same way.) Feels like I'm better off learning Rust. Go's loss is Rust's gain.
You can usually have "generics" by way of code generation, or losing type safety. Both aren't perfect but they still work. I wonder, what do you use generics for? Maybe Go isn't suited for that type of work in general.
> Feels like I'm better off learning Rust. Go's loss is Rust's gain.
Or just Java, Go isn't just competing with Rust. Again, that will depend on your problem space.
- maccard 5y ago> I wonder, what do you use generics for? Check if an element is contained in a slice is the textbook example.
- pjmlp 5y agoFor those of us that believe in systems programming languages with GC, Go is indeed competing with Rust, alongside Nim, D, Swift, C# https://tinygo.org/ https://tinygo.org/ https://www.f-secure.com/en/consulting/foundry/usb-armory https://www.f-secure.com/en/consulting/foundry/usb-armory Naturally Rust remains an option for the use cases where GC, for whatever technical reason, is indeed not possible.