Dereferencing a Pointer

Related Topics:

Example of Dereferencing a Pointer

You can move to the location of, or dereference, a pointer to access the data located at the address. When you dereference a pointer, you ask for the value stored in the object to which the pointer is a reference, not for the value of the pointer-variable.

To dereference a pointer:
   Click the pointer value link.

The selected expression is replaced with the dereferencing expression.

You can keep all windows for a pointer by choosing Undisplay on Reference from the pop-up menu in the Data Display window. You open the pop-up menu by placing the pointer anywhere within the window and pressing the right mouse button.

You can also set a global default using the Debugging Options Dialog Box. For more information, see Removing Pointer Items When Dereferenced.

Following Pointers

Suppose the expression in the Data Display list is:

p = 0x04fa72

The value 0x04fa72 is a link. When you click the link, the pop-up window for *p = {...} opens automatically. p automatically undisplays when *p appears.

The Data Display window shows:

---------------------------
*p = {...}
---------------------------

If you want to redisplay an intermediate value, retrieve it from the Redisplay submenu in the Data Display main window.