attach is not a member of ofstream

Hi,

Code written in C++ got compiled successfully using Sun 4.2 Compiler on Solaris 6. As part of migration, i am using same code and trying to compile using Sun 5.8 C++ compiler(Sun Studio11) on Solaris 10 and could not compile the below line,

outStr.attach(1); // here outStr is declared as "static ofstream outStr;"

Error displayed is :
"
Error: attach is not a member of std::ofstream
"

Please suggest how to use attach with Sun 5.8 compiler.

Thanks,
Shafi

attach() is not a standard member of iostream and never was. You'll have to use a nonstandard extension of some sort to accomplish this. I know how to do this in GNU libc but not solaris...