Submitted for discussion... You will find this interesting. Take this program:
#include "stdio.h" int main() { int a = 2; int b = 3; b++; a = b++ * a++; int c = a % b; printf("a = %d b = %d c = %d",a,b,c); return 0; } and compile it. Depending on where you compile, you get different results:
gcc: a = 8 b = 5 c = 3
MS c++ Version 6, 7, and 8: a = 9 b = 5 c = 4
MS c#: a = 8 b = 5 c = 3 So, I think this says that Microsoft's c++ compiler has violated the iso language standard at least for the last three versions, and they are now fixing the bug in their c# compiler. Think of all that MS code out there that is broken! |
Printed at http://lxer.com/module/newswire/view/32353/index.html