Re: [cc65] 65816 and ca65 : help needed

From: Greg King <gngking1erols.com>
Date: 2005-12-21 08:32:14
From: Ullrich von Bassewitz; on December 12, 2005; at 12:39 AM -0500
>
> On Mon, Dec 12, 2005 at 05:29:31PM +0100, chris wrote:
>
> > 2) add #-local produce an error ( Error: `:' expected
> > main.ca65(13): Error: Unexpected trailing garbage
> > characters
> > )
>
> The argument is treated as unsigned, so -something gives a large number.
> You have to use the '<' operator to get only the low byte:
>
>  lda #<-(arg)

Actually, the assembler did not get that far.

I see those error messages, alot.  They are accurate, but they don't help
us to understand what we did wrong (I would like to see a different
message).  The bug usually is one of these:

1) a typo or misspelling,
2) an undefined macro.

When ca65 can't recognize the first word on a line, it thinks that we
wanted to write a label (which needs a colon).  That "add" macro must be
defined by adding this line next to the ".P816" line:

    .macpack    generic
----------------------------------------------------------------------
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 30 04:16:34 2005

This archive was generated by hypermail 2.1.8 : 2005-12-30 04:16:39 CET