@firelizzard@programming.dev avatar

firelizzard

@firelizzard@programming.dev

Principal Engineer for Accumulate

This profile is from a federated server and may be incomplete. Browse more on the original instance.

firelizzard,
@firelizzard@programming.dev avatar

so you have to catch all exceptions then do extra work to tell what the specific situation is

That’s horrifying. That’s a solid reason to avoid Python like the plague.

firelizzard,
@firelizzard@programming.dev avatar

I’ve done a little bit of Python in the past, the biggest thing being an automation task that borderline became an app. I certainly can imagine using it for scripts, though I default to bash because that’s almost always available but TBH mostly because inertia. Beyond that my default is Go because inertia (and I love Go). I watched a video by the Primeagen (on YT) - in his view, Rust is better for text/data pipelines and CLI tools. Being very familiar with Go and not at all familiar with Rust, that’s an interesting take because honestly writing a CLI in Go is kind of meh.

firelizzard,
@firelizzard@programming.dev avatar

I think it’s a joke about the song being copyrighted

firelizzard,
@firelizzard@programming.dev avatar

Not that they are shit tbf.

That’s your opinion. My opinion is that Windows is a garbage fire.

firelizzard,
@firelizzard@programming.dev avatar

For references within a scope, you’re probably right. For references that cross scope boundaries (i.e. function parameters), they necessarily must consume memory (or a register). Passing a parameter to a function call consumes memory or a register by definition. If a function call is inlined, that means its instructions are copy-pasted to the call location so there’s no actual call in the compiled code.

firelizzard,
@firelizzard@programming.dev avatar

“Feeding garbage to OCR” is a really boring way of generating text. I was assuming it would be something more interesting, like creating a symbolic representation of the splatters and generating text from that. Using OCR is basically piping /dev/urandom to perl and seeing what happens. The fact that they’re valid perl programs is worth a laugh but the generation method is totally uninteresting.

firelizzard,
@firelizzard@programming.dev avatar

The whole point is that random character sequences are often valid Perl

When I read the headline I also assumed “valid Perl program” meant it did something interesting. I was expecting to read an article about an interesting image to text conversion process that produced non-trivial Perl programs.

firelizzard,
@firelizzard@programming.dev avatar

Better to not have version control!? Dear god I hope I never work on anything with you.

firelizzard,
@firelizzard@programming.dev avatar

Ah, yeah that makes a lot more sense

firelizzard,
@firelizzard@programming.dev avatar

Agreed. Even self-reviewing a few days after I wrote the code helps me see mistakes.

firelizzard, (edited )
@firelizzard@programming.dev avatar

I used this tutorial for shaders: learnopengl.com/Lighting/Colors

This one also has useful stuff about how lighting works: opengl-tutorial.org/…/tutorial-8-basic-shading/

These are both about OpenGL, but the theory is the same regardless of the environment.

firelizzard,
@firelizzard@programming.dev avatar

“Flagged as spam”, “Publication Not Available”. I can’t see the article.

firelizzard,
@firelizzard@programming.dev avatar

After programming in Go for nearly a decade, the idea of going back to needing semicolons brings me pain. Rust seems cool, but semicolons 🤢

firelizzard,
@firelizzard@programming.dev avatar

The presence of semicolons is not a language killer.

I’m not saying it is. But every time I have to work in a language that requires semicolons I’m constantly forgetting them and constantly reminded of how nice it is to not have to care in Go.

firelizzard,
@firelizzard@programming.dev avatar

To me this is an argument for why Go should not add type inference to function/method declarations. Go is like Rust (I guess, I haven’t used Rust) - type inference works for declaring a variable (or const) and generic type parameters but not for type declarations, methods, functions, etc. I was in the “more inference is always better” camp but now I’m thinking Go has the perfect level of inference. Except for function literals/lambdas. I really want go to infer the argument and return types when I’m passing a function literal/lambda to a function.

