String as parameter of file.open()

My book says that file.open() only accepts C-string as parameter. However, when I try to use string as parameter, it works! I wonder if this is good to do or I should use the conventional way (C-string)?
The C++11 standard added support for using std::string as a parameter to the stream constructor, and open() function. So as long as you use the current standard you should be okay using the std::string.



Topic archived. No new replies allowed.