Get the latest tech news

Rust’s worst feature


* available in Rust nightly. There are several aspects of Rust that I’m not particularly fond of but the one that takes the cake is core::io::BorrowedBuf which I despise with passion.

Change to the compiler, its options, modification of unrelated parts of the code or using the function for a different Read trait implementation may break the program in unpredictable ways. MADV_FREE flag of the madvise system call allows user space to advise the kernel that (until next write) it no longer cares about contents of specified anonymous pages. They may require switching to nightly compiler, patching third-party crates, going straight to doing unsafe syscalls (e.g. read) or isolating critical code paths and writing them in C.

Get the Android app

Or read this on Hacker News

Read more on:

Photo of Rust

Rust

Photo of worst feature

worst feature

Related news:

News photo

Parsing PDFs (and more) in Elixir using Rust

News photo

Linux 6.14 With Rust: "We Are Almost At The 'Write A Real Driver In Rust' Stage Now"

News photo

HawkEye: A Simple license header checker and formatter in Rust