firelizzard,
@firelizzard@programming.dev avatar
  • Scenario: I’m in the middle of writing a new feature.
  • Boss, to me: "Shit broke. Go figure it out."
  • Me, thinking: I’m in the middle of doing some complex work. If I commit/stash and close the open files, it will take a day for me to remember WTF I was doing.
  • Me: “Oh look, worktrees! I can leave my workspace intact with all the files open, pending changes, test results, terminal output, everything! And just create a new worktree to checkout the production version and debug! I’m saved!”

Also setting up a worktree is really easy. git worktree add …/hotfix prod-branch && cd …/hotfix and get working. Though in reality it’s cd …/hotfix && git checkout prod-branch because I’ve never needed more than one secondary worktree.

firelizzard,
@firelizzard@programming.dev avatar

Additionally, switch performs extra sanity checks that checkout doesn’t, for example switch would abort operation if it would lead to loss of local changes.

What checks? Under what situation does checkout lead to loss of changes? If I make changes and attempt to checkout a ref that would overwrite them, I get the following error:


<span style="color:#323232;">error: Your local changes to the following files would be overwritten by checkout:
</span><span style="color:#323232;">        some/file
</span><span style="color:#323232;">Please commit your changes or stash them before you switch branches.
</span><span style="color:#323232;">Aborting
</span>

To my knowledge it’s not possible to overwrite changes when switching branches/refs (git checkout <ref> without any other arguments or flags) so I guess what the author really means is, “If you use checkout incorrectly you can overwrite local changes.” As far as I can recall I’ve never accidentally git checkout <ref> <some/file> so I don’t see a reason to retrain my muscle memory. I do use git restore since it’s behavior is a lot more obvious than checkout/reset though sometimes I still use git checkout <ref> – <some/file> because muscle memory.

firelizzard,
@firelizzard@programming.dev avatar

I’ve written programs in C. I’ve written programs in assembly, for x86 and for microcontrollers. I’ve designed digital logic and programmed it into an FPGA. I’ve built digital logic circuits with transistors.

I’ll still take Go over C any day of the week. If I’m doing embedded, I’ll use TinyGo.

firelizzard,
@firelizzard@programming.dev avatar

Why? I see no reason to go through the hassle of learning yet another language when Go serves my purposes perfectly and I’m happy with it.

firelizzard,
@firelizzard@programming.dev avatar

I’d rather spend my free time doing something I enjoy

firefly, (edited ) to programmerhumor
@firefly@neon.nightbulb.net avatar

Difference Between Nerd and Geek

Has anyone written a scientific treatise on the differences between nerd and geek?

On the one hand, I could instigate endless debate about the finer points of nerds.

On the other hand I could construct nerds with a 3-D meat printer.

@programmerhumor

firelizzard,
@firelizzard@programming.dev avatar

I think the word you want is minutiae?

firelizzard,
@firelizzard@programming.dev avatar

I’d stop being awkward if I could but I wouldn’t give up my intense interests. You?

firelizzard,
@firelizzard@programming.dev avatar

If my IQ was higher than my body weight I’d be the smartest person on the planet…

Edit: I was thinking lbs, that makes a lot more sense in kg.

firelizzard,
@firelizzard@programming.dev avatar

I’m a cishet white dude so I experience effectively zero discrimination directed at me, but I am on the spectrum.

I guess basically everyone I regularly interact with either is also on the spectrum or has intense interests regardless, or is used to people like that. Though TBF I have learned to not get intense if I’m in public talking to random strangers. But if someone asks me a question like, “how do computers work”, I will answer at great length.

  • All
  • Subscribed
  • Moderated
  • Favorites
  • megavids
  • tacticalgear
  • magazineikmin
  • thenastyranch
  • Youngstown
  • mdbf
  • rosin
  • slotface
  • InstantRegret
  • khanakhh
  • Durango
  • kavyap
  • osvaldo12
  • DreamBathrooms
  • JUstTest
  • GTA5RPClips
  • ngwrru68w68
  • everett
  • tester
  • ethstaker
  • cisconetworking
  • cubers
  • modclub
  • provamag3
  • anitta
  • normalnudes
  • Leos
  • lostlight
  • All magazines