Opened 16 years ago

Closed 16 years ago

Last modified 14 years ago

#625 deleted Support Requests (None)

Cannot access boost::filesystem namespace

Reported by: nobody Owned by: nobody
Milestone: Component: filesystem
Version: None Severity: Cosmetic
Keywords: Cc:

Description

Hi.

I am quite new to programming, however, I decided to
install the boost library as it looks very good.

The first two lines of my program are:
#include "boost/filesystem/operations.hpp"
#include "boost/filesystem/fstream.hpp" 

Yet when I include the statement:
using boost::filesystem;
just after, I get an error message saying:
"error C2873: 'boost::filesystem' : symbol cannot be
used in a using-declaration"

I am using Microsoft Visual Studio 2005. Where could I
have gone wrong? I have tried to find documentation
that will help, but I haven't found anything. I have
followed the installation to the letter.


Change History (6)

comment:1 by nobody, 16 years ago

Logged In: NO 

Hi.

I think I have figured out the problem. I was missing the
keyword 'namespace', (which doesn't appear to be in the
example). Everything seems to be ok now, so please feel free
to delete this post.

comment:2 by vawjr, 16 years ago

Logged In: YES 
user_id=5962

using namespace boost::filesystem;


comment:3 by nobody, 16 years ago

Logged In: NO 

boost::filesystem is only a namespace, so you should
probably write 'using namespace boost::filesystem;'

comment:4 by Gennaro Prota, 16 years ago

Status: assignedclosed

comment:5 by Daryle Walker, 14 years ago

Component: Nonefilesystem
Severity: Showstopper

comment:6 by Daryle Walker, 14 years ago

Severity: ShowstopperCosmetic
Note: See TracTickets for help on using tickets.