开发者

What does the compiler do to perform a cast operation in C++? [duplicate]

This questio开发者_开发问答n already has answers here: Closed 12 years ago.

Possible Duplicate:

How do C/C++ compilers handle type casting between types with different value ranges?

What does the compiler do to perform a cast operation in C++?

Explain with some sample C++ code.


Standard sections

5.2.7, 5.2.8, 5.2.9, 5.2.10 and 5.2.11

give a good idea on how these casts work (which is what compiler and/or runtime implement).

reinterpret_cast is the only one whose behavior is kind of implementation defined.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