I'm trying to use .open() but I'm having an issue with my arguments to this function. Here's my code:
vector<string> FDT_filename; ifstream is; is.open (FDT_filename, ios::binary );
Which results in the following error:
../sim_main.cpp:297: error: no matching function for call to ‘std::basic_ofstream<char, std::char_traits<char> >::open(std::basic_string<char, std::char_traits<char>, std::allocator<char> >&, const std::_Ios_Openmode&)’ /usr/include/c++/4.2.1/fstream:650: note: candidates are: void std::basic_ofstream<_CharT, _Traits>::open(const char*, std::_Ios_Openmode) [with _CharT = char, _Traits = std::char_traits<char>]
In what way is my FDT_filename not correct? Does it need to be converted to a character and if so how? Keep in mind that FDT_filename[..] can be of arbitrary length.