• WhyJiffie@sh.itjust.works
    link
    fedilink
    English
    arrow-up
    1
    arrow-down
    1
    ·
    6 days ago

    I suppose we need to make definitions clearer. C++ is memory safe in the sense that you can write memory safe code. It doesn’t enforce memory safety though. But not doing that is not the language’s fault. If someone jumps with a bike from a flying airplane, it’s not the bike’s fault that they will not land safely. It’s the misuse of the bike.

    saying that C++ is memory safe because it’s possible to use it in a memory safe manner is like saying jumping out of a plane with the bike is safe, because it’s possible to safely land (with a parachute and a lot of training).

    you always repeat that C++ is memory safe because its possible, and that “misuse” is “not its fault”.
    first, you are quite simply redefining what does memory safety mean. you basically say bombs are safe because they can be safely defused with the expertise.
    second, do you really need to misuse it to get unsafe code? it does not warn anywhere. not in the instructions, not in the compiler output.
    third, its no one’s “fault” that c++ is not memory safe. That’s not a fault of c++. like its not a fault of factories that you have to wear safery gear when working inside because otherwise you may get injured more severely. this is just a property of C++, not a judgement

    I’d argue those weren’t the best developers then.

    oh no, my suspension was correct, you are really thinking that you are the perfect coder who jever makes any mistakes. It does not make sense to argue with you

    • Zacryon@feddit.org
      link
      fedilink
      arrow-up
      2
      ·
      4 days ago

      does not warn anywhere

      This is incorrect. If you properly test your code such errors will become visible. It’s not too much of an ask to conduct systematic software testing. You should do it anyway regardless of the language used.

      you are really thinking that you are the perfect coder who jever makes any mistakes. It does not make sense to argue with you

      You are quick with being judgemental and ignoring the rest of what I said in that part, which is why I agree with you. This discussion is no longer productive.

      • WhyJiffie@sh.itjust.works
        link
        fedilink
        English
        arrow-up
        1
        arrow-down
        1
        ·
        4 days ago

        This is incorrect. If you properly test your code such errors will become visible.

        Ah, just as all the memory-mishandling related security issues in all operating systems out there. Nobody tests their shit well enough nowadays!

        You are quick with being judgemental and ignoring the rest of what I said in that part,

        Quick??? Read all your other comments man! I take it as you not wanting to accept it.

        • Zacryon@feddit.org
          link
          fedilink
          arrow-up
          2
          arrow-down
          1
          ·
          23 hours ago

          Nobody tests their shit well enough nowadays!

          I think there is indeed a lack of commitment. Thanks to capitalism and therefore production deadlines. Well, given, you can’t always catch “all” potential bugs, not just memory related issues. That’s sometimes not even theoretically possible. But it’s no secret how software quality increases by testing it thouroughly. And a lot of the time I just don’t see that happening. I’ve worked at institutions where software tests were done by answering the question “does it compile and run?”. And I’ve experienced systematic tests with specialized test engineers, who still had to cut short a lot of the time. But to assume that software is always tested well enough is in my experience naive.

          Read all your other comments man!

          This is not helpful. If you have critique, be more specific. I know what I’ve written.

          I am always open to discussion and changing my views if I see convincing arguments, as I did at another place here. Your lack of patience and quick judgement of my character is not my fault, but yours. I was discussing the issues here neutrally with you so far.

          However, this topic is done for me anyway, as the discussions here did indeed change my view regarding memory safety in C++.