Microsoft KB Archive/26972

= Change of Radix Does Not Change Array Index =

Article ID: 26972

Article Last Modified on 12/1/2003

-

APPLIES TO


 * Microsoft CodeView 4.1
 * Microsoft CodeView 3.0
 * Microsoft CodeView 3.0
 * Microsoft CodeView 3.0
 * Microsoft CodeView 4.0
 * Microsoft CodeView 4.01
 * Microsoft CodeView 4.01
 * Microsoft CodeView 3.0
 * Microsoft CodeView 3.0
 * Microsoft CodeView 4.1
 * Microsoft CodeView 4.1
 * Microsoft CodeView 4.1
 * Microsoft CodeView 3.0
 * Microsoft CodeView 3.05
 * Microsoft CodeView 3.06
 * Microsoft CodeView 3.07
 * Microsoft CodeView 4.0
 * Microsoft CodeView 4.01
 * Microsoft CodeView 4.1

-



This article was previously published under Q26972



The Microsoft CodeView debugger assumes all array indexes are in the current radix. Therefore, if a watch is placed on a particular array element and the radix is then changed, the value displayed in the Watch window may change.

To illustrate, assume the current radix is 10 and the program being debugged contains an array called buffer. If a watch has been placed on buffer[10] and the radix is then changed to base 16, the Watch window will still show buffer[10], but the 10 now refers to 0x10 or decimal 16. Thus, the value displayed is buffer[16].

This behavior occurs because CodeView reinterprets the items in the Watch window each time; when you set a watch on a variable, CodeView does not &quot;compile&quot; that address into some internal memory location. Instead, it recalculates the watch statement each time.

This behavior was changed in CodeView version 4.1.

Additional query words: kbinf 2.20 3.00 3.50 4.00

Keywords: kb16bitonly KB26972

-

[mailto:TECHNET@MICROSOFT.COM Send feedback to Microsoft]

© Microsoft Corporation. All rights reserved.