Forums
New posts
Search forums
Members
Current visitors
Log in
Register
What's new
Search
Search
Search titles only
By:
New posts
Search forums
Menu
Log in
Register
Install the app
Install
Forums
Archive
Archive
C Programming
undefined behavior or not undefined behavior? That is the question
JavaScript is disabled. For a better experience, please enable JavaScript in your browser before proceeding.
Reply to thread
Message
[QUOTE="Papadopoulos Giannis, post: 1701408"] Well, except D-float -- but this is not an integral type and it has "bit" as well as "byte" order issues, when one takes it apart (because the bit-fields do not fall on "natural" byte boundaries). I am willing to bet that at least one CPU architecture will resurrect mixed-endian integers in its 32-to-64-bit transition. (I suspect it will be an existing little-endian architecture that is heavily stack-oriented, too.)[/QUOTE] Have in mind though, that mixed-mode architectures make things more difficult than it should be... -- #include <stdio.h> #define p(s) printf(#s" endian") int main(void){int v=1;*(char*)&v?p(Little):p(Big);return 0;} Giannis Papadopoulos [URL]http://dop.users.uth.gr/[/URL] University of Thessaly Computer & Communications Engineering dept. [/QUOTE]
Verification
Post reply
Forums
Archive
Archive
C Programming
undefined behavior or not undefined behavior? That is the question
Top