_x is int. and return type is int too. You don't need static_cast