3 ms·
It's an inapt comparison and the comparison should not be made naively. If I spent the next 6-12 months writing libraries in Rust targeted towards Python-level
by pnathan 13y ago
It's an inapt comparison and the comparison should not be made naively.
If I spent the next 6-12 months writing libraries in Rust targeted towards Python-level code, we could spend time comparing Rust + those libraries vs. Go and have a productive discussion.
Personally, I think that Go is a clumsy language, a chimera of C plus Python, having neither type safety nor significant abstraction nuance. More sophisticated minds than I have flamed Go in depth, I won't bother parroting them. :-)
Go's primary advantages are:
1. Google.
2. Targeting the Python/Ruby developers & needs.
3. Compiled & statically linked
4. Relatively stable.
Rust's chief disadvantages are:
1. Still < 1.0.
2. Semi-manual memory management. Gc'd pointers are kind of a pain.
3. How many pointer types again? >.<
4. Strongly typed. [1]
If I was given a mandating hand to develop a reliable and efficient system for most applications to maintain (with funding) over the 5-10 year term, I would be OK with choosing Rust today, with the expectation that we'd have some porting and heavy lifting as things change, possibly even contributing development time to the Rust project.
[1] Probably should expand this. You have to spend serious time understanding how the type system works after you get into the more advanced type systems. Haskell, ML. It's a disadvantage for quick learning and the quick hack to get the system working. Changes simple in a less typed language (e.g., Perl) can have non-local type ramifications in a project. /me handwaves. It's double-edged.
- pcwalton 13y ago> 2. Semi-manual memory management. Gc'd pointers are kind of a pain. Well, that's exactly what makes Rust so useful for many domains. Rust is useful for systems code because it doesn't use GC for everything. > 3. How many pointer types again? >.< There are references and then smart pointers, of which owned pointers (~) are one kind.
- NateDad 13y agoNot sure how you come to the conclusion that Go doesn't have type safety. In the end, the languages are quite different. Rust is ML/Haskelly, Go is C-ish. It's a matter of whether you like the advanced type systems, options, matching, etc in Rust, or if you want something that is capable, but a lot more straightforward and easier to come up to speed on, like Go.