On 3/10/07, Luc Le Blanc <[EMAIL PROTECTED]> wrote:
When the CW 9.3 compiler reports error "Warning : variable 'x' is not
initialized before being used", the IDE points to the declaration line, not
the line where the unitialized variable is first used. Can this be changed?

almost all compilers do this.

the point is to identify the variable that has not been initialized.
going to its declaration is the right thing.

Or is there a trick to find out where, other than just reading th whole code?

search?

you may also try to keep your functions smaller in size so that you dont
have so much code to read through as well in this case, but it is a matter
of style i guess. in some cases, it may be like this:

int x;

if (condition) x = 0;

...

y = x;

as you can see, x isn't known if the condition is false. how would it help
to know where x is first used in this case? one should always assume
variables have a default value of some form, and set it.

its a matter of programming style.

--
// Aaron Ardiri

--
For information on using the ACCESS Developer Forums, or to unsubscribe, please 
see http://www.access-company.com/developers/forums/

Reply via email to