|
Boost Users : |
Subject: Re: [Boost-users] [Boost.PropertyTree] Application hangs (Boost 1.61)
From: Daniel Hofmann (daniel_at_[hidden])
Date: 2016-06-24 18:23:38
On 06/24/2016 11:24 PM, Andrew C wrote:
> Hi!
>
> It seems to be a bug that this application hangs inside "erase" method:
>
> #include <boost/property_tree/ptree.hpp>
> int main()
> {
> boost::property_tree::ptree pt;
> pt.erase(pt.begin()); // enters infinite loop...
> }
>
> Compiled with Cygwin/GCC-5.4.0.
>
> Is it really a bug or my misuse?
erase(begin()) is equivalent to pop_front. An empty collection does not
fulfill the pre-condition for this. What do you expect should happen?
Daniel J H
>
> Thanks!
>
>
>
> _______________________________________________
> Boost-users mailing list
> Boost-users_at_[hidden]
> http://lists.boost.org/mailman/listinfo.cgi/boost-users
>
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