CodeWarrior 6.1 Go to macro declaration error

取消
显示结果 
显示  仅  | 搜索替代 
您的意思是: 

CodeWarrior 6.1 Go to macro declaration error

2,557 次查看
RodBristol
Contributor I
When a macro is conditionally compiled and the file holding the declaration is not open, the right-click-and-Go-to-macro-declaration feature works correctly. If the file holding the macro is already open, the IDE chooses the last declaration in the file instead of the correct one. This is with the "Generate Browser Data From Compiler" option selected.
 
In my project, the compile switches are defined in a file set on a path unique to each target.
 
Here's an example:
/* active high relay control on port E */
#if(LocalRelayDrive == 1)
#define SetLocalRelayOn         PTED |= 1
#define SetLocalRelayOff        PTED &= ~0X01
#define GetLocalRelayStatus     (PTED & 1)
/* active low relay control on port E */
#elif(LocalRelayDrive == 0)
#define SetLocalRelayOff        PTED |= 1
#define SetLocalRelayOn         PTED &= ~0X01
#define GetLocalRelayStatus     (!(PTED & 1))
/* multiple relay control  on port B */
#elif(LocalRelayDrive == 3)
#define ShutdownRelayOff        PTBD |= (1<<2) // brown, shutdown
#define ShutdownRelayOn         PTBD &= ~(1<<2)
#define SetLocalRelayOff        PTBD &= ~(1<<1) // gray, short = setback
#define SetLocalRelayOn         PTBD |= (1<<1) // open = occupied
#endif
 
 
Thanks.
Rod Bristol
 
标签 (1)
0 项奖励
回复
2 回复数

777 次查看
CrasyCat
Specialist III
Hello
 
I would recommend you to submit a service request for that.

Click here to submit a service request.

Make sure to attach a reproducible project and installed product information to the service request.
To generate the required information:
- Start CodeWarrior
- Open the project
- Select "Help" -> "Pack and Go" and follow instructions on the screen.

Attach the generated .zip file to the SR.
 
CrasyCat
0 项奖励
回复

777 次查看
RodBristol
Contributor I
Packed and sent. Thanks.
Rod Bristol
0 项奖励
回复