• JakeHimself@programming.dev
      link
      fedilink
      English
      arrow-up
      49
      arrow-down
      1
      ·
      1 year ago

      Tbf, you have to be pretty far with Rust to get to a point where Rust’s compiler errors stop helping you (at least, as far as I’ve seen). After that, it’s pretty much the same

      • philm@programming.dev
        link
        fedilink
        English
        arrow-up
        25
        ·
        1 year ago

        Yep use a little bit more deeply cascaded generic rust code with a lot of fancy trait-bounds and error messages will explode and be similar as C++ (though to be fair they are still likely way more helpful than C++ template based error messages). Really hope that the compiler/error devs will improve in this area

      • Boinketh@lemm.ee
        link
        fedilink
        English
        arrow-up
        16
        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
            3
            ·
            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)

        • 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.