diff --git a/lib/ctu.cpp b/lib/ctu.cpp index c6728315de0..f186ade9543 100644 --- a/lib/ctu.cpp +++ b/lib/ctu.cpp @@ -214,6 +214,7 @@ bool CTU::FileInfo::FunctionCall::loadFromXml(const tinyxml2::XMLElement *xmlEle const int column = readAttrInt(e2, ATTR_LOC_COLUMN, &error); ErrorMessage::FileLocation loc(file, line, column); loc.setinfo(readAttrString(e2, ATTR_INFO, &error)); + // TODO: loc is unused } return !error; } diff --git a/lib/errorlogger.h b/lib/errorlogger.h index 56051125db1..39b61df3e5b 100644 --- a/lib/errorlogger.h +++ b/lib/errorlogger.h @@ -52,7 +52,7 @@ class CPPCHECKLIB ErrorMessage { * Internally paths are stored with / separator. When getting the filename * it is by default converted to native separators. */ - class CPPCHECKLIB FileLocation { + class CPPCHECKLIB WARN_UNUSED FileLocation { public: FileLocation(const std::string &file, int line, unsigned int column) : fileIndex(0), line(line), column(column), mOrigFileName(file), mFileName(file) {}