典型问题分析一

 在main.cpp中:

#include <iostream>
#include "Exception.h"
using namespace std; using namespace DTLib; int main() { try { NullPointerException npe; cout << "throw" << endl; throw npe; } catch(const Exception& e) { cout << "catch" << endl; } return 0; }

测试结果表明在这个示例下没有问题。

猜你喜欢

转载自www.cnblogs.com/-glb/p/12313882.html