TIP: Click on subject to list as thread! ANSI
echo: cis.os9.68000.osk
to: Rick Caldwell 72067,2567 (X)
from: Jack Crenshaw 72325,1327
date: 1991-02-07 18:53:09
subject: #9399-Assembler

#: 9426 S12/OS9/68000 (OSK)
    07-Feb-91  18:53:09
Sb: #9399-Assembler
Fm: Jack Crenshaw 72325,1327
To: Rick Caldwell 72067,2567 (X)

My thoughts exactly re the strong typing, Rick.   The only problem is: How is
the assembler to decipher things like

       D0 += D1   ?

In the case of the registers, you have to somehow tell it what you mean. Until
recently, I've been thinking that I would require typing of the registers as
well.  It makes things more orthogonal, and would result in a language that
would even compile on a different machine (in other words, if D0 were treated
as a variable).  Since you sometimes want to treat the register as one type and
sometimes as another, you'd have to allow types to be changed, which gets kind 
of awkward.

More recently, I've been thinking about borrowing a page from Intel's book, and
declare the size as part of the register definition, i.e.,

       D0B = C
       D0L = X    etc.

There still remains to decide what to do when types don't match up.  For

       D0B = D1L, should we generate some kind of conversion (But what??),
generate an error message, or simply ignore the 'L'?  More importantly, what do
we do with

       D0B = X,  where X was declared long?  Do we fetch the high byte (i.e.,
the one at the address of X) or the low byte (i.e., treat it as a type
conversion from long to byte)?

Jack

SOURCE: compuserve via textfiles.com

Email questions or comments to sysop@ipingthereforeiam.com
All parts of this website painstakingly hand-crafted in the U.S.A.!
IPTIA BBS/MUD/Terminal/Game Server List, © 2025 IPTIA Consulting™.