• 53 Posts
  • 1.07K Comments
Joined 4 年前
cake
Cake day: 2023年4月27日

help-circle








  • Let me ask a question, then: why were the Linux kernel and the Linux ecosystem written in C rather than Python?

    … because C is a systems langauge that you can use to build a kernel? While Python is an interpreted runtime that cannot target bare-metal?

    Rust can easily take the place of C, as Rust can also target bare-metal. It can do everything that C can do (perhaps aside from compiling to some very esoteric platforms). The reason Linux is written in C is cause C was the best option at the time, not because C is some magical language that can do stuff that no other language can.

    Also, just because Linux was written in C doesn’t mean it is the best-known, most famous or most widely used language. Python is much more well-known and widely used than C.


  • I don’t know where you’ve heard this, but none of it is true. Rust is definitely used for low-latency trading, and that’s actually one place where it really shines.

    sharing memory addresses across code intentionally having the same address written to and read from across threads. Something rust is sort of designed to not support.

    C++ does not “support” that either. C++ will let you write that code, but if you write code like that in C++, it’s undefined behavior and trust me, no low-latency trading firm wants undefined behavior in their trading software (just imagine what could go wrong…).

    Rust helps you avoid such issues. However, Rust definitely “supports” undefined behavior in the exact same way. If you want to share mutable pointers across threads and you don’t give a crap about undefined behavior… I mean, that’s really, really stupid but you can just write unsafe and then you can do exactly what you can do in C++ as well.



  • but no language can take the place of C

    Why do you say that? I definitely think Rust can take the place of C. Not just can actually, I’d go as far as to say that Rust should take the place of C. C is much too unsafe to be used in today’s age. There’s really no excuse to use a memory unsafe language today if you’re starting something new.

    It would not have been better if it was written in C. Rust is just as fast and much better.


  • I’m a professional software engineer writing Rust for many years now.

    Honestly, I am very happy that AI is using Rust. Much better that AI uses Rust than Python! If you think AI written Rust is bad, you have no idea how sloppy AI written Python is.

    Rust is a great language. Turns out the same stuff that makes it great for humans also makes it great for agents. This is not a bad thing, this is a win-win.

    Historically, Rust’s biggest disadvantage has been how hard the language is to write and how much you sometimes need to fight the compiler. This disadvantage is quite effectively mitigated by AI, since you can let the AI fight the compiler and write most of the code. So you get all the advantages that Rust brings with basically none of the downsides.

    I’m just happy that Rust was invented before LLMs. If Rust did not exist before LLMs, the code the AIs would be writing would be a lot worse.

    Hope that answers it.






  • You may not agree with how we raise our kids around these parts, but it sure does work better than what you’ve got going on, you fucking worthless American pussies.

    This is unnecessarily rude and derogatory towards many, many people, and not a tone we condone on Feddit.dk (see our site-wide rule 1). These rules also apply to you as a user when commenting in external communities. Please keep that in mind. We expect Feddit.dk users to be respectful in external communities, as we do not want Feddit.dk to be associated with bad behaviour.



  • You need to stop thinking like the fediverse is a popularity contest. The fediverse is not about anyone “winning”, it’s not about one app or service becoming “the” place to be. The fediverse is not like the big tech closed social media platforms.

    If you like Piefed, you should use it. If you prefer Lemmy, use that. If you want to make your own fediverse service, you can do that.

    If Piefed suddenly gets super popular, everyone wins cause Piefed connects to everyone else, like Lemmy and Mastodon does too.

    A rising tide lifts all boats. The point of the fediverse is not winning, but choice. Everyone has their own choice to make about their use of software, and nobody has to force that choice upon you.