static_cast<type>(Expression)
dynamic_cast<type>(Expression)
const_cast<type>(Expression)
reinterpret_cast<type>(Expression)
static cast alternatives (not recommended):
(type) Expression
type(Expression)
Eg: static_cast<double>(3) || double(3) || (double) 3
No comments:
Post a Comment