What strategy should I use if I have an implementation of std::fstream with 32-bit std::streampos? If I want to move position I can do it in several steps(10gb – 10 times +1gb). How can I get position? Or should I keep current position in some variable outside fstream?
P.S. I can’t change the implementation of STL.
Keeping track of the current position yourself is the most straight-forward answer, if you’re unable to addle the STL. If your compiler support the
long longtype, I’d go with that.