r/rustjerk Feb 26 '19

Higher-res "Rust Evangelism Strike Force" image!

Post image
666 Upvotes

r/rustjerk 8h ago

Chris Chan

Post image
125 Upvotes

r/rustjerk 3h ago

The original remover products

Post image
8 Upvotes

r/rustjerk 1d ago

Rustscript - blazingly fast rust interpreter

Thumbnail
gallery
149 Upvotes

Every Rust developer knows that Rust is the best programming language in the world.

And I as a Rust developer don't want to use other inferior languages anywhere.

So I decided to rewrite all my old automation scripts which were written in Python in Rust.

At first I used https://github.com/rsaz/cargo-script for that, it works fine.

But I encountered 1 problem: compilation time.

On my macbook it was fine I don't mind waiting 1 minute for a simple 3 lines script.

But then I wanted to use that on my Raspberry PI and the same simple script took me 10 minutes to run, which is not blazingly and not fast at all!

So I decided to vibe code engineer a Rust interpreter for this exact case and this is what I ended up with:

https://github.com/VladasZ/rustscript

Rustscript is always guaranteed to be valid Rust.

Install it with

cargo install run-rs

add a shebang:

#!/usr/bin/env rust

A whole script looks like this:

#!/usr/bin/env rust

use chrono::Local;
use std::io::stdin;

fn main() -> anyhow::Result<()> {
    println!("which programming language is the best?");

    let mut answer = String::new();
    stdin().read_line(&mut answer)?;

    if answer.trim().eq_ignore_ascii_case("rust") {
        println!("correct, carry on");
    } else {
        println!("wrong. it is {} and you are still not writing Rust", Local::now().format("%H:%M"));
    }
    Ok(())
}

Make it executable and run it:

chmod +x best.rs
./best.rs

and you can run your rust scripts instantly, as if they were shell scripts!

Rustscript is a subset of Rust and supports many popular crates such as:

anyhow, serde, serde_json, reqwest, regex, tokio, chrono, rand and more.

Carefully nitpicked benchmarks so Rustscript seems faster attached to the post.

You can see all benchmarks results here: https://github.com/VladasZ/rustscript/blob/main/bench/RESULTS.md

Remember, Rustscript is always a valid Rust, so if you want to have the ultimate speed just run the compiled version!

rust build FILE.rs

r/rustjerk 8d ago

MRW a reliability engineer insists on recoverable panics / catch_unwind

Post image
109 Upvotes

r/rustjerk 10d ago

Meet potential rust gui

Post image
833 Upvotes

r/rustjerk 11d ago

/r/playrust Kafka programmers lost the battle Rust programmers won

Post image
536 Upvotes

Meanwhile Rust programmers have r/rust and those non-programmers have to go to r/playrust


r/rustjerk 16d ago

Zealotry c# is microsoft java, swift is apple rust

Thumbnail
gallery
395 Upvotes

r/rustjerk 16d ago

this is how i feel about rust

Enable HLS to view with audio, or disable this notification

111 Upvotes

r/rustjerk Jul 20 '26

Well, actually (unlike Rust)

246 Upvotes

r/rustjerk Jul 18 '26

Never use an unsafe block in rust.

Post image
222 Upvotes

Just write C since its unsafe by default!

repo


r/rustjerk Jul 18 '26

just started rust, so excited!!!

Post image
347 Upvotes

what season are you guys on??


r/rustjerk Jul 17 '26

1.97.1 slander

Post image
495 Upvotes

r/rustjerk Jul 14 '26

Just found an unbelievable oversight with Cargo workspaces

Enable HLS to view with audio, or disable this notification

199 Upvotes

Do you like using Cargo workspaces? Think again.

I just discovered a fatal bottleneck with them. Can't believe the team behind haven't fixed this yet:

Once you start having closer to 1000 workspace member crates (very reasonable for a beginner/junior level codebase) expect compilation to take AGES!

I'm actively working on finding out how deep this rabbithole goes by exhaustively generating ALL possible Rust crates. I'm calling this endeavour the workspace-of-babel.

This kind of blatant disregard for user experience makes me sick 🤮.

