<分区>
Possible Duplicate:
Undefined, unspecified and implementation-defined behavior
我正在努力加深对 C++ 中未定义行为的理解。假设 C++ 编译器将有意检测某些未定义行为的情况 - 例如,modifying the variable twice between two sequence points :
x++ = 2;
一旦想象中的编译器可靠地检测到这种情况,它就会说将十个完全随机的机器指令发送到生成的机器代码中。
根据 C++ 标准,wherever something is classified as UB there're no requirements on what happens .所描述的假想编译器是否符合C++标准?