Hiker, software engineer (primarily C++, Java, and Python), Minecraft modder, hunter (of the Hunt Showdown variety), biker, adoptive Akronite, and general doer of assorted things.

  • 2 Posts
  • 1.22K Comments
Joined 2 years ago
cake
Cake day: August 10th, 2023

help-circle




  • But they are not the default option. And your new job may not use them.

    Who cares if it’s the default? If it’s the best tool, use it.

    It’s silly to have a reason for “going Rust” be the build system, especially in the context of something as new as a WASM context where basically any project is going to be green field or green field adjacent.

    Exceptions is a non standard exit point. And by “non standard” I’m not talking about the language but about its surprise appearance not specified in the prototype. Calling double foo(); you don’t know if you should try/catch it, against which exceptions, is it an internal function that may throw 10 level deep ?

    And that’s a feature not a bug; it gets incredibly tedious to unwrap or forward manually at every level.

    By contrast fn foo() -> Result<f64, Error> in rRst tell you the function may fail. You can inspect the error type if you want to handle it. But the true power of Result in Rust (and Option) is that you have a lot of ergonomic ways to handle the bad case and you are forced to plan for it so you cannot use a bad value thinking it’s good:

    You can do this in C++ https://en.cppreference.com/w/cpp/utility/expected (and as I said, if you feel so inclined, turn off exceptions entirely); it’s just not the “usual” way of doing things.



    1. It’s statically compiled and isn’t dependent on system binaries and won’t break if there if the system has the wrong version like C/C++, allowing you to distribute it as a single binary without any other installation steps

    You can do that with C++ too.

    1. Still produces fairly small binaries unlike languages like Java or C# (because of the VM)

    I mean, the jars are actually pretty small; but also I really don’t get the storage argument. I mean we live in a world where people happily download a 600 MB discord client.

    1. Is a modern language with a good build system (It’s like night and day compared to CMake)

    Meson exists … as do others.

    1. And I just like how the language works (errors as values etc.)

    Fair enough; though why? What’s wrong with exceptions?

    I work in a code base where I can’t use exceptions because certain customers can’t use exceptions, and I regularly wish I could because errors as values is so tedious.











  • Yes, Trump trying to take Palestine for the US, possibly with US troops was preventable.

    Was all loss of human life preventable? No, because the US Govt does not control Isreal but considers its relationship with Israel critical.

    People need to get off their high horses and vote on the spectrum, not on single issues.

    I didn’t like everything about Kamala but acting like not voting in protest was “the right thing to do” is not a good answer. I hate that our bombs were used on Palestinians, but people need to accept their protest vote moved things one step backwards.

    You’re doing a lot of talking about “not driving a wedge”, but I didn’t drive a wedge. I voted for the clearly more qualified candidate, some others decided “I don’t like what that candidate has done for Israel, so even though I agree with her on so many other things, I’m not voting for her.”

    The wedge is these idiotic purity tests the left keeps applying where “if you don’t agree on this particular issue, you’re not one of us, and you don’t get my vote.”

    It’s obnoxious that these folks had the audacity to tell people “if you vote for Kamala you’re a horrible person because Palestinians will die.” You know who’s going to die because of their vote? Lots of people. Climate change and pollution kills. The destruction of the US AID office kills. Disease kills. Between the three, we may see many many more deaths than we can even fathom.




  • I don’t know; it’s one of those weird things where digital “cost to copy” being cheap really makes things problematic.

    Unlike BitTorrent you were giving away your access to that item and possibly never getting it back; we don’t really have a standard way of doing stuff like that in the digital era. The closest thing we have is very clunky, greedy, and intrusive DRM systems.