... please wait while loading ...

To view the complete site without permanently having to scroll, your browser-window should be maximized to support your screen-resolution of .
supportforum
BGStats Consulting

facebook google

  17.377.098 Nedstat Basic - Kostenlose web site statistiken Persönliche Homepage webseite Zähler
Kostenlose Zähler
In memoriam C-BIT Information-Center Hannover (2.241/1075+2.241/1076 - no longer active)
Sicherheitshinweis: Wir weisen vorsorglich darauf hin, dass wir bei der Anmeldung saemtliche automatisch uebermittelten Parameter wie IP-Adresse und/oder Einwahlrufnummer speichern, um uns und unsere Kunden vor Missbrauch zu schuetzen. Selbstverstaendlich werden wir bei Bedarf umgehend strafrechtliche Massnahmen ergreifen, um einen vorliegenden Missbrauch zu ahnden.

PRB: Unable to Set CodeView Breakpoint on Desired Line

Article ID:60338
Last Review:October 23, 2003
Revision:2.0
This article was previously published under Q60338
On This Page

SYMPTOMS

In CodeView, an attempt to set a breakpoint on a specified line fails.

CAUSE

The compiler command line did not specify both the /Od and /Zi option switches. Some compiler optimizations concatenate code in the executable file unless the command line specifies /Od to disable all optimizations.

RESOLUTION

Recompile the code with the correct options specified.

MORE INFORMATION

The code example below demonstrates this problem. When the code is compiled with only the /Zi switch, you cannot set a breakpoint on the indicated line.

Sample Code

/*
 * Compile options needed: /Zi
 */ 

#include <stdio.h>

int func();

void main(void)
{
   int a, b, c;

   a = func();  // You cannot set a breakpoint on this line because
                // the default optimization concatenates it with the
                // following line to form the expression:
                //    b = (a = func()) + c
   b = a + c;
}

int func()
{
   return(10);
}
				

APPLIES TO
 Microsoft CodeView for MS-DOS
 Microsoft CodeView 4.1


This mirror is sponsored by:
Hansjoerg G. Henker
A-Z Consulting & Development
[453]

Information-Center [11.02.2012 22:53:20]