Last weekend I started the fasmg Z80 coding as I was saying some time ago.
I thought about it and my approach for simplicity and effectiveness would be to encode each different instruction in a different macro, and if it is not possible (as I assume) in a different "match" instruction (as below)...
Following a "not working" example of 4 instructions: I tried to read documentation but no success. Posting here with hope that is possible to easily correct and so I might understand it better and continue to implement the full instruction set.
Joined: 16 Jun 2003
Location: Kraków, Poland
The main problem is that you got the order of arguments to MATCH wrong: it should be the matched pattern first, and then the text to match. Also you need to precede "HL" token with "=", otherwise it is treated as parameter name (at the same time you do not need to put "=" before the parentheses, though it does not hurt there):
Also note that this macro silently ignores any unrecognized syntax, you'd need to add the "else" clauses with some error signaling to make sure that it does not allow any syntax errors to pass undetected.
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum You cannot attach files in this forum You can download files in this forum