• Boinketh@lemm.ee
    link
    fedilink
    English
    arrow-up
    15
    arrow-down
    1
    ·
    edit-2
    1 year ago

    Rust has better runtime errors, too. If you run a dev build, it should pretty much never segfault unless you use unsafe and will instead tell you what went wrong and where, no valgrind necessary.

      • eth0p@iusearchlinux.fyi
        link
        fedilink
        English
        arrow-up
        2
        ·
        1 year ago

        Can’t have a runtime error if you don’t have a compiled binary *taps forehead*

        (For the record, I say this as someone who enjoys Rust)

        • asdfasdfasdf@lemmy.world
          link
          fedilink
          arrow-up
          1
          ·
          1 year ago

          This is actually unironically a major benefit of Rust - compile time errors are supposed to be for dev mistakes and runtime errors supposed to be for user mistakes. Way easier to debug something at compile time instead of runtime.

    • Beanie@programming.dev
      link
      fedilink
      arrow-up
      1
      ·
      1 year ago

      ‘it should pretty much never segfault’ uh, isn’t that the entire point of Rust? Unless you’re counting failing a bounds check as a segfault

      • Boinketh@lemm.ee
        link
        fedilink
        arrow-up
        1
        ·
        1 year ago

        I’m confused by your comment. Yes, that is a major benefit of using Rust. That was my point.