[cc65] ca65 Feature request

From: Jeremy Turner <jeremiah.turner1gmail.com>
Date: 2012-12-21 20:53:38
Two things that would make things better for me:

I briefly contacted Uz about the 1st one:

1) A pseudo function to evaluate if an string (or token) is a valid macro
or instruction name. Right now I have code that needs to call other macros
using tokens and just does so, hoping that the token or string is a valid
macro (or instruction). It would be nice to be able to tell before and do
something about it (.error for example.)

2) Overloading of instructions. I see that there is a
.feature ubiquitous_idents, but this seems to turn off all instruction
matching. I would prefer a method where all instructions work normally
unless a macro was defined to overload them, in which case you could do
something and then call the original instruction.

For example I like and use this syntax where I have control over it:

lda foo[ 3 + x ]

Basically I can do:

.macro array_syntax I O
  ; process O
  ; ouput I O
.endmacro

array_syntax lda foo[ 3 + x ]

I process it with macro code and turn it into lda foo+3,x and output that
code from the macro. I don't think I can't do that if I have "lda foo[ 3 +
x ]" bare on a line unless I use ubiquitous_idents and process everything
down to .byte output. Would it be difficult to overload the instruction
only if it is defined and then call the original instruction somehow?

I suppose I could use something like lda_ or _lda but I would rather not.

Thanks
JT

----------------------------------------------------------------------
To unsubscribe from the list send mail to majordomo@musoftware.de with
the string "unsubscribe cc65" in the body(!) of the mail.
Received on Fri Dec 21 20:54:00 2012

This archive was generated by hypermail 2.1.8 : 2012-12-21 20:54:03 CET