What would happen if a container that BOOST_FOREACH is iterating through is changed inside the BOOST_FOREACH scope?
Does BOOST_FOREACH "freeze" the initial state?
In this case behavior is undefined. Look at Hoisting and Iterator Invalidation in official documentation of BOOST_FOREACH
.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With