#include
using namespace std;
class Point
{int x,y;
char *name;
public:
Point(char *str,int x1,int y1):x(x1),y(y1),name(str)
{cout<<name<<"点构造"<<endl;}
~Point(){cout<<name<<"点析构"<<endl;}
};
class Line
{Point p1,p2;
public:
Line(Point &a,Point &b):p1(a),p2(b)
{cout<<"Line点构造"<<endl;}
~Line(){cout<<"Line点析构"<<endl;}
};
class Line_1:public Line
{
int LineColor;
public:
Line_1(Point &a,Point &b,int color=0)
:Line(a,b),LineColor(color)
{cout<<"Line_1线构造"<<endl;}
~Line_1(){cout<<"Line_1线析构"<<endl;}
};
int main()
{
Point A("A",1,1);
Point B("B",2,2);
Line_1 line(A,B,255);
cout<<"===============\n";
system("pause");
return 0;
}
我在return处设置断点,想在输出框中查看 "Line_1线析构" 等的输出,但是只能显示到"===============”,用的是2012版的,求细致操作。
【c++】 断点调试怎么做?
- 写回答
- 好问题 0 提建议
- 追加酬金
- 关注问题
- 邀请回答
-