“Rust’s compiler prevents common bugs” So does skill. No offense to you, but, this trope is getting so tiresome. If you like the language then go ahead and use it. What is it with the rust crowd that they have to come acrosslike people trying to convert your religion at your front door?

  • LeFantome@programming.dev
    link
    fedilink
    arrow-up
    6
    ·
    2 months ago

    Some bugs. I have never heard anybody remotely skilled in Rust claim that it prevents bugs in general.

    Python prevents many classes of bugs too (compared to C++). And any statically typed compiler will prevent some bugs that Python allows. Not too controversial I hope. Of course, unlike Rust, Python is unsuitable for many C++ use cases for other reasons.

    I do not use Rust and my self-image is not tied to C++. So I do not have to get upset when people explain the benefits of Rust.

    Rust is not perfect. That is why I do not use it. But it is not some elaborate lie either. It was designed to do certain things, and it does.

    • Guttural
      link
      fedilink
      Français
      arrow-up
      1
      ·
      2 months ago

      Python will protect against certain classes of bugs for sure, but at a tremendous cost in terms of runtime performance. While it is an acceptable compromise for a lot of apps, especially when you’re lucky enough to be able to have native modules under hand (numpy?), it is not acceptable for other types of systems (embedded, high-fidelity 3D games…).

      Rust is a better general-purpose language IMO because it is more broadly applicable, while still offering the necessary safety required for modern software engineering.

      Rust’s bells and whistles aren’t free though. You pay for them in iteration speed, and that might make Python the better choice for small projects where performance isn’t a priority, among other types of projects, ignoring certain factors such as familiarity, candidate pool size, integration into existing systems, legacy code… which may tip the balance in favor of a language or the other.