33a1e511b5
N3644 implies that operator- can be used on value-init iterators. We now return 0 if both iterators are value initialized. If only one is value initialized we keep the UB by returning the result of a normal computation which is a meaningless value. libstdc++-v3/ChangeLog: PR libstdc++/70303 * include/bits/stl_deque.h (std::deque<>::operator-(iterator, iterator)): Return 0 if both iterators are value-initialized. * testsuite/23_containers/deque/70303.cc: New test. * testsuite/23_containers/vector/70303.cc: New test. |
||
---|---|---|
.. | ||
backward | ||
bits | ||
c | ||
c_compatibility | ||
c_global | ||
c_std | ||
debug | ||
decimal | ||
experimental | ||
ext | ||
parallel | ||
precompiled | ||
pstl | ||
std | ||
tr1 | ||
tr2 | ||
Makefile.am | ||
Makefile.in |