Skip Navigation

InitialsDiceBearhttps://github.com/dicebear/dicebearhttps://creativecommons.org/publicdomain/zero/1.0/„Initials” (https://github.com/dicebear/dicebear) by „DiceBear”, licensed under „CC0 1.0” (https://creativecommons.org/publicdomain/zero/1.0/)AS
Posts
5
Comments
679
Joined
2 yr. ago

  • You can do all that with Rust. Maybe C/C++ is good to teach if the professor explains why they should almost never be used, but IMO it would probably be better to just educate them using a well designed language like Rust so that they have the experience for a career.

  • IMO the "stuck in their ways" isn't about experience at all. It's about good or bad devs. I've seen green devs stuck in their ways.

    Sometimes managers or devs who don't know any better think that knowing the right thing to do is the same as being inflexible, because they don't understand the rationale since they aren't experienced programmers.

  • Rust is mainly designed to overcome common memory problems people have with low level C systems without the overhead of garbage collectors

    So you didn't read my comment then.

    A concrete example of what my comment means is opening files. When you open a file handle, you can read from it, write to it, but then you should close it. After you close it you shouldn't be ready to or write from it again. If you do, bad things can happen.

    Rust is the only language where you cannot. It's a compile time error. This has nothing to do with low level systems programming. Using file handles is very high level.

    Same goes for thread safety. Web servers often can benefit from multithreading. Java does not enforce thread safety at compile time. If you send some data across threads and you don't already understand what is thread safe and what isn't, you'll end up with data races, which is a form of memory safety violation. This is not possible in Rust, but it is in Java.

    Rust also isn't subject to "the billion dollar mistake" since it doesn't have the concept of null references. It also doesn't support exceptions, which are the exact same issue as null references. These are also general programming problems and not specific to low level systems.

    Regarding frameworks, I've used Spring before and, although Rust doesn't do some things Java frameworks do, IMO that's a very good thing, and the web frameworks I've used in Rust have been a far better experience than what I saw from Spring.

  • Rust is a general purpose language which is excellent for API servers and many other things. I'd say it's definitely a direct competitor to Java. The only difference is in the ecosystem of libraries.

    Rust's type system is really just about enforcing correctness, which is very important in a general sense. Memory safety is just a subset of correctness.

    You can see this is in practice since there are a TON of devs like myself coming to Rust from JavaScript.

  • Libraries are physical media. If you get public access to a newspaper, then one person can read it at a time. You also create a barrier for people to have to drive to a library, which might be closed, hope that nobody else checked out the thing, etc.

    It's not at all a solution.

  • It's a double edged sword. Quality information should be accessible to everyone. We ensure that for kids through public school systems, but for adults you need to pay for it yourself. Which is a huge problems since that is the same demographic as "voters".

  • You friend is insane and making the problem worse. Tell them to stop.

    Even in the US, where tipping has been out of control for a long time, nobody in their right mind tips for takeout. The employee literally didn't do a damn thing other than a couple seconds of handing you a box and possibly cashing you out.

  • "he wasn't actually paid in money. it was just the value of the gold bullion he received".

    Is that better somehow? I never understood this logic. Money itself is existentially just paper with no value until you spend it on something, and its value also rises and falls based on other factors. It's basically stock in the US economy.

    Why is it not okay to give someone one kind of paper but not another?