Commit 1cbf940e authored by Davis King's avatar Davis King

Fixed a bug I introduced a minute ago.

parent f1896128
...@@ -490,7 +490,7 @@ namespace dlib ...@@ -490,7 +490,7 @@ namespace dlib
sstack pop(size_t num=1) sstack pop(size_t num=1)
{ {
DLIB_CASSERT(num < size(), "You can't pop more things from the stack than it has in it."); DLIB_CASSERT(num <= size(), "You can't pop more things from the stack than it has in it.");
return sstack(data+num, mysize-num); return sstack(data+num, mysize-num);
} }
......
...@@ -178,7 +178,7 @@ namespace dlib ...@@ -178,7 +178,7 @@ namespace dlib
); );
/*! /*!
requires requires
- num < size() - num <= size()
ensures ensures
- returns a reference to the sub-stack S such that: - returns a reference to the sub-stack S such that:
- S.size() == size()-num. - S.size() == size()-num.
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment