摘要: include try{}cache(exception &e){ cout代码生成-->启用C++错误,改成 /eha才行而且据说,也不是任意错误都能处理的,我就比较崩溃了;nclude#includeusingnamespacestd;//可以自己定义Exceptionclassmyexception:publicexception{virtualconstchar*what()constthrow(){return"Myexceptionhappened";}}myex;intmain(){try{if(true)//如果,则抛出异常;throwmyex 阅读全文
posted @ 2013-08-19 16:28 姜大伟 阅读(412) 评论(0) 推荐(0) 编辑