endlos99/xdt99

LI R1,R2 - no errors

petersobolev opened this issue · 1 comments

There are no syntax errors for notation like:

li r1,r2

but I think it should, because r2 is not a number and there wasn't label called "r2"

That's a peculiarity of all TI assemblers. R0 through R15 are pre-defined symbols for 0, ..., 15 that get added automatically if you add the "R" assembler option (for xas99, that would be -R).

So LI R1,R2 means LI 1,2 means load value to 2 into register 1 -- unexpected when you see it the first time, but the way assembly on the TI 99 has always been. And I wouldn't want to mess with that heritage. 😄