Boost logo

Boost :

From: me22 (me22.ca_at_[hidden])
Date: 2006-04-02 21:57:57


On 4/2/06, Wang Weiwei <wwwang_at_[hidden]> wrote:
> namespace fs = boost::filesystem;
> fs::path p("d:/temp");
>
> and I got an exception saying that "d:" in the input path is invalid.
>

The constructor you're calling in this case expects the portable path
format, not the native one. You need to tell it that it's a
native-format path:
fs::path p("d:/temp",fs::path::native); // iirc

I think this might be changing in the new and improved version in the
soon-to-be-released 1.34 however, so you might want to start
using/wait for the new version.

~ Scott


Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk