on Wed Jul 11 2007, Max Motovilov
It is not immediately obvious how to correctly specify the template arguments for boost::iterator_facade<> with an output iterator. This particular case is not mentioned in the tutorial and the first impression is that using such category as std::output_iterator_tag should be all that's required. This is not the case; in order for the postincrement temporary NOT to create a copy of a [fake] pointed-to value OR a copy of the proxy, the user has to be very careful about Value and Reference arguments. Took me 3 tries and a thorough look into the sources to get it right: Value=
and Reference=Proxy&. Would be nice to add this use case to the tutorial since it is definitely tricky and error-prone as it is.
It sounds like you're the perfect candidate to write those docs. Patches gratefully accepted. -- Dave Abrahams Boost Consulting http://www.boost-consulting.com The Astoria Seminar ==> http://www.astoriaseminar.com