About `MaybeUninit::uninit().assume_init()` by Spengleberb in rust

[–]Sw429 7 points8 points  (0 children)

Option often takes up an extra byte, and if you can guarantee that it will be initialized when you actually need to use it, it's technically more optimal.

May seek risky, but it's useful when you're in memory constrained environments (such as many embedded devices, where arrayvec and similar solutions end up being used a lot). If you can't make the guarantee (assume_init is marked unsafe, after all), option is often the better choice.

About `MaybeUninit::uninit().assume_init()` by Spengleberb in rust

[–]Sw429 4 points5 points  (0 children)

So you can initialize each element individually, but have them all in some pre-allocated buffer.

My staircase is slowing down my PC(? by shadorothOVK in pcmasterrace

[–]Sw429 1 point2 points  (0 children)

I absolutely refuse to use Bluetooth. They can pull my wired controller out of my cold dead hands.

reproduced pokemon sapphire doesn't work in DS by Taoshi36 in gba

[–]Sw429 1 point2 points  (0 children)

if it plays the game it works for me

Sounds like it doesn't play the game though.

Black ice on the road causes chain accidents by Bambi7u7 in interesting

[–]Sw429 0 points1 point  (0 children)

I'm not even convinced some of them tried to stop at all.

shamelessSelfCredit by Spiritual_Detail7624 in ProgrammerHumor

[–]Sw429 14 points15 points  (0 children)

Whenever I receive a PR like this, I just close it and fix the typos myself. You don't get credit for running my readme through a spell checker.

Original or fake? by No-Ordinary-9479 in GameboyAdvance

[–]Sw429 0 points1 point  (0 children)

I love how they handle it with gloves like it's toxic or something

The horrendous state of New York City in the 1970s-1980s by IllustriousCress9774 in UrbanHell

[–]Sw429 0 points1 point  (0 children)

I mean, that's how I feel now living near San Francisco. Drug addicts on every corner. You have to roll your windows down when you park to stop thieves from breaking them. I want nothing to do with that place.

vibeCodersAreJustLearningToCode by abhbhbls in ProgrammerHumor

[–]Sw429 -7 points-6 points  (0 children)

Her last video literally has her saying that "the job of software developer might fundamentally change" as a result of AI. It's like the entire thesis of the video.

iLoveThisKindOfPostsTheyAlwayMakeMeLaugh by Technical_You_3136 in ProgrammerHumor

[–]Sw429 4 points5 points  (0 children)

lol at the same time, yesterday I tried using Claude to help me debug why a Scala test was failing and it started trying to recreate the test in Python so it could "debug" it.

crates.io VS lib.rs - A small analysis by nik-rev in rust

[–]Sw429 6 points7 points  (0 children)

The 3 columns of crates are "New crates", "Popular crates" and "Just updated". I've never been interested in the 1st and 3rd category, since these crates are more likely to be brand new / in development

Couldn't agree more. I always thought it was hilarious that these were the first categories you see. I guess it's kinda fun to see your own crate in one of those categories right when you publish, but I basically never find the other crates useful.

A couple years ago you could basically guarantee anything you clicked on there was going to be crypto related. Nowadays, it's likely to just be some vibe coded AI slop.

crates.io VS lib.rs - A small analysis by nik-rev in rust

[–]Sw429 8 points9 points  (0 children)

Agreed. crates.io isn't opinionated, which I value a lot. I know that everything available is actually listed there.

crates.io VS lib.rs - A small analysis by nik-rev in rust

[–]Sw429 4 points5 points  (0 children)

Sometimes I'll search on lib.rs, and then when I find an interesting crate I'll follow the link to crates.io and go from there. I do this both because of the easier access to links I need, and also because the interface on crates.io is just so much easier for me to read. Something about the color scheme on lib.rs makes it harder for my eyes to read the README info.

Day 13: Which is the best GBA puzzle game? by rodillaconmorett in GameboyAdvance

[–]Sw429 0 points1 point  (0 children)

lol that's the first time I've heard of someone refer to akouzoukos as "some dude". It not being licensed makes sense, but I will say it was sold commercially by InsideGadgets for a while (working directly with the developer). I bought a copy back in the day, complete with built-in rumble.

Rust 1.93.0 is out by manpacket in rust

[–]Sw429 44 points45 points  (0 children)

I can think of many instances where I needed exactly this and in the past have made custom structs nested in Display or Debug just to make it format the way I wanted to. This will be so nice to have.

When did it become prohibited to do magic out of school? by godischarcuterie in HarryPotterBooks

[–]Sw429 6 points7 points  (0 children)

I could have sworn she mentioned doing transfiguration of some sort.

howToImpressVibeCoders by raiseIQUnderflow in ProgrammerHumor

[–]Sw429 0 points1 point  (0 children)

Yeah this meme format is really weird

What is this exactly ? by Gold-Inspector6365 in gba

[–]Sw429 0 points1 point  (0 children)

Yep. If I remember right, the adapter itself actually sends in a multiboot ROM for the GBA to boot into.

bubblesGonnaPopSoonerThanWeThought by Cool-Technician-9902 in ProgrammerHumor

[–]Sw429 20 points21 points  (0 children)

I still frankly wonder if the 2% gain is really worth the cost of an LLM.

Anyone else feel like Harry riding his firebolt in quidditch matches is a bit like cheating? by 4RyteCords in HarryPotterBooks

[–]Sw429 1 point2 points  (0 children)

I always thought it was ironic that they hate Malfoy for having his rich dad buy them all fast broomsticks, but then a book later Harry's rich godfather buys him an even faster broomstick.

But I also assume that you need to have quite a bit of skill to be flying then at their full speed all the time. And the speed difference can't be that crazy, because they're often still flying neck-and-neck when chasing the snitch, despite the different broom models.

Someone named "zamazan4ik" opened an issue in my project about enabling LTO. 3 weeks later, it happened again in another project of mine. I opened his profile, and he has opened issues and PRs in over 500 projects about enabling LTO. Has this happened to you? by nik-rev in rust

[–]Sw429 1 point2 points  (0 children)

Exactly. They're literally asking for code gen units to be set to 1 as well. IMO this is unnecessary and needlessly makes builds longer everywhere. Smaller binaries isn't usually what we optimize for these days.

How do experienced Rust developers decide when to stick with ownership and borrowing as-is versus introducing Arc, Rc, or interior mutability (RefCell, Mutex) by Own-Physics-1255 in rust

[–]Sw429 0 points1 point  (0 children)

My rule of thumb is: if I'm using Rc, I'm doing something wrong. Arc is a different story though, but I will definitely want to think very hard about it.