r/rust • • 15h ago

🗞️ news Anthropic: Migrating our Messages API to Rust

Thumbnail anthropic.com
267 Upvotes

r/rust • • 8h ago

📡 official blog Rust 1.100.1

Thumbnail blog.rust-lang.org
172 Upvotes

r/rust • • 17h ago

You can now use Aristotle to formally verify Rust, including unsafe and concurrent code

13 Upvotes

Hi r/rust,

I work at Harmonic on Aristotle, our formal verification tool. After launching with C and Verilog in October, Rust verification is now available for anyone to use, through the web app or CLI.

Aristotle supports safe and unsafe Rust, including concurrent code. You submit your project and describe the properties you want checked in plain English. Aristotle attempts to prove or refute them and reports the results and assumptions. You don’t need to write proofs yourselves or know Lean.

One example case study that shows what Aristotle can do is Manifest’s custom red-black-tree implementation, which uses substantial unsafe Rust. Manifest is an open-source order book on Solana; its trees store nodes directly in account memory, using unsafe accesses. Aristotle can verify properties of the existing Rust implementation, including that inserting and removing orders preserves tree validity and leaves unrelated data untouched. The invariants hold across arbitrary finite sequences of operations, under the stated preconditions. We are not aware of another tool that is able to prove such properties without any annotations or source code modifications. Across the order book, Aristotle proved 28 properties identified by Manifest as relevant. It also found a rounding bug that Manifest fixed, then verified the corrected behavior. You can explore the Aristotle run or read the full case study.

Another example is Signal’s curve25519-dalek Rust elliptic-curve library. Aristotle proved 283 specified contracts for version 4.1.3 using its serial 64-bit backend, covering field and scalar arithmetic, curve operations, and multiscalar multiplication. The Dalek run includes the results and assumptions. It verifies functional correctness of the library itself assuming correctness of external dependencies, and does not verify cryptographic security properties.

You can try Aristotle on your own project, and our Rust docs include a smaller ring-buffer example to get started. Happy to discuss the supported Rust features, the verification approach, or particular use cases.


r/rust • • 16h ago

🎙️ discussion async fn, await and pinned futures

3 Upvotes

People which works with async rust often falls into a scenario where a trait method needs to be async.

For these situations, a crate like async_trait (or dynosaur) helps a lot, but that comes to my question, if async is a rust keyword, meaning part of it is built in language itself, why Box::pin(async move {}) can't be simplified in a dyn trait as some sort of language keyword or something like AwaitableResult?

I'm not sure if there's any issue opened related to it, will check.

What you think about futures in dyn dispatch context? Something which has room for ergonomics improvement or it is good as it is by using macros?


r/rust • • 8h ago

🎙️ discussion Serious question...

0 Upvotes

Is it just me or has Rust become the default programming language of AI's? I know its lightweight and extremely fast in terms of run/consume, but whatever project i see, be it for a game server or anything else, always Rust. It wasnt like this before. Been in the run for a long time (10+ years) and i can confidently say that people DID NOT like Rust at that time because it was so hard to understand and it felt like a joke language to them (They were also saying that about PHP, lol)

Give me your opinion. Am i hallucinating?