hennep
Programmer
- Dec 10, 2000
- 429
auto_ptr does not compile in BCB5
The first sample generates an error the second compiles allright.
// !!! #include <memory>
std::auto_ptr<char> buf;
buf = std::auto_ptr<char>(new char[1024]);
// !!! #include <memory>
std::auto_ptr<char> buf = std::auto_ptr<char>(new char[1024]);
The code I am working on has a declaration in a header and assignment in cpp.
How to proceed ?
hennep
P.S. please don't tell me to compile it with VC (this works).
The first sample generates an error the second compiles allright.
// !!! #include <memory>
std::auto_ptr<char> buf;
buf = std::auto_ptr<char>(new char[1024]);
// !!! #include <memory>
std::auto_ptr<char> buf = std::auto_ptr<char>(new char[1024]);
The code I am working on has a declaration in a header and assignment in cpp.
How to proceed ?
hennep
P.S. please don't tell me to compile it with VC (this works).