<< Previous Message Main Index Next Message >>
<< Previous Message in Thread This Month Next Message in Thread >>
Date   : Sun, 28 Dec 2008 17:08:50 +0100
From   : kortink@... (John Kortink)
Subject: Using stack page for temp vars

On Sun, 28 Dec 2008 14:12:21 -0000, "Michael Firth"
<mfirth@...> wrote:

>----- Original Message ----- 
>From: "Rob" <robert@...>
>To: "BBC micro mailing list" <bbc-micro@...>
>Sent: Sunday, December 28, 2008 12:29 PM
>Subject: Re: [BBC-Micro] Using stack page for temp vars
>
>
>> 2008/12/28 Alex Taylor <zeem.uk@...>:
>>> 2008/12/28 Jonathan Graham Harston <jgh@...>:
>>>
>>>> I am **FED** **UP** with calling *commands from View, Diagram, 
>>>> ViewSheet,
>>>> Exmon, Art, any non-BASIC language, and things being corrupted because 
>>>> it's
>>>> trampled over space that BASIC doesn't use, thinking that nothing uses 
>>>> it.
>>>
>>> This is really interesting, because I think I may have been guilty of
>>> this (even though I was in my teens at the time). I'm not sure if this
>>> counts though, it was a tiny piece of machine code called from a BASIC
>>> program - is that the same, or does that not count because it's called
>>> from within BASIC?
>>
>> No, that doesn't count becuase that's what the reserved bytes were for
>> - for use by code exclusively used from within BASIC programs,  The
>> problem comes when people write more "generic" routines (things like
>> sideways ROM/RAM tools for instance) to use that workspace, because
>> they might be called from within other language ROMs, where that
>> workspace is not available, and so they disrupt the operation of the
>> language concerned.
>>
>Does that mean that I'm incorrect in my assumption that almost everyone 
>would do any SRAM handling from BASIC?

What kind of approach to programming is this anyway,
trying to make some assumption stick when you know
you don't have to make any if you put in a little
more effort ? Pretty much a waste of time, if you
ask me.

It's only an open issue when it comes to non-transient
data. Even then you should ask yourself if you really
need it.


John Kortink


-- 

Email    : kortink@...         
Homepage : http://www.inter.nl.net/users/J.Kortink

GoMMC, the ultimate BBC B/Master/Electron storage system :
http://web.inter.nl.net/users/J.Kortink/home/hardware/gommc




<< Previous Message Main Index Next Message >>
<< Previous Message in Thread This Month Next Message in Thread >>