So I'm very new to Boost but I'm running into problems trying to do some of the most basic of things in my win32 application project in vs2010.
I have gone into my vs2010 project properties and made sure that my include files are looking in the right places, and when I build I don't get errors including hpp files from boost in my stdafx.h, however when I read the documentation on their site here: http://www.boost.org/doc/libs/1_43_0/libs/spirit/doc/html/spirit/support/multi_pass.html I just get a bunch of basic errors like multi_pass is undefined.
I only need boost for one thing, and that is to create a forward operator from my current input operator so I can pass it through a function. Below is the declaration for my input operator.
std::istreambuf_iterator<char> eof;
I found an alternative solution on that same page where the std::basic_istream_iterator is actually a forward operator but when I compile I get an error saying that basic_istream_iterator is not part of the std library.
In the end I'm just really new to iterators themselves and boost. I would like to know how I can get my input iterator transformed into a forward iterator so I can iterator through a file.
std::basic_istream_iterator
; there's astd::istream_iterator
however. – 0x499602D2multi_pass
is undefined, you're not including the right headers. Did you follow the "complete source code" link from the multi_pass documentation page mentioned in your question - i.e. boost.org/doc/libs/1_43_0/libs/spirit/example/support/… ? Make sure you're including the headers listed there. Out of curiosity - you say you want a forward iterator so you can "pass it through a function", and "iterator through a file" - is that a Standard library function you want to use it with? Which one? Why isn't an input iterator enough? (there are valid reasons) – Tony Delroy