This is terrifying on so many levels.
- 10 Posts
- 60 Comments
It’s new(ish): https://science.nasa.gov/moon/moon-water-and-ices/
jjj@lemmy.blahaj.zoneto
196@lemmy.blahaj.zone•post a rule of a folder day. DAY 3 [OC, brainmade]English
6·14 days agoRecently cleaned up the filegarden folders for my mspfa:

(I used to give a vibes based name to each image and append _2/_3/etc if it was a duplicate, this way i can also sort them by page number)
jjj@lemmy.blahaj.zonetoPhotography@lemmy.world•The try hard baltic sea sunset, it even has a little waterspout 😂
4·15 days agoReminds me of an orange yolked egg.
jjj@lemmy.blahaj.zoneto
Technology@lemmy.world•Here's how to block Meta from using your Instagram pictures for its AIEnglish
6·16 days ago- ArfArfWoof, 2026
(came here to say this)
Relevant xkcd: https://xkcd.com/329/
these rules are affected by whether you can or can’t edit the referenced data
Yes, but not quite. They are affected by whether something else is allowed to look at the referenced data at that time. You can mutate data behind a shared reference with interior mutability: https://doc.rust-lang.org/reference/interior-mutability.html
I recommend you and everyone start here: https://doc.rust-lang.org/book/
(there’s even an interactive version with quizzes, etc)
Just thought to do a search, and it seems it’s a popular title: https://www.newgrounds.com/search/conduct/audio?suitabilities=etm&c=3&terms=stardust
In other news, you’ve got a lot of nickels, I guess.
Oops, forgot the
https://www/.part. Your links show as broken images for me, the ! should be omitted.
Code? I would fucking love it if games just let you download the code. (there are even some paid games which do btw)
You’ll get the obfuscated compiled binary, because fuck you, that’s why.
Rust is often treated like it has a split between mutable and immutable state, but it’s really a split between unique and shared state. Shared state can be mutated if certain invariants are held, which types that provide “interior mutability” as its called enforce.
https://doc.rust-lang.org/reference/interior-mutability.html
Cell doesn’t disable memory safety, though? It comes with additional restrictions such as being unable to share between threads (statically enforced) obviously, it’s not an unsafe feature. You also can’t read from it unless your type can be bitwise copied, etc.
Interior mutability is mostly for making immutable interfaces that for some reason or another benefit from storing a bit of mutable state, such as for lazy evaluation. It’s also used for cross thread communication in some cases since you have to use shared (immutable) references to share things between threads.
It requires a lot of nigh-illegible boilerplate code to even compile
this is the entire source code for an app that performs a rather complex function, note the absence of boilerplate
from https://codeberg.org/Mycellf/wordjoin
use std::{ fs::File, io::{self, BufRead, BufReader, Read, Write}, path::PathBuf, }; use clap::{Parser, ValueEnum}; use icu_segmenter::{ LineSegmenter, LineSegmenterBorrowed, options::{LineBreakOptions, LineBreakStrictness, LineBreakWordOption}, }; /// Insert utf-8 word joiners (U+2060) to prevent text from wrapping outside of whitespace characters. #[derive(Parser)] struct Args { /// Format and concatenate each file in stead of stdin file_paths: Vec<PathBuf>, /// Read stdin by line instead of all at once /// (sometimes worse for interactive use; files are always read by line) #[clap(short = 'l', long)] by_line: bool, /// See https://drafts.csswg.org/css-text-3/#line-break-property #[clap(short, long, default_value = "strict")] strictness: LineBreakStrictnessValues, /// See https://drafts.csswg.org/css-text-3/#word-break-property #[clap(short, long, default_value = "normal")] word_option: LineBreakWordOptionValues, /// Print this app's GNU GPL-3.0 license #[arg(short = 'L', long)] license: bool, /// Print this app's source code #[arg(short = 'S', long)] source: bool, } const WORD_JOINER: char = '\u{2060}'; fn main() -> io::Result<()> { let args = Args::parse(); if args.source || args.license { if args.source { println!( "Cargo.toml:\n{config}\n\nsrc/main.rs:\n{source}\n\nREADME.md:\n{readme}", config = include_str!("../Cargo.toml"), source = include_str!("main.rs"), readme = include_str!("../README.md"), ); } if args.license { println!("LICENSE:\n{}", include_str!("../LICENSE")); } return Ok(()); } let mut options = LineBreakOptions::default(); options.strictness = Some(args.strictness.into()); options.word_option = Some(args.word_option.into()); let segmenter = LineSegmenter::new_auto(options); let mut stdout = io::stdout().lock(); if args.file_paths.is_empty() { let stdin = io::stdin(); if args.by_line { join_text_by_lines(stdout, stdin, segmenter)?; } else { join_text_by_all(stdout, stdin, segmenter)?; } } else { for path in args.file_paths { let file = File::open(path)?; join_text_by_lines(&mut stdout, file, segmenter)?; } } Ok(()) } fn join_text_by_lines( mut writer: impl Write, text: impl Read, segmenter: LineSegmenterBorrowed, ) -> io::Result<()> { for line in BufReader::new(text).lines() { let line = line?; join_text(&mut writer, &line, segmenter)?; writeln!(&mut writer)?; } Ok(()) } fn join_text_by_all( writer: impl Write, mut text: impl Read, segmenter: LineSegmenterBorrowed, ) -> io::Result<()> { let mut input = String::new(); text.read_to_string(&mut input)?; join_text(writer, &input, segmenter)?; Ok(()) } fn join_text( mut writer: impl Write, text: &str, segmenter: LineSegmenterBorrowed, ) -> io::Result<()> { let mut segments = segmenter.segment_str(text).peekable(); while let (Some(start), Some(&end)) = (segments.next(), segments.peek()) { let segment = &text[start..end]; write!(writer, "{segment}")?; if end < text.len() && segment .chars() .next_back() .is_some_and(|end| !end.is_whitespace()) { write!(writer, "{WORD_JOINER}")?; } } Ok(()) } #[derive(Clone, ValueEnum)] enum LineBreakStrictnessValues { Loose, Normal, Strict, Anywhere, } impl From<LineBreakStrictnessValues> for LineBreakStrictness { fn from(value: LineBreakStrictnessValues) -> Self { match value { LineBreakStrictnessValues::Loose => LineBreakStrictness::Loose, LineBreakStrictnessValues::Normal => LineBreakStrictness::Normal, LineBreakStrictnessValues::Strict => LineBreakStrictness::Strict, LineBreakStrictnessValues::Anywhere => LineBreakStrictness::Anywhere, } } } #[derive(Clone, ValueEnum)] enum LineBreakWordOptionValues { Normal, BreakAll, KeepAll, } impl From<LineBreakWordOptionValues> for LineBreakWordOption { fn from(value: LineBreakWordOptionValues) -> Self { match value { LineBreakWordOptionValues::Normal => LineBreakWordOption::Normal, LineBreakWordOptionValues::BreakAll => LineBreakWordOption::BreakAll, LineBreakWordOptionValues::KeepAll => LineBreakWordOption::KeepAll, } } }
Rust is all about changing internal state. It even has structures (Cell and others) that specifically allow you to change internal state in otherwise immutable data structures. You should probably learn rust properly before making such claims about it.
Every foreign language is unreadable until it is not foreign. Acquiring programmer socks helps, too.
There is ALWAYS ALWAYS ALWAYS an xkcd: https://xkcd.com/2248/
Practically, dynamic typing is quite different from no typing, such as with the B programming language, although I agree that it often defeats certain benefits of type systems.
strong typing
Grrrrrrr. (this term is ambiguous but still very popular for some reason https://en.wikipedia.org/wiki/Type_safety#Strong_and_weak_typing)
There are other well defined ways to describe a type system, such as:
- Static vs dynamic
- Implicit vs manifest
e.g.
- Rust’s is mostly static and sometimes optionally implicit
- Haskell’s is static and optionally implicit
- Python’s, Lua’s, etc is dynamic and implicit
- C’s is static and manifest
For every MEAL YOU BUY A MEAL NO LOITERING POLICE ENFORCED
Thanks for coming to my (your) TED talk.
This looks great!
Bullet hell games are normally not my thing
It turns out genre doesn’t have to do with one’s preferences as much as the distribution of execution/planning/adaptation challenges:



Is webp ok?
https://pictrs.blahaj.zone/pictrs/image/1c6552a7-7ef2-4e13-a559-dcf75492b08e.webp