Conversation
Notices
-
Embed this notice
Anhedonia (anhedonia@fsebugoutzone.org)'s status on Friday, 18-Oct-2024 21:09:45 JST Anhedonia @SuperDicq you can clearly tell this is a satire (because of the pointer cast)
malloc.png-
Embed this notice
SuperDicq (superdicq@minidisc.tokyo)'s status on Friday, 18-Oct-2024 21:13:59 JST SuperDicq @anhedonia@fsebugoutzone.org Oh god I didn't even notice, that's hilarious.
-
Embed this notice
翠星石 (suiseiseki@freesoftwareextremist.com)'s status on Friday, 18-Oct-2024 21:16:47 JST 翠星石 @SuperDicq @anhedonia Casting the return value of malloc() makes it sepples-compatible, which appears to be the cursed intention. -
Embed this notice
SuperDicq (superdicq@minidisc.tokyo)'s status on Friday, 18-Oct-2024 21:19:01 JST SuperDicq @Suiseiseki@freesoftwareextremist.com @anhedonia@fsebugoutzone.org What the fuck is sepples?
-
Embed this notice
翠星石 (suiseiseki@freesoftwareextremist.com)'s status on Friday, 18-Oct-2024 21:19:37 JST 翠星石 @SuperDicq C++ -
Embed this notice
SuperDicq (superdicq@minidisc.tokyo)'s status on Friday, 18-Oct-2024 21:20:37 JST SuperDicq @Suiseiseki@freesoftwareextremist.com Oh I don't know anything about C++. What does C++ do differently that it doesn't understand malloc normally?
-
Embed this notice
翠星石 (suiseiseki@freesoftwareextremist.com)'s status on Friday, 18-Oct-2024 21:24:00 JST 翠星石 @SuperDicq main.cpp:5:26: error: invalid conversion from ‘void*’ to ‘int*’ [-fpermissive]
5 | int *yes = malloc(sizeof(int)*4);
| ~~~~~~^~~~~~~~~~~~~~~
| |
| void*
The C++ spec refuses to allow implicit casting even in well formed cases, so you have to either compile with -fpermissive or cast.Sick Sun likes this. -
Embed this notice
SuperDicq (superdicq@minidisc.tokyo)'s status on Friday, 18-Oct-2024 21:25:08 JST SuperDicq @Suiseiseki@freesoftwareextremist.com I keep learning more and more reasons for why nobody should ever use C++ every single day
-
Embed this notice
翠星石 (suiseiseki@freesoftwareextremist.com)'s status on Friday, 18-Oct-2024 21:25:37 JST 翠星石 @GNUxeava To dynamically allocate memory?
"new" and "delete" seems pretty cursed. -
Embed this notice
Emi Yusa (gnuxeava@fedi.absturztau.be)'s status on Friday, 18-Oct-2024 21:25:39 JST Emi Yusa @SuperDicq @Suiseiseki also, why would one use malloc in c++? -
Embed this notice
SuperDicq (superdicq@minidisc.tokyo)'s status on Friday, 18-Oct-2024 21:28:05 JST SuperDicq @Suiseiseki@freesoftwareextremist.com Like so void* has no real purpose in C++?
-
Embed this notice
SuperDicq (superdicq@minidisc.tokyo)'s status on Friday, 18-Oct-2024 21:31:22 JST SuperDicq @Suiseiseki@freesoftwareextremist.com inb4 the point of void* in C++ is being able to interact with C libraries
-
Embed this notice
翠星石 (suiseiseki@freesoftwareextremist.com)'s status on Friday, 18-Oct-2024 21:32:12 JST 翠星石 @SuperDicq I believe it still retains the purpose of casting between types that are compatible, but which the compiler doesn't believe so.
C++ doesn't even want you to use standard pointers, it wasn't you to use "checked pointers", or whatever it's called. -
Embed this notice
SuperDicq (superdicq@minidisc.tokyo)'s status on Friday, 18-Oct-2024 21:36:58 JST SuperDicq @GNUxeava@fedi.absturztau.be @Suiseiseki@freesoftwareextremist.com I think it's hilarious that nobody who uses C++ actually understands anything about C++. At least it feels like that to me.
-
Embed this notice
Emi Yusa (gnuxeava@fedi.absturztau.be)'s status on Friday, 18-Oct-2024 21:37:00 JST Emi Yusa @SuperDicq @Suiseiseki there are
but it is voodoo magic and i already forgot -
Embed this notice
SuperDicq (superdicq@minidisc.tokyo)'s status on Friday, 18-Oct-2024 21:46:28 JST SuperDicq @GNUxeava@fedi.absturztau.be @Suiseiseki@freesoftwareextremist.com Python is probably indeed the worst example of a language where everything is version dependent.
-
Embed this notice
Emi Yusa (gnuxeava@fedi.absturztau.be)'s status on Friday, 18-Oct-2024 21:46:29 JST Emi Yusa @SuperDicq @Suiseiseki it's true
it tries to be everything so a person only knows parts of c++ they've actually used
what i like about c++ is if you know how to do one thing and be good at it, it will work forever. I miss this soooo much with python because every package in existence complains about major.minor.revision.revision.revision.revision to be different and refuses to work -
Embed this notice
SuperDicq (superdicq@minidisc.tokyo)'s status on Friday, 18-Oct-2024 21:50:56 JST SuperDicq @GNUxeava@fedi.absturztau.be @Suiseiseki@freesoftwareextremist.com And yeah I agree a good part of C is that 40 year old C code very likely still compiles using the latest version of GCC (with maybe some minor changes).
-
Embed this notice