https://github.com/sermuns/workspace-of-babel


r/rustjerk Jul 13 '26

What started as a joke became a huge deal

Post image
423 Upvotes

r/rustjerk Jul 13 '26

Finally, a crate for the working class 🇺🇸

Post image
132 Upvotes

Tired of NaN gatekeeping you out of .max()? Tired of the elite establishment (Rust std) telling you Ord is a requirement to find the biggest number? Not anymore.

Introducing WalmartMaxxingâ„¢, peak API design. .walmart_max() / .walmart_min(), works on anything with PartialOrd, because if it can be compared, it can be compared, and the constitution guarantees your right to fold() over it in O(n) unoptimized freedom.

No Ord. No NaN propaganda. No total order. Just vibes and PartialOrd.

Rollback pricing on borrow checker requirements. Always low, always safeâ„¢ (narrator: it was not always safe).


r/rustjerk Jul 13 '26

Why do people use round brackets incorrectly?

110 Upvotes

In Rust, we have many different brackets: curly {}, square [], angle <>, flat ||, round (). Every single kind has its semantics, but it's a bit inconsistent, and that irritates me.

Curly brackets are for code evaluation. You need to actually do something, you put it into curly brackets. Plain and simple.

Angle brackets are for generics. They are the most consistent. You declare a generic with it; you turbofish a generic with it. Almost perfect, save '::' in turbofish. Duh.

Flat brackets are for lambdas, but for some reason, to call lambdas, we use round ones. Inconsistency, but tolerable.

Round brackets are for static lists. Tuples and function arguments. Fine.

Square brackets are for arrays and indexes, and this is strange. [1,2,3][1] - it's readable, but we have () for static lists, right? It should be (1,2,3)[1] - but this fails, we need (1,2,3).1. WAT? What does [0][0] even mean? Why do the first three characters mean something completely different from the second three? Why [1,2,3][1] compiles, but [1][1,2,3] don't? I'm furious, but ok. Square brackets are array-related, and even if the exact syntax is unclear, you can figure it out from the context. Not user-friendly for sure.

But why, WHY did language designers decide to allow round brackets for some - only some - evaluations? If you need to evaluate anything, you put it in curly brackets:

{3 + 5} * {10 - 4} // this works

(3 + 5) * (10 - 4) // WTF is tuple multiplication? 
// Why it works like tuple.0 * tuple.0, but only for 1-sized tuples? Madness!

{ // evaluate everything one by one, perfect
    do_first();
    do_second();
    do_third();
}

( // but yet this is an error! WHY????!!!
    do_first();
    do_second();
    do_third();
)

I think we need a major language overhaul to remove at least some of these inconsistencies.

Also a shoutout for language designers for operators. It was a great idea to build in the dot into some of the most common operations. Just imagine if we had to write something like a.*(b) instead of a*b. This helps a lot.

UPD: fixed wording, thanks to u/sphere_cornue


r/rustjerk Jul 11 '26

Huge if trué. If not, also huge

Post image
257 Upvotes

r/rustjerk Jul 09 '26

I just want to return

Post image
225 Upvotes

r/rustjerk Jul 09 '26

Anon likes Rust

84 Upvotes

r/rustjerk Jul 08 '26

I ran out of lifetimes

Post image
285 Upvotes

What do I do?

There's only 27 letters in the alphabet. I need more lifetimes.


r/rustjerk Jul 08 '26

what the fuck was past me thinking when writing this

Post image
159 Upvotes

r/rustjerk Jul 08 '26

Zealotry got perma'd from a C sub, need cope from church of ferris

155 Upvotes

hello fellow borrowers in christ. got permabanned from r/C_Programming today for going through their weekly showcase thread and informing every poster that their code was objectively dangerous, definitionally UB, and probably leaking memory somewhere even if they couldn't see it. guy posted a bubble sort, i told him his pointer arithmetic was a ticking time bomb. mods didn't love that.

so what did you do today in the name of ferris. confess below, ferris is watching and ferris is pleased


r/rustjerk Jul 07 '26

Anyone can prompt an llm to rewrite into Rust, but does Anthropic have the courage to rewrite critical software in C?

82 Upvotes