Keil™, An ARM® Company

Technical Support

A166: COMMENTS IN MACROS

QUESTION

I need to comment out some definitions in my A166 Macros. However, the semicolon (;) does not seem to do that. For example, the following code...

%DEFINE (ADDRESS2) (040000H)
;;;;;;;; %DEFINE (ADDRESS2) (001000H)

defines ADDRESS2 to be 001000h instead of 040000h. What am I doing wrong?

ANSWER

You cannot comment out Macros with a simple semicolon (;). You must use the Macro Comment Function (%'):

%DEFINE (ADDRESS2) (040000H)
%' %DEFINE (ADDRESS2) (001000H)

MORE INFORMATION

Last Reviewed: Friday, July 15, 2005


Did this article provide the answer you needed?
 
Yes
No
Not Sure