Date : Tue, 24 Nov 2009 16:41:15 +0000
From : rs423@... (Mick Champion)
Subject: Quine
David Harper wrote:
> Ian Stocks wrote:
>
>
>
>> Nope, think of a stack of plates, the last one you pushed onto the pile
>> will be the first one you pop off the pile. So the push and pop need to
>> be nested.
>>
>> PHA
>> PHP
>> //do other code
>> PLP
>> PLA
>>
>
> It is perhaps worth noting that if you really want to preserve both P and A
> it is better to do the push and pop (or pull) the other way round, ie:
>
> PHP
> PHA
> //do other code
> PLA
> PLP
>
> Otherwise the final PLA could affect the P register (in particular the N and
> Z flags, though it will not make any difference to C).
>
I think that's more than important enough to know. Thank you.
All this will have to wait for 9 days now though unless I do a Rick and
actually have some energy and brain activity before then. Must move all
these tips and hints to a separate folder while I remember, or else I'll
have a job to find them again.
Mick