[cc65] .macro related error

From: <silverdr1wfmh.org.pl>
Date: 2013-03-17 19:04:40
The situation:

file: ui.i
-----------------
.import ui_system_status_code
.macro ui_status status_code, status_msg
	ldx # status_code
.ifnblank	status_msg
	lda #< status_msg
	ldy #> status_msg
.endif
	jsr ui_system_status_code
.endmacro


file: status.i
-------------------
.enum
	SCANNING_DEVICES
	LOADING_DRIVERS
.endenum


file: load_drivers.s
------------------------
.include "../ui.i"
.include "../status.i"
[...]
	ui_status (LOADING_DRIVERS, msg_status_loading_drivers)
[...]


Generates upon building:

ui.i(6): Note: Macro was defined here
load_drivers.s(25): Error: Unexpected trailing garbage characters
ui.i(8): Note: Macro was defined here
load_drivers.s(25): Note: Macro parameter came from here
load_drivers.s(25): Error: Unexpected trailing garbage characters
ui.i(9): Note: Macro was defined here
load_drivers.s(25): Note: Macro parameter came from here

But when I invoke the same macro without parentheses, it seem to compile fine. What is the problem with parentheses here? Or is it the combination with .enum? causing troubles?

----------------------------------------------------------------------
To unsubscribe from the list send mail to majordomo@musoftware.de with
the string "unsubscribe cc65" in the body(!) of the mail.
Received on Sun Mar 17 19:04:53 2013

This archive was generated by hypermail 2.1.8 : 2013-03-17 19:04:56 CET