EUforum Messages
- Powered by Euphoria -
Post Reply Previous Next All Messages
Date: Thu May 8 21:36
From: Jeremy Cowgar <jeremy at cowg?r?com>
Subject: Re: Revision 417 -- tests are broke

CChris wrote:
> 
> 
> As I mentioned earlier, it depends on whether dup() is supposed to duplicate
> the last pushed value or the top(). I don't remember you replied to this.
> The second failure is caused by the same issue, since the stack is not in the
> expected shape.
> 
> CChris
> PS: Looks like a test for the tests is needed :-)

http://www.openeuphoria.org/EUforum/m20654.html

:-)

dup() should duplicate the top item. Whenever working with a stack, almost everything
happens to the top item. swap() for instance, swaps the top item with the one
below it. drop() (pop()) removes the top item, etc...

--
Jeremy Cowgar
http://jeremy.cowgar.com

 
Post Reply Previous Next All Messages