4 ms·
From my experience building (not writing) relatively complex Rust applications like Alacritty, it's really not that bad. Building for release is definitely slow
by Kaze404 6y ago
From my experience building (not writing) relatively complex Rust applications like Alacritty, it's really not that bad. Building for release is definitely slower than C++, but development builds are almost always instant for me, as they're done incrementally.
- adamnemecek 6y agoRust is much better at caching the intermediate results of compilation. First time compilation might take some time, recompilation will be faster though.
- sivizius 6y agoMost of the time, I let my IDE check the code with rls, rust-analyzer or cargo check which invokes the rust-compiler without doing the costly code generation part with LLVM, so it is usually fast enough checking huge projects while writing or at least when saving.
- vmchale 6y agocargo doesn't do a terribly good job of caching dependencies. Might be better than whatever C++ does though.
- pjmlp 6y agoCurrently C++ is still a better experience, because using binary dependencies is quite common, so you don't compile the whole world, rather just your own application. Then most organizations have staging areas where you can share binaries across the company. And the two package managers that have been growing community support, conan and vcpkg, support caching and distribution of binary dependencies. No doubt cargo will eventually get something similar, it just isn't there today.
- adamnemecek 6y agoYou can do this with a build script.
- pjmlp 6y agoSo goodbye declarative builds.
- adamnemecek 6y agoI thought I cared about declarativeness, turns out I don't.
- pjmlp 6y agoExperience has taught me to always care about it, except when working on throw away hobby projects with teams of one, turns out not using it doesn't scale across organisations and makes for very unhappy DevOps teams.