ChaiScript/unittests/range_back.chai

5 lines
79 B
ChaiScript

auto x = {1, 2, 3, 4}
auto r = range(x)
r.pop_back()
assert_equal(3, r.back())