314
True crime (europe.pub)
you are viewing a single comment's thread
view the rest of the comments
[-] orgrinrt@lemmy.world 1 points 1 day ago* (last edited 13 hours ago)

Yeah obviously with constants for the set roles per value. Some languages call them enums, but the point is that what we pass and use is always still the smallest integer type possible. With the extra bonus that if the roles ever become composable, the same value type would likely suffice for a bitflag and only thing needing refactoring would be bitshifting the constants.

But anyway, this turns out to be the weirdest hill I find myself willing to die on.

this post was submitted on 14 Aug 2025
314 points (96.4% liked)

Programmer Humor

25750 readers
1497 users here now

Welcome to Programmer Humor!

This is a place where you can post jokes, memes, humor, etc. related to programming!

For sharing awful code theres also Programming Horror.

Rules

founded 2 years ago
MODERATORS