testdbg.cpp
来自「eC++编译器源码」· C++ 代码 · 共 32 行
CPP
32 行
#include <iostream.h>
#include <Help.h>
void pr(int a, double b)
{
char s[10]; boolean bo;
s = "abcdef"; bo = true;
cout<<"Typing a '!' will continue execution. Try it.\n";
Look();
cout<<"Good. Now type 'system.m' to list all the modules\n"
" that your program uses. Type '.system.c' to get a backtrace\n"
"of the program's execution. Then type '!' to continue.\n";
Look();
cout<<"Good. Now try typing the following:\n"
"\t.testdbg[8]\tto display line 8\n"
"\t.testdbg[8..11]\tto display lines 8 to 11\n"
"\t.testdbg.x\t.testdbg.pr.a\t.testdbg.pr.s\tto look at variables\n";
Look();
};
unsigned int x;
void main()
{
cout<<"This program illustrates some capabilities\n"
"of the Help interface to the debugger. The Look\n"
"method can be used to look at program text or variables\n"
"in any module. The Assert method calls Look only if\n"
"its argument is false\n";
x = 99;
pr(4, 5.6);
};
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?