The [2004] worm will also copy itself to various peer-to-peer shared folders as the following files: Doom 3 release 2.exe Gimp 1.8 Full with Key.exe Internet Explorer 9 setup.exe Smashing the stack full.rtf.exe Win Longhorn re.exe Windows 2000 Sourcecode.doc.exeLMAO. I didn't know those worms from 2004 were that hilarious. :blobcatlul:
@hyc@mastodon.social memcpy() is no longer a library function today, it also works like a special code annotation. I believe calling a dummy memcpy() is one legal way to do type punning. If you do it yourself by casting pointers, the result is undefined. If memcpy() does it, it's implementation-defined - which usually gets optimized into a noop by the compiler anyway, if direct access to the underlying memory is acceptable for a particular machine (not always, e.g. alignment-to-machine-word rules).
The root of the problem is that C cannot decide whether it's a high-level or low-level language and sits on the borderline between both. Historically, programmers did all kinds of hacks inside C, like arbitrarily casting memory from and to char * (K&R didn't even have void), or the famous "you're not expected to understand this", which relied on compiler-specific register allocation. But when it became a general-purpose language, for portability and optimizations, only a subset of all possible C code is allowed, which is the part that only operates on "entities" rather than bytes without making assumption about the underlying machine or data representation.
But of course machine-specific assumptions must be made somewhere down the chain. How should the intention of the programmers in these kinds of code be expressed or communicated to the compiler is never systematically considered when C was originally designed.
#TIL C++26 is planning to add the whole BLAS into the standard library, and will natively support std::mdspan (the official multi-dimensional array since C++23). C++ surely is a programming language that people just throw everything imaginable into it. #hpc
"There are no known reports of those [backdoored xz] versions being incorporated into any production releases for major Linux distributions"It's the one single big difference between npm and traditional distro packages - a bad upstream change doesn't instantaneously propagate to all end users within a picosecond.
Modern Python code uses explicit type annotation everywhere, meanwhile modern C++ code uses implicit type "auto" everywhere and relying on template type deduction to match it to a compatible function automatically. What a strange new world we find ourselves living in.
Previously: @niconiconi@cybre.space / Code monkey and sysadmin / No nations, no flags, no patriots. / Chaotic Neutral / Now Accelerationist / currently NEET + hikikomori / ? “Onii-chan is watching you!", use OpenPGP: FAD3EB05E88E8D6D / biologically male, self-identified as '; DROP TABLE genders;