News for hackers. Stuff that matters.
Re:Malicious Rust crate Arrayref runs a build-time payload by 0cf8612b2e1e on Thursday August 20, 2026 @11:47AM (#49376290)
On the other hand, there are some bad Go standard libraries that are frozen in time.
Re:Malicious Rust crate Arrayref runs a build-time payload by rirze on Thursday August 20, 2026 @11:58AM (#49376429)
which, as painful as it may be, is ok. Better to have a safe functional stdlib library than a exposed external crate (which then asks the question; what's the replacement...)
Re:Malicious Rust crate Arrayref runs a build-time payload by lesuorac on Thursday August 20, 2026 @12:38PM (#49376962)
Those aren't the only two choices.

We also have the classic example of PHP with numerous not safe stdlib ways to use mysql.

To me the answer is still to vendor your dependencies and don't be on the bleeding edge of updates unless you're willing to invest the time into validating them.

Re:Malicious Rust crate Arrayref runs a build-time payload by kergonath on Thursday August 20, 2026 @02:19PM (#49378235)
> We also have the classic example of PHP with numerous not safe stdlib ways to use mysql.

I think it goes without saying that emulating PHP is rarely a good decision.

Re:Malicious Rust crate Arrayref runs a build-time payload by VorpalWay on Thursday August 20, 2026 @06:19PM (#49381046)
Don't forget C++ where large parts of the standard library are unusable (regex is slow and unfixable) or soft deprecated (dont use iostreams for formatting, use std::format, etc).

No, I prefer what rust is doing. It suits a system programming language. Which is what Rust is.

Re:Malicious Rust crate Arrayref runs a build-time payload by pjmlp on Friday August 21, 2026 @02:15AM (#49384411)
Regex does the job for most business software, iostreams is alright, using them since 1993, std::format is cool provided one has control over their compiler version,...
Re:Malicious Rust crate Arrayref runs a build-time payload by VorpalWay on Friday August 21, 2026 @06:49AM (#49386268)
Regex is absolutely not suitable for most use cases that I have come across. Iostreams formatting is awful, especially if you care about internationalization (which is very common).

Not sure what the issue with std::format would be here, you would have to elaborate. Obviously you need to specify a minimum version to have support for it at all.

Re:Malicious Rust crate Arrayref runs a build-time payload by pjmlp on Friday August 21, 2026 @07:36AM (#49386584)
It works good enough for stuff I would be using Java or .NET for.

Not every application requires internationalisation, especially server code or internal company tools.

Re:Malicious Rust crate Arrayref runs a build-time payload by bigstrat2003 on Thursday August 20, 2026 @01:06PM (#49377305)
Which isn't actually a problem. You can ignore the bad standard library and use something different.
Re:Malicious Rust crate Arrayref runs a build-time payload by pjmlp on Thursday August 20, 2026 @02:20PM (#49378246)
Yeah, but I will take a not great library that works everywhere the compiler does, than be at the whims of which platforms are supported by 3rd party libraries.

I can use most of the clunky Python, Java, .NET and if it must be, Go, standard libraries, than hunting down for dependencies with platform tier support and such.

Re:Malicious Rust crate Arrayref runs a build-time payload by dwattttt on Thursday August 20, 2026 @04:17PM (#49379670)
Add more and more to a standard library, and you're going to start losing your "works everywhere".
Re:Malicious Rust crate Arrayref runs a build-time payload by pjmlp on Thursday August 20, 2026 @05:26PM (#49380499)
Naturally there is a balance, still I think Java, .NET, Python, Go, Smalltalk, manage quite well, while having subsets to slim down when needed for specific deployment scenarios like embedded devices.
Re:Malicious Rust crate Arrayref runs a build-time payload by kelnos on Friday August 21, 2026 @01:25AM (#49384142)
It's interesting that you include Java in there, as I've worked on some pretty bog-standard Java code bases where the dependency tree didn't look all that different from a cargo project's.
Re:Malicious Rust crate Arrayref runs a build-time payload by pjmlp on Friday August 21, 2026 @02:13AM (#49384401)
It starts by those that reach out for Log4J, when java.util.logging.Logger already does the job.

Guava for whatever cool reason, and so on.

Re:Malicious Rust crate Arrayref runs a build-time payload by pie_flavor on Thursday August 20, 2026 @02:21PM (#49378267)
Platform support is a non-issue for every library being discussed. This is an array construction macro, it has nothing to do with what operating system you're running on.
Re:Malicious Rust crate Arrayref runs a build-time payload by pjmlp on Thursday August 20, 2026 @02:57PM (#49378676)
Just because some trees have a specific trait, it doesn't mean the whole forest is the same.
Re:Malicious Rust crate Arrayref runs a build-time payload by imtringued on Friday August 21, 2026 @04:46AM (#49385469)
Your argument only works for no_std crates, but the std exists and allows the vast majority of crates to be cross platform out of the box.
Re:Malicious Rust crate Arrayref runs a build-time payload by pjmlp on Sunday August 23, 2026 @08:06AM (#49408147)
I bet there are plenty of them that don't work on IBM i, while Java does fine there.

Just to quote a possible scenario among others.

Re:Malicious Rust crate Arrayref runs a build-time payload by VorpalWay on Thursday August 20, 2026 @06:15PM (#49380999)
Which is how you get the mess that is the standard library of C++. Where regex is an unusably slow joke and everyone uses third party libraries for that instead.

And tons of parts of the standard library (and language) being cordoned off as "legacy, don't use for new development". Of course figuring out what you shouldn't use in C++ can be hard too. It isn't well documented (or universally agreed upon), and it takes having it as a full time job to be able to keep up with these days.

No, I much prefer the way Rust is doing it.

Re:Malicious Rust crate Arrayref runs a build-time payload by pjmlp on Friday August 21, 2026 @02:12AM (#49384394)
Regex drama is overblown, it is quite usable for most business purposes.

Sure, it would be great if the volunteers that contribute to C++ compilers, would improve regex instead of adding the gazillion of features that each ISO C++ standard requires, mostly on their free time, because devs can't be bother to pay for compilers.

Additionally the companies that actually sponsor those compilers also have bigger priorities than improving regex implementation.

Finally if you want to stick regex into a micro-benchmarks context, there are plenty of options out there, as you point out.

The Rust way, like you can have any async runtime, as long as it is Tokio?

Re:Malicious Rust crate Arrayref runs a build-time payload by VorpalWay on Friday August 21, 2026 @06:46AM (#49386237)
Regex issues aren't at all overblown, at least in the fields I have worked in or in fields of people I have talked to.

As for async in Rust, I wrote in another comment that yes that is an issue. What we need is std to define traits that all the different runtimes can implement. Because there are absolutely reasons to use alternative runtimes, depending on what you do. I mostly use embassy (embedded microcontroller development) for example. And if you want thread-per-core with io-uring you want glommio or monio. Smol is simple and compact.

I could also see uses for async in desktop GUI or gamedev (but to my knowledge there isn't any runtime suitable for those domains yet).