我被告知这样做,
int* i = new int();
我无法检查我的指针为0. new如果失败则发送异常.但是,如果我不想出于原因使用异常会怎样.有没有办法检查我的指针是否正确分配?
new
c++
c++ ×1