3 ms·
Go is garbage-collected just like .NET. Rust indeed always pushes you towards efficiency :)
by floatboth 7y ago
Go is garbage-collected just like .NET.
Rust indeed always pushes you towards efficiency :)
- thelazydogsback 7y agoNot necessarily. I've moved C++ code to C#, and it got much faster. The reason is because of copy (and other flavors of) c'tors that needlessly copied data because it was either happening unbeknownst to the author, or it was easier than dealing with the consequences of proper aliasing semantics. I have a feeling that this is not uncommon. So IOW, bad manual memory management is going to perform worse than modern GC systems. Pretty much the same as an automatic transmission on a high-end sports sedan -- unless you really know what you're doing, the AT is going to do a better job of shifting than you are.
- mamcx 7y ago> Go is garbage-collected just like .NET. And I bet the .NET GC is much better than Go. But what I was trying to say is that is very common in .NET to build layers of layers of abstraction. .NET is still largely used by a lot of "enterprisey" developers with bad or non-existence training. With Go you get a much simpler deal: You have structs (like POCOS in C#) and you pass them. Sometimes, you put traits. Is alike what is preached for good F#/C# code, but .NET still carry the inertia. However, if you get into .NET with modern runtime (aka: around 4.5+) and idioms then I think the results will be very good.