ChaiScript/unittests/retroretro.chai
Jonathan Turner c73f16fdfe Fixing 4.x grammar to be backward compatible.
Added 3.x unit tests back to show this.
2012-05-17 10:14:50 -07:00

8 lines
148 B
ChaiScript

auto x = [1, 2, 3, 4]
auto r = retro(range(x))
r.pop_back()
auto r2 = retro(r)
r2.pop_front()
assert_equal(2, r.back())
assert_equal(3, r2.front())