[Coco] [Color Computer] Re: MAS/EDT

Roger Taylor webmaster at coco3.com
Sun Jul 9 01:18:09 EDT 2006


At 11:49 PM 7/8/2006, you wrote:

> > For example, MAS allowed for
> > local labels. If a block of code is separated by blank lines from the
> > rest of the code, you could place a local label there (essentially a
> > lowercase letter a-z) and any branch to it would be recognized, even
> > if the same label exists outside of that code "island."
>
> > EDT allowed
> > for easy generation of the next local label which has not been used
> > yet in the current code island. Also, EDT would keep the line you are
> > typing in the middle of the screen, which is easier to look at than
> > the bottom. It had all sorts of cool stuff like this.
>


My CCASM 6809/6309 cross assembler for Windows support local labels.  A 
local label is defined as any label containing a '@' character, anywhere in 
the name (start, middle, end, etc.).  See the CCASM manual to see if any 
other special characters are allowed to define a local label.

CCASM goes futher by introducing what I call Branch Point local 
labels.  Using the '!' character for a local label, you can issue BRA 
<  and BRA >  instructions to branch backwards or forwards in your code to 
the nearest branch point local label.  This system is for quick coders but 
has its ups and downs.  For instance, you can get into trouble if you move 
segments of your code around often.  Branching to the reusable '!' label 
doesn't complain as long as it finds a legally-nearby label it can branch 
to.  This is not the desired behavior but it's legal, so be careful.

         LDB     #90
!       DECB
         BNE     <       loop
         BRA     >       exit
         NOP
         NOP
!       RTS



-- 
Roger Taylor




More information about the Coco mailing list