Question

I know that most of you might have noticed now. When you try to evaluate an expression using watch on RAD Studio 2007, it does not evaluate.

For example, if I had a vector, I could not do "vecData.size()", if I do "vecData.size", it just gives an address.

Is there any other way to watch the size and view each element of the vector in RAD Studio while debugging?

Was it helpful?

Solution

If you disable the compiler optimisations in the project options, the debugger will then be able to evaluate vecData.size().

"Project Options->C++ Compiler->Optimizations->Disable all optimizations" set this option to "True".

This works for 2009, I believe it is the same for 2007.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top