4 ms·
Purely a question. So why would I use rust instead of C++ or C# to develop games? what are the potential advantages of that.
by throw_m239339 6y ago
Purely a question. So why would I use rust instead of C++ or C# to develop games? what are the potential advantages of that.
- implfuture 6y agoThere are many reasons, but to name a few important to me: rust gives performance on the level of C++, but with the memory safety of a garbage-collected language. It also provides protection against data races so that you can use concurrency with less chance of hard-to-debug issues.
- rainbow-road 6y agoOver C#: * Garbage collectors often scare game developers since they can lead to hard-to-fix latency spikes. * Rust has some cool libraries (specs, rayon, etc.) that let you safely parallelize computation. Over C++: * It's a memory-safe language, which instantly avoids tons of bugs. * Library interfaces are usually higher-level in Rust than in C++, for various reasons (sum types being a big one). * It's a much smaller language, so there aren't any dark corners that you'll randomly be forced to learn. * It has an easy-to-use package manager, and I'm not sure where C++ is on that front.
- PrototypeNM1 6y ago> * It has an easy-to-use package manager, and I'm not sure where C++ is on that front. In the inescapable hell of n+1 competing standards.
- adamnemecek 6y agoYou mean that every langauge has its own package manager?
- ashtonkem 6y agoI think they mean that C++ isn’t one thing, it varies a lot by the specific compiler and version you’re using.
- ShinTakuya 6y agoI think they mean that people keep coming along and saying "the existing N competing standards suck, let's make a new one everyone can use" and now there's N+1 competing standards. A reference to this xkcd https://xkcd.com/927/ https://xkcd.com/927/
- ShinTakuya 6y agoTo clarify, for C++ specifically.
- cstrahan 6y agoNo, rather C++ has many competing package managers, none of which have majority buy in from the C++ community. To name a few: https://github.com/cpp-pm/hunter https://github.com/cpp-pm/hunter https://conan.io/ https://conan.io/ https://docs.microsoft.com/en-us/cpp/build/vcpkg?view=vs-2019 https://docs.microsoft.com/en-us/cpp/build/vcpkg?view=vs-201... https://buckaroo.pm/ https://buckaroo.pm/
- aspaceman 6y agoFor some, theoretically it's easier to train new Rust developers than it is to fix the bugs of new C/C++ programmers. Folks are trying to move the cost to training and dev bringup time instead of bug-fixing time. Rust has other more technical advantages. But if you want to know why management is choosing it, it's because getting good C/C++ developers is a painful process nowadays.
- pjmlp 6y agoGetting good developers is painful process no matter what, usually those are the ones that don't answer headhunters, search for their own gigs via their own contact network, and don't get to change jobs just for a couple of more coins.
- aspaceman 6y agoTrue. Guess I just meant some folks are willing to trade one problem for another.