Details
-
Bug
-
Status: Open
-
Minor
-
Resolution: Unresolved
-
4.2.1
-
None
-
Usability
Description
LWG issue 454 proposes to change [filebuf.members] from:
basic_filebuf<charT,traits>* open(const char* s, ios_base::openmode mode);Effects: If is_open() != false, returns a null pointer. Otherwise, initializes the filebuf as required. It then opens a file, if possible, whose name is the NTBS s ("as if" by calling std::fopen(s, modstr)).
to:
basic_filebuf<charT,traits>* open(const char* s, ios_base::openmode mode); basic_filebuf<charT,traits>* open(const wchar_t* ws, ios_base::openmode mode);Effects: If is_open() != false, returns a null pointer. Otherwise, initializes the filebuf as required. It then opens a file, if possible, whose name is the NTBS s ("as if" by calling std::fopen(s, modstr)). For the second signature, the NTBS s is determined from the WCBS ws in an implementation-defined manner.
(NOTE: For a system that "naturally" represents a filename as a WCBS, the NTBS s in the first signature may instead be mapped to a WCBS; if so, it follows the same mapping rules as the first argument to open.)