Boost logo

Boost Users :

Subject: Re: [Boost-users] [ptr_container] Transferring the Last Element from a ptr_vector
From: Nat Goodspeed (nat_at_[hidden])
Date: 2009-09-10 10:47:31


Steven Watanabe wrote:

> The ability to decrement any bidirectional iterator
> except begin() is required by the standard. All Bidirectional
> iterators /must/ support this, including the iterators of
> std::vector. (See 24.1.4, Table 75)

I guess I was conflating the case of

(iterator returned by a bidirectional container's end())

with

(end-marker iterator obtained by default-constructing certain types of
iterators).

I'm glad to learn that you can reliably decrement the iterator returned
by end(), providing it's not equal to the iterator returned by begin().


Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net