Local variables disappear in CLion 2021.2

Viewed 499

I'm trying to debug a non-optimized build of a C++ test executable in a repository of mine, with CLion 2021.2. I start debugging, and at some point tell the CLion debugger to run up to some breakpoint - and when I reach it, the local variables are no longer listed. The variables/watches pane is empty, saying only:

"Variables are not available"

... and they are unavailable even if I walk up the stack to the calling function, where, when I broke earlier, did show the variables.

What are the possible reasons (I assume there aren't many) for this occurring? Can this be "legit" or is it an IDE bug?

Notes:

  • The breakpoint is in an innocent-looking C(ish) function, not in any templated code, lambda or anything like that.
  • If I manually add watches - they work, i.e. I see the appropriate values getting updated.
0 Answers
Related