C++???????????????
???????????? ???????[ 2014/1/9 13:45:55 ] ????????C++ ???? ??
???????????е??????
?????????????
???????????MyTest_Base????????
??????????????????????????????????C++????????漲???????????Щ???????г?????????????????????????????????????????????????ζ?????г?????????????????????????????в????????????????????????????е????仰???????????????????????????????????????????????????????????????з?????????????????C++????й漲????????з???????????????????????????????Щ????????????????????漲?????????????з???????????????????????в????????????????????
????2???????????????????????????????????????С?????^-^??????????????????????C++??????????????????C++?е?????????????????????????????C++????????漲???е????????????????????????????????е????????????????????CPU?????????????????????????е??????????????????????п???·····???????C++????????????????????????????????????????????£????£?
class MyTest_Base
{
public:
MyTest_Base (string name = “”) : m_name(name)
{
throw std::exception(“????????????????????????”);
cout << “???????MyTest_Base?????????????????”<<m_name << endl;
}
virtual ~ MyTest_Base ()
{
cout << “???????MyTest_Base?????????????????”<<m_name << endl;
}
void Func() throw()
{
throw std::exception(“???????????????????”);
}
void Other() {}
protected:
string m_name;
};
void main()
{
try
{
// ????????????????
MyTest_Base obj1(“obj1”);
obj1.Func();
obj1.Other();
}
catch(std::exception e)
{
cout << e.what() << endl;
}
catch(...)
{
cout << “unknow exception”<< endl;
}
}
????????????н???????????“??????????????????????????????????????”
??????
???·???
??????????????????
2023/3/23 14:23:39???д?ò??????????
2023/3/22 16:17:39????????????????????Щ??
2022/6/14 16:14:27??????????????????????????
2021/10/18 15:37:44???????????????
2021/9/17 15:19:29???·???????·
2021/9/14 15:42:25?????????????
2021/5/28 17:25:47??????APP??????????
2021/5/8 17:01:11