Changing What the Variable Window Displays
When TotalView displays a Variable Window, the Expression field contains either a variable or an expression. Technically, a variable is also an expression. For example, my_var.an_element is actually an addressing expression. Similarly, my_var.an_element[10] and my_var[10].an_element are also expressions, since both TotalView and your program must figure out where the data associated with the element resides.
The expression in the Expression field is dynamic. That is, you can tell TotalView to evaluate what you enter before trying to obtain a memory address. For example, if you enter my_var.an_element[i], TotalView evaluates the value of i before it redisplays your information. A more complicated example is my_var.an_element[i+1]. In this example, TotalView must use its internal expression evaluation system to create a value before it retrieves data values.
You can replace the variable expression with something completely different, such as i+1, and TotalView simply displays the value produced by evaluating the expression.
Chapter 15, Evaluating Expressions has a discussion of the evaluation system and typing expressions in an eval point in the Tools > Evaluate Window. In contrast, the expressions you can type in the Expression List Window are restricted, with the principal restriction being that what you type cannot have side effects. For example, you cannot use an expression that contains a function call or an operator that changes memory, such as ++ or --.