Filters can be convenient when you are placing a data change breakpoint on a local variable. In the following example, the current scope is in function foo()(), while index, the variable of interest, is in function bar()().
(dbx) stop access w &bar`index -in bar |
bar`index ensures that the index variable in function bar()() is picked up, instead of the index variable in function foo() or a global variable named index.
-in bar implies the following:
The breakpoint is automatically enables when function bar() is entered.
The breakpoint remains enabled for the duration of bar()() including any functions it calls.
The breakpoint is automatically disabled upon return from bar()().
The stack location corresponding to index might be reused by some other local variable of some other function. -in ensures that the breakpoint is triggered only when bar`index is accessed.