diff --git a/include/libdbc/dbc.hpp b/include/libdbc/dbc.hpp index b732895..2dfe7bf 100644 --- a/include/libdbc/dbc.hpp +++ b/include/libdbc/dbc.hpp @@ -52,7 +52,7 @@ class DbcParser : public Parser { void parse_dbc_nodes(std::istream& file_stream); void parse_dbc_messages(const std::vector& lines); - std::string get_extension(const std::string& file_name); + static std::string get_extension(const std::string& file_name); }; } diff --git a/src/dbc.cpp b/src/dbc.cpp index 5c3e2c0..108ab7e 100644 --- a/src/dbc.cpp +++ b/src/dbc.cpp @@ -1,4 +1,5 @@ #include +#include #include #include #include @@ -93,7 +94,7 @@ void DbcParser::parse_file(const std::string& file) { } std::string DbcParser::get_extension(const std::string& file_name) { - size_t dot = file_name.find_last_of("."); + std::size_t dot = file_name.find_last_of("."); if (dot != std::string::npos) { return file_name.substr(dot, file_name.size() - dot); }