[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[ale] gcc-3.4.2 backwards-incompatibility?
- Subject: [ale] gcc-3.4.2 backwards-incompatibility?
- From: jkf at wolfnet.org (Jason Fritcher)
- Date: Thu Apr 28 20:29:19 2005
- In-reply-to: <[email protected]>
- References: <[email protected]>
Mills, John M. wrote:
> The module uses:
> #include <fstream>
>
> The build then fails on the declaration:
>
> fstream f(PREPROG_FNAME, ios::out);
>
> with the message:
> "preprogrammed.cc:201: error: `fstream' undeclared (first use this
> function)"
I don't see it mentioned above, so I'll assume the following is the problem. ;)
To be more standards compliant, gcc 3+ enforces namespaces. The standard C++
code like that is all in the std namespace, so you'll either need to include a
'using namespace std' statement near the top, or prefix all the library function
references with std::. I'd go with the former. :)
--
Jason Fritcher
jkf at wolfnet.org
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 254 bytes
Desc: OpenPGP digital signature