main.cpp: In function ‘void getMap()’:
main.cpp:58:29: error: no matching function for call to ‘std::basic_fstream<char>::open(std::string&, const openmode&)’
file.open(file_name, ios::in);
^
main.cpp:58:29: note: candidate is:
In file included from main.cpp:5:0:
/usr/include/c++/4.8/fstream:886:7: note: void std::basic_fstream<_CharT, _Traits>::open(const char*, std::ios_base::openmode) [with _CharT = char; _Traits = std::char_traits<char>; std::ios_base::openmode = std::_Ios_Openmode]
open(const char* __s
^
/usr/include/c++/4.8/fstream:886:7: note: no known conversion for argument 1 from ‘std::string {aka std::basic_string<char>}’ to ‘const char*’
https://travis-ci.com/Nircek/labirynt/builds/85000113
https://github.com/Nircek/labirynt/blob/805cf015dfa1c23e83503509165e490bf62d7243/main.cpp#L17 Wystarczy scastować tego
string
a w pierwszym argumencie naconst char*
a