6502.org Forum  Projects  Code  Documents  Tools  Forum
It is currently Sat Nov 23, 2024 3:05 am

All times are UTC




Post new topic Reply to topic  [ 16 posts ]  Go to page Previous  1, 2
Author Message
 Post subject: Re: WDC Tools - bugs!
PostPosted: Fri Sep 16, 2022 10:56 am 
Offline
User avatar

Joined: Fri Aug 03, 2018 8:52 am
Posts: 746
Location: Germany
BillG wrote:
floobydust wrote:
BillG wrote:
Then again if you try:
Code:
 LDA #256

you get code of A9 00 (LDA #0). So it wraps around.

An argument can be made that should be flagged as an error.


ca65 for example does throw an "out of range" error when the operand size is too large for the selected instruction. (same with branch instructions that try to reach too far)
of course it also takes in account the size of the registers when assembling for the 65816. so with the Accumulator in 8-bit mode, doing LDA #256 will throw an error, with A in 16-bit mode, it will assemble fine.

overall i'm kinda getting tempted again to try and port DOS/65 to use ca65 instead of WDC's Assembler. mostly just because ca65 is fully open source and any kind of quirky behavior like that would quickly be found by some user and then posted on the cc65 github.
but i think that kind of project is above my skill level as it's not just an easy 1:1 convertion of assembler directives...
so maybe someday in the future i'll attempt it, or maybe someone else will have done it by then


Top
 Profile  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 16 posts ]  Go to page Previous  1, 2

All times are UTC


Who is online

Users browsing this forum: No registered users and 26 guests


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 post attachments in this forum

Search for:
Jump to:  
cron