- 论坛徽章:
- 0
|
In the C programming language, explicit type conversion (cast) can be thought of as a special reinterpretation of the raw data, which is usually unchanged throughout the step. It is changed, however, when the new type cannot hold as much data as the original one, for example, when a long int is converted into a short int.
在 C 程序设计语言中,强制类型转换可以认为是对原始数据的一种特殊的重新解释,这里的数据在转换的整个过程中一般是不做任何改动的,除非新类型能容纳的信息量比原类型更少,比如从长整型 long int 转换到短整型 short int 的时候。
Further reading: http://en.wikipedia.org/wiki/Type_conversion |
|