fs::native throws an exception. But fs::no_check works. Just wondering if
this is a "feature" that the boost developers are aware of.
Timo
"Heiko Fechner"
Hi,
try this fs::path full_path( "C:\\cygwin\\boost", fs::native );
Nat Goodspeed schrieb:
-----Original Message----- From: boost-users-bounces@lists.boost.org [mailto:boost-users-bounces@lists.boost.org] On Behalf Of Timo Sent: Monday, March 12, 2007 6:41 AM To: boost-users@lists.boost.org Subject: [Boost-users] Problem with fs::path initialization in windows
I have a little problem with initialization of boost filesystem path. I'm working on Cygwin in Windows XP.
But when I try to use a path of my own, say: c I get thrown with an exception. Same deal with the rest of the combinations I can think of: C:/cygwin/boost c:/cygwin/boost. c/cygwin and /cygwin don't throw but the paths are not found.
So how do initialize the fs::path with a Windows type of directory path?
[Nat] Have you tried something like: fs::path full_path("some string", fs::no_check); ? I've found that the best policy with boost::filesystem is to explicitly disable its name check on every instantiation. In fact I've introduced a local subclass with a constructor accepting a path string; the constructor simply passes the string to the base-class constructor along with boost::filesystem::no_check. _______________________________________________ Boost-users mailing list Boost-users@lists.boost.org http://lists.boost.org/mailman/listinfo.cgi/boost-users
--------------------------------------------------------------------------------
_______________________________________________ Boost-users mailing list Boost-users@lists.boost.org http://lists.boost.org/mailman/listinfo.cgi/boost-users