ID Number: Q34922
1.x 2.x 3.00 3.10 3.11 3.14 | 2.x 3.00 3.10 3.11 3.12 3.50
MS-DOS | OS/2
Summary:
The Microsoft CodeView debugger prior to version 3.0 cannot debug
source code in include files. CodeView versions 3.0, 3.1, 3.11, 3.12
3.14, and 3.50 allow code in include files to be debugged if you
observe certain restrictions.
More Information:
Attempting to debug a program with code in include files using
CodeView version 2.35 or earlier generally results in the include file
appearing on screen when you trace through the program, and the
current line indicator may be completely out of sync with the
displayed code. Attempts to view the top-level source code always
results in display of the include file.
The inability to debug source code in include files is a documented
limitation of CodeView versions prior to 3.0. Include files should
only contain non-executable statements such as prototypes,
declarations, #defines, and #includes. Although it is valid C code,
include files must not contain variable initializations, function
definitions, or other executable statements for these versions of
CodeView to be able to debug your program properly.
When using CodeView version 3.0, 3.1, 3.11, 3.12, 3.14, or 3.5, the
limitation on code in include files is removed subject to one major
restriction: you must arrange your source code so that the top-level
source file contains a code-generating statement before the files are
included. If you fail to meet this requirement, CodeView 3.x will not
be able to display the top-level source.
Additional reference words: 1.0 1.00 1.1 1.10 1.11 2.0 2.00 2.1 2.10
2.2 2.20 2.30 2.30 2.35 3.0 3.00 3.1 3.10 3.11 3.12 3.14 3.5 3.50