Follow

rustlang silly pseudocode 

Developing unsafe abstractions in Rust:

use dev::Dev::{self, UnsafeAbstraction, ProgramFault};

loop {
let design = Dev::idea(UnsafeAbstraction);
let impl = design.prototype();
loop {
while impl.typeck().is_err() {
impl.hack();
}
while impl.borrowck().is_err() {
impl.hack_more();
}
let binary = impl.build().unwrap();
match binary.run() {
Ok(_) => {
impl.commit();
impl.forget_what_any_of_this_means();
return
},
Err(e) => match e {
ProgramFault::Err | ProgramFault::Panicked
=> impl.debug(),
ProgramFault::Incorrect
=> impl.debug_desparate(),
ProgramFault::Crashed => {
use Drop::drop as fuck_this;
fuck_this(impl);
fuck_this(design);
if Dev::really_not_feeling_it() {
panic!("aaaaa")
} else {
eprintln!("not this time");
break
}
}
}
}
}
}

(inspired by but not based on: twitter.com/LinaAsahi/status/1)

SubwayTooter 1 0 1

re: rustlang silly pseudocode 

This was just gonna be a list where "typecheck" and "borrowcheck" were repeated several times and then the program crashed and was thrown out at the end. But that felt unfair and I didn't want to be negative or exclusive. And then it kind of got out of hand,,, :blobsweats:

behind the post, mh med re: rustlang silly pseudocode 

And my ADHD is being partially medicated so my hyperfocus ran unchecked and I could just finish my idea instead of being distracted and abandoning it. Which resulted in a post that is probably not that funny.

But hey I managed to fit it in the character limit without even trying that much! The tiny indentations weren't even to save characters for the most part, they were saving post width lmao

There was going to be program output too, to capture the intent of my original joke (but presenting it as "one possible outcome of a process" instead of "the only result of a process"). But I couldn't think of a way to write it that would have been concise *and* funny enough...

Sign in to participate in the conversation
Cybrespace

the mastodon instance at cybre.space is retiring

see the end-of-life plan for details: https://cybre.space/~chr/cybre-space-eol