<< Previous Message Main Index Next Message >>
<< Previous Message in Thread This Month Next Message in Thread >>
Date   : Wed, 17 Nov 2010 08:53:38 +0000
From   : jgh@... (J.G.Harston)
Subject: Hints'n'Tips: Assembling non-ARM code on ARM BASIC

Sprow wrote:
>    J.G.Harston <jgh@...> wrote:
>> Yes, the IF PAGE>&8000 is a quick'n'dirty way of deciding that you're
>> running on ARM BASIC, but I haven't been able to work out a succinct
>> better way of testing it.
>
>  DEFFNdetectBASIC5
>  LOCAL temp
>  ON ERROR =FALSE
>  temp=BEAT
>  =TRUE

Which isn't a single line. My usual code is:

   IF FALSE THEN
     REM Running on pre-BASIC V
   ELSE
     REM Runnning on BASIC V
   ENDIF

but, again, is not a single line.

> or look at REPORT$ on startup,

which will give an error on pre-BASIC V. And, if it doesn't you can't
guarrantee that you're running immediately after startup.

> or try $&70="Hello" which gives a 'too low' error.

Which generates an error, and so consequently isn't a single line.

-- 
J.G.Harston - jgh@...     
<< Previous Message Main Index Next Message >>
<< Previous Message in Thread This Month Next Message in Thread >>