The ca65 documentation doesn't say much about the .Inn and .Ann (pseudo?) instructions, how do I use them?
https://cc65.github.io/doc/ca65.html#ss11.102
.Inn and .Ann in ca65 .SMART mode
Re: .Inn and .Ann in ca65 .SMART mode
These directives tell the assembler whether the registers are in 8-bit or 16-bit mode, nothing more. That will determine how the assembler interprets your code, generating 8-bit or 16-bit operands according to the last directive. Once changed, that directive is in effect further down in the source file until it is changed again.
When smart mode is active, the assembler will track SEP/REP instructions to try to determine the mode but this is problematic if your code doesn't have a top to bottom flow.
It's usually recommended to include these commands in macros. See this post by BDD for example.
When smart mode is active, the assembler will track SEP/REP instructions to try to determine the mode but this is problematic if your code doesn't have a top to bottom flow.
It's usually recommended to include these commands in macros. See this post by BDD for example.
-
jeffythedragonslayer
- Posts: 114
- Joined: 03 Oct 2021
Re: .Inn and .Ann in ca65 .SMART mode
Oh, 8 and 16 are supposed to be substituted in where the n's are. I see, thanks.