Bug #18789 2012-11-13 08:15

krlez

Structure members listing issues in C

Example:

// GPIO_TypeDef is a structure defined using typedef

#define GPIOB_BASE_ ((((uint32_t)0x40000000) + 0x10000) + 0x0C00)

#define GPIOB_ ((GPIO_TypeDef *) GPIOB_BASE_) // ST Micro and NXP defines peripheral registers this way

GPIO_TypeDef *pStr = (GPIO_TypeDef *) GPIOB_BASE_;

// access to pointers:

pStr-> // shows up members - ok

((GPIO_TypeDef *) GPIOB_BASE_)-> // shows up members - ok

((GPIO_TypeDef *) ((((uint32_t)0x40000000) + 0x10000) + 0x0C00))-> // only displays type ("GPIO_TypeDef" with "Typedef" symbol)

GPIOB_-> // no reaction. This is used very often in embeded development with ST and NXP ARM MCUs.

Category
Plugin::CodeCompletion
Group
 
Status
Open
Close date
 
Assigned to
 
krlez 2012-11-13 08:16

svn Build 8549, win7 x64