From 2c1bfa4da2ae809b6580ed1d6cd420cdba2806d0 Mon Sep 17 00:00:00 2001 From: Mike Buland Date: Wed, 9 Sep 2009 23:30:44 +0000 Subject: Fixed a unit test, and added some fixes and new queue functions to list, fuck it it's easier when they're in list. --- src/list.h | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) (limited to 'src/list.h') diff --git a/src/list.h b/src/list.h index 12b50e5..cce29fe 100644 --- a/src/list.h +++ b/src/list.h @@ -263,6 +263,27 @@ namespace Bu return v; } + MyType &push( const value &v ) + { + _hardCopy(); + prepend( v ); + + return *this; + } + + MyType &pop() + { + _hardCopy(); + erase( begin() ); + + return *this; + } + + value &peek() + { + return first(); + } + /** * Append a value to the list. *@param v (const value_type &) The value to append. -- cgit v1.2.3