Conversation
Notices
-
Embed this notice
CrunkLord420 (crunklord420@clubcyberia.co)'s status on Monday, 05-May-2025 03:20:32 JST CrunkLord420
Can you gay nulang do this?
The way you'd do this before was to "compile" your binary into an object file and then link it. It was weird and ugly.-
Embed this notice
silverpill (silverpill@mitra.social)'s status on Monday, 05-May-2025 06:00:08 JST silverpill
@crunklord420 Yes, in rust you can
let image_data = include_bytes!("image.png"); -
Embed this notice
opal (wowaname@freesoftwareextremist.com)'s status on Monday, 05-May-2025 11:05:17 JST opal
@RustyCrab @FailurePersonified @crunklord420 we get it, you think #embed is the next goto CrunkLord420 likes this. -
Embed this notice
Rusty Crab (rustycrab@clubcyberia.co)'s status on Monday, 05-May-2025 11:05:18 JST Rusty Crab
@wowaname @FailurePersonified @crunklord420 I had a project manager that was obsessed with having no files shipped with the binary and as a result every time you made a tiny change to any asset or dependency it would trigger a gigantic recompile and testing changes while the program was running was impossible.
I have PTSD now (Past Trauma from Stupid Developer) -
Embed this notice
opal (wowaname@freesoftwareextremist.com)'s status on Monday, 05-May-2025 11:05:19 JST opal
@FailurePersonified @RustyCrab @crunklord420 i should say underinformed rather than misguided. for desktop applications it definitely makes way more sense to refer to (replacable) locations for assets -
Embed this notice
Failure_Personified (failurepersonified@clubcyberia.co)'s status on Monday, 05-May-2025 11:05:20 JST Failure_Personified
@RustyCrab @wowaname @crunklord420
Rough take -
Embed this notice
opal (wowaname@freesoftwareextremist.com)'s status on Monday, 05-May-2025 11:05:20 JST opal
@FailurePersonified @RustyCrab @crunklord420 it's more a well-meaninged but misguided opinion, than it is any sort of bad take -
Embed this notice
Rusty Crab (rustycrab@clubcyberia.co)'s status on Monday, 05-May-2025 11:05:21 JST Rusty Crab
@wowaname @crunklord420 regardless I do not think I would want to introduce giant binary blobs into my c files -
Embed this notice
opal (wowaname@freesoftwareextremist.com)'s status on Monday, 05-May-2025 11:05:22 JST opal
@RustyCrab @crunklord420 you'd typically use xxd(1) before #embed got introduced into the preprocessor. and this is important to note: this is a preprocessor directive, not something in the C language itself. that means it's still kinda fuckin gay, especially considering how long it took for someone to *finally* hack this in -
Embed this notice
Rusty Crab (rustycrab@clubcyberia.co)'s status on Monday, 05-May-2025 11:05:23 JST Rusty Crab
@crunklord420 isn't there a standard utility that turns any binary file into a C byte array? -
Embed this notice
Rusty Crab (rustycrab@clubcyberia.co)'s status on Monday, 05-May-2025 11:05:23 JST Rusty Crab
@crunklord420 I misread #embed as #include wtf when did that get in the language -
Embed this notice
CrunkLord420 (crunklord420@clubcyberia.co)'s status on Monday, 05-May-2025 14:10:20 JST CrunkLord420
@wowaname @FailurePersonified @RustyCrab
>#embed is the next goto
so based? -
Embed this notice
CrunkLord420 (crunklord420@clubcyberia.co)'s status on Tuesday, 06-May-2025 04:01:29 JST CrunkLord420
@wowaname @FailurePersonified @RustyCrab goto is still regularly used in C to break out of nested loops and certain types of error checking. It's really not a big deal. Sometimes it just makes sense to use a goto. -
Embed this notice
opal (wowaname@freesoftwareextremist.com)'s status on Tuesday, 06-May-2025 04:01:30 JST opal
@FailurePersonified @RustyCrab @crunklord420 goto really is a mark of shitty control flow though. it's completely unnecessary in FP and declarative languages, and furthermore it doesn't even make sense from an implementation standpoint in those. even in assembler languages you have jumps, conditional jumps, and longjumps -
Embed this notice
Failure_Personified (failurepersonified@clubcyberia.co)'s status on Tuesday, 06-May-2025 04:01:31 JST Failure_Personified
@crunklord420 @wowaname @RustyCrab that's what I'm thinking.
If you don't have a goto, you aren't a real language.
-
Embed this notice