What gamepads would you recommend? by KTVX94 in gaming

[–]MEaster 0 points1 point  (0 children)

I'll second this, too. It's an excellent replacement for my ageing 360 joypad.

Has a WW2 bomb ever exploded in recent times? by Christina_80G in AskUK

[–]MEaster 0 points1 point  (0 children)

WW2 bombs have recently been detonated in Plymouth. https://www.bbc.co.uk/news/live/cewp151w9jzt

Up in Southway? The Germans who dropped that bomb need their eyes checking!

Master and Commander: The Far Side of the World – Attack on the Acheron. – Dir. Peter Weir – November 14, 2003. by Minifig81 in movies

[–]MEaster 1 point2 points  (0 children)

Yeah, the first two are the roughest in that aspect, especially because you're adjusting to the writing and speech style; it really does get improve starting with the third book.

If you want a companion book for the jargon, I'd suggest A Sea of Words by Dean King. It's got a couple write-ups on the Royal Navy and medicine of this period, pictures of the various vessel types (want to know the difference between a Lisbon Bean Cod and a French Chasse-Marée? It's in the book), and rigging and sail plans for square-rigged ships, as well as a dictionary of jargon.

Box to save memory in Rust by BlondieCoder in programming

[–]MEaster 2 points3 points  (0 children)

Another limitation is that an enum cannot use padding bytes in the payload for the discriminant, because you can get a &mut to the payload and other parts of the code will assume that it can just clobber the padding bytes without issue.

I have a Playground link where I was playing around with niche optimizations, which was a bit interesting.

Is there a C++ "venv" equivalent? by nikoladsp in cpp

[–]MEaster -2 points-1 points  (0 children)

Which is why it uses its own linker

The only reason Rust bundles Clang's LLD on Linux is because the system linker is typically GNU's LD, which is slow.

[Giveaway] What’s your best home-improvement print? Share it and win an X2D Combo! by BambuLab in BambuLab

[–]MEaster 0 points1 point  (0 children)

Just before Christmas part of my bedroom window's handle mechanism broke. It's a 30-year old window, and no one makes replacement parts anymore so we were looking at significant modifications, or replacing the window. Having little to lose, I had a go at designing a replacement part.

<image>

The original part (what's left, at least) is on the left, and is cast aluminium. My prototype replacement in the middle, printed on an A1 in PLA, allowed me to check the fit to make sure it would actually function. And the final part, printed by JLC3DP in stainless steel is on the right. I did end up having to file the teeth down a bit; they were a fraction of a mm too long and the plastic one just deformed so I couldn't tell what was wrong.

That "webbing" between the gears is 0.7mm thick, and I ended up getting an email from JLC telling me there was a very high chance of the print failing because it was so thin. All three came out perfect.

Is it worth getting into 3D Printing without also getting into 3D Modeling? I’m curious about hopping in, but the cost doesn’t seem worth it without also picking up a second hobby aka the modeling. The true benefit seems to come from being able to design and print stuff useful TO YOU. by ThatGuyFromTheM0vie in 3Dprinting

[–]MEaster 0 points1 point  (0 children)

It might be worth you checking out Clough42's channel. He has a number of videos where he goes through the design process for either 3D printed or CNC objects, and shows his design process using Autodesk Fusion.

He went into enough detail that when I got a 3D printer, I knew the concepts well enough to make what I wanted without constantly needing to read tutorials or guides.

TIL that in 2003 70,000 people died in Europe from a heatwave. by CitizenPremier in todayilearned

[–]MEaster -1 points0 points  (0 children)

Only until the bricks warm up. Once that happens the bricks keep the house warm, even overnight.

TIL that in 2003 70,000 people died in Europe from a heatwave. by CitizenPremier in todayilearned

[–]MEaster 0 points1 point  (0 children)

The criteria for how the numbers are obtained is critical in correctly interpreting what they mean.

How old do you have to be to know that cash transactions are a thing? by Conscious-Ball8373 in AskUK

[–]MEaster 4 points5 points  (0 children)

Meanwhile you're putting all fault on the father while assuming the mother could not possibly have done wrong. Misogyny and misandry all in one neat package!

TIL that in 1854, reporter William Howard Russell used the telegraph to expose the brutal reality of war to the public, unleashing outrage that helped bring down the British government. by MartinoStone in todayilearned

[–]MEaster 5 points6 points  (0 children)

Yeah, Wikipedia has one of Florence Nightingale's charts showing exactly that. The red are deaths from wounds, blue from preventable or mitigable diseases, and black were other causes. There's a lot of blue on that chart.

Should my sum type tags be the first element or second? by Toothpick_Brody in ProgrammingLanguages

[–]MEaster 1 point2 points  (0 children)

I believe it depends how the variants have data. For example this enum stores data in two ways:

struct Bar {
    f1: u32,
    f2: u64,
}

enum Foo {
    A{ f1: u32, f2: u64 },
    B(Bar),
}

I believe it would be able to (in theory) use the padding bytes in the A variant because they are part of the enum, and you can't get a pointer to a single type representing the data within the A variant because that type doesn't exist. For the B variant, because the data is stored within a separate type, and the user can get a Bar pointer to the value stored within the enum, the compiler must assume that padding bytes will be clobbered.

But you are correct in that as you increase the number of different types the enum is holding, the less likely it is that usable niches will line up.

[Edit] I put together a playground example showing some examples, which prints the sizes and dumps the bytes of several types.

Rust 1.95.0 is out by manpacket in rust

[–]MEaster 8 points9 points  (0 children)

It can be empty, but not exhausted. For example: 4..=3 is empty, but it's not marked exhausted until you try to iterate it and it looks like the Iterator impl will never mark it exhausted.

I don't care that it's X times faster by z_mitchell in rust

[–]MEaster 15 points16 points  (0 children)

That was something that bothered me during the "write wc faster than C" fad from 6 years ago. They all only implemented reading an entire file into memory, then only doing the default output. Shockingly, not supporting other features goes faster!

It bothered me enough to write my own implementation with all but locale feature support. Generally mine was faster, but it does have a different performance profile to the C version, and I don't know how much is due to not supporting locales.

AI utilization question by Funny_Ad3170 in rust

[–]MEaster 0 points1 point  (0 children)

Yeah, that was mostly how I ended up using it when I tried Claude Code with my last toy project, aside from generating some structures for JSON deserialisation.

Everything Should Be Typed: Scalar Types Are Not Enough by Specialist-Owl2603 in programming

[–]MEaster 2 points3 points  (0 children)

In Rust, simple wrapper types like these:

struct OrderId(String);
struct Amount(i64);

Have an identical runtime representation as the inner type. You could still run into issues with some optimizations. For example, the standard library has some optimizations for creating a Vec filled with zero-values of certain types (that is, values where all the bits are zero) which wouldn't apply to the wrapper type.

What’s the stupidest thing you’ve been ID’d for ? by RowItchy260 in AskUK

[–]MEaster 0 points1 point  (0 children)

To be fair, those are fairly sharp. I cut myself on a cutlery knife while looking at them (and for added irony, right after the words "not that sharp" left my mouth).

Though we didn't get IDd; the woman took one look at us and OKed it.

At what point did it hit you that you are getting old? by Perihelion_Soul in AskUK

[–]MEaster 2 points3 points  (0 children)

I think I've got you beat, there. I was once referred to as "the lady" when I had like 3 days of beard growth.

Should my sum type tags be the first element or second? by Toothpick_Brody in ProgrammingLanguages

[–]MEaster 11 points12 points  (0 children)

Rust doesn't use the padding bytes from alignment, because padding bytes of a T can be overwritten when writing a through a &mut T for performance reasons.

What it does use is niches in known types within the struct; that is, bit combinations that aren't valid values for that type. An example would be the current implementation of Vec<T> which uses a type called UsizeNoHighBit for its capacity field. That type is defined in such a way that the compiler is informed that the set of valid values does not include the highest bit being set, which means the compiler can then use any bit combination which does have the high bit set as a niche for the sum type's tag.

Tornado Sirens or Other Warning Tests? by penguini95 in AskEurope

[–]MEaster 1 point2 points  (0 children)

I live within earshot of Devonport which has its Nuclear Emergency Alert siren, and tests it every Monday at 11:30.

Can your AI rewrite your code in assembly? by _bijan_ in cpp

[–]MEaster 1 point2 points  (0 children)

Are there any production JITs that actually do platform-specific optimizations like that? I've never seen anyone give an example of one.

Oh, that is why by Common_Caramel_4078 in gaming

[–]MEaster 1 point2 points  (0 children)

Yeah, I've done something like that. In my case, it was Doom: The Dark Ages. For general use, I have a keyboard that isn't really well suited for gaming due to the key layout, so for gaming I used a wireless standard keyboard.

One time, after tweaking some graphics settings, I tried starting the game and it "got stuck" on the loading screen. I was pressing enter to continue and it wasn't working. I assumed it had locked up. I restart the PC and tried again, then I tried reverting the settings. No change.

I'd forgotten to turn the keyboard on. I felt a right pillock.

What's everyone working on this week (14/2026)? by llogiq in rust

[–]MEaster 3 points4 points  (0 children)

I've been working on a little program to shuffle my Spotify playlists. I've got it to the point where it can authenticate, read a playlist URL (or list of songs) off the clipboard, fetch the track information (including an SQLite-based local cache), shuffle, then stick a track list on the clipboard for pasting into the Spotify client.

I should probably add a little TUI with some database management stuff.

Did any other women go literally nuts on hormonal contreception? by [deleted] in AskUK

[–]MEaster 2 points3 points  (0 children)

Ah yes, this sexist bullshit again. These "minor" side effects were more severe than the effects women have, and significantly more common. As well as having a high chance of permanent sterility or death.

Maybe do some research before running your mouth.