Hovering and Debugging
Join the DZone community and get the full member experience.Join For Free
eclipse provides in the editor view great tool tips (called ‘hovers’) which shows what is behind a macro: i can move my mouse over it, and it shows me the content behind it:
but if i’m debugging, i get “no value available” :
obviously, the debugger queries the value of that macro, and as there is no variable with that name, there is no value. makes sense. but: how can i see the macro value while debugging?
the solution is to configure different hover keys in the preferences (menu window > preferences > c/c++ > editor > hovers ):
the above dialog shows as well that there are different hovers available. by default, the ‘combined hover’ is used. and it is using the debugger hover, which cannot provide a value, thus the ‘no value available’ result. the hover preferences has as well the possibility to assign a modifier key: with this, a selected hover can be used.
and indeed: if i use the ‘shift’ key pressed while hovering in the debugger, i get what i want :
Published at DZone with permission of Erich Styger, DZone MVB. See the original article here.
Opinions expressed by DZone contributors are their own.