'Keil debugger ini file complains to user types as "undefined identifier"

I have a type which describes the data layout of the EEPROM and I'm trying to watch it in Keil debugger via a pointer to a fixed address using the following command:

WS 1, (EEPROM_Type*)0x1101F000

where EEPROM_Type is a packed structure type which is used in my code to access various values in EEPROM. The above debugger command works fine when I enter it manually in a debug session, but not in the debugger initialization file:

WS 1, (EEPROM_Type*)0x1101F000
_______^
*** error 34: undefined identifier

The expression (EEPROM_Type*)0x1101F000 can also be added directly to the watch window, but it is removed from the watch window whenever a debug session is restarted. I assume this is because the same error happens internally when the list of watch expressions is processed. I would like to have it in my watch list permanently without having to add it manually every time. Is there a way to do this?

Note: none of this happens with a native C type, e.g. (char*)0x1101F000. This expression is correctly saved it the watch window across debug sessions, and can used with a WS command in the debugger ini file.

Note 2: the same thing happens with types describing the MCU internal registers, e.g. CPU_Type.

I'm using Keil 5.26.2, which is the last version for which I have the license. However, I would be interested to know if this issue is solved in the latest versions, since that would be yet another argument I could bring to the table the next time we are discussing license upgrades.



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source