"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "lib/preprocessor.cpp" between
cppcheck-1.86.tar.gz and cppcheck-1.87.tar.gz

About: Cppcheck is a static analysis tool for C/C++ code. It checks for memory leaks, mismatching allocation-deallocation, buffer overrun, and many more.

preprocessor.cpp  (cppcheck-1.86):preprocessor.cpp  (cppcheck-1.87)
/* /*
* Cppcheck - A tool for static C/C++ code analysis * Cppcheck - A tool for static C/C++ code analysis
* Copyright (C) 2007-2018 Cppcheck team. * Copyright (C) 2007-2019 Cppcheck team.
* *
* This program is free software: you can redistribute it and/or modify * This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by * it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or * the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version. * (at your option) any later version.
* *
* This program is distributed in the hope that it will be useful, * This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of * but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details. * GNU General Public License for more details.
skipping to change at line 821 skipping to change at line 821
const ErrorLogger::ErrorMessage::FileLocation loc(file, line); const ErrorLogger::ErrorMessage::FileLocation loc(file, line);
locationList.push_back(loc); locationList.push_back(loc);
const ErrorLogger::ErrorMessage errmsg(locationList, mFile0, Severity::infor mation, "Skipping configuration '" + cfg + "' since the value of '" + macro + "' is unknown. Use -D if you want to check it. You can use -U to skip it explicitl y.", id, false); const ErrorLogger::ErrorMessage errmsg(locationList, mFile0, Severity::infor mation, "Skipping configuration '" + cfg + "' since the value of '" + macro + "' is unknown. Use -D if you want to check it. You can use -U to skip it explicitl y.", id, false);
mErrorLogger->reportInfo(errmsg); mErrorLogger->reportInfo(errmsg);
} }
void Preprocessor::getErrorMessages(ErrorLogger *errorLogger, const Settings *se ttings) void Preprocessor::getErrorMessages(ErrorLogger *errorLogger, const Settings *se ttings)
{ {
Settings settings2(*settings); Settings settings2(*settings);
Preprocessor preprocessor(settings2, errorLogger); Preprocessor preprocessor(settings2, errorLogger);
settings2.checkConfiguration=true; settings2.checkConfiguration = true;
preprocessor.missingInclude(emptyString, 1, emptyString, UserHeader); preprocessor.missingInclude(emptyString, 1, emptyString, UserHeader);
preprocessor.missingInclude(emptyString, 1, emptyString, SystemHeader); preprocessor.missingInclude(emptyString, 1, emptyString, SystemHeader);
preprocessor.validateCfgError(emptyString, 1, "X", "X"); preprocessor.validateCfgError(emptyString, 1, "X", "X");
preprocessor.error(emptyString, 1, "#error message"); // #error .. preprocessor.error(emptyString, 1, "#error message"); // #error ..
} }
void Preprocessor::dump(std::ostream &out) const void Preprocessor::dump(std::ostream &out) const
{ {
// Create a xml directive dump. // Create a xml directive dump.
// The idea is not that this will be readable for humans. It's a // The idea is not that this will be readable for humans. It's a
 End of changes. 2 change blocks. 
2 lines changed or deleted 2 lines changed or added

Home  |  About  |  Features  |  All  |  Newest  |  Dox  |  Diffs  |  RSS Feeds  |  Screenshots  |  Comments  |  Imprint  |  Privacy  |  HTTP(S)