标签: c++ typecasting-operator
在2以下的类型转换中哪一个更适合/更好地在C ++代码中使用?为什么?
unsigned char var = 10; unsigned int value; value = static_cast<unsigned int>(var); //typecasting 1 value = (unsigned int)var; //typecasting 2