MCPcopy Create free account
hub / github.com/cppcheck-opensource/cppcheck / getErrorMessages

Method getErrorMessages

lib/preprocessor.cpp:1067–1084  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1065}
1066
1067void Preprocessor::getErrorMessages(ErrorLogger &errorLogger, const Settings &settings)
1068{
1069 std::vector<std::string> files;
1070 simplecpp::TokenList tokens(files);
1071 Preprocessor preprocessor(tokens, settings, errorLogger, Standards::Language::CPP);
1072 simplecpp::Location loc;
1073 loc.line = 1;
1074 loc.col = 2;
1075 preprocessor.missingInclude(loc, "", UserHeader);
1076 preprocessor.missingInclude(loc, "", SystemHeader);
1077 preprocessor.error(loc, "message", simplecpp::Output::ERROR);
1078 preprocessor.error(loc, "message", simplecpp::Output::SYNTAX_ERROR);
1079 preprocessor.error(loc, "message", simplecpp::Output::UNHANDLED_CHAR_ERROR);
1080 preprocessor.error(loc, "message", simplecpp::Output::INCLUDE_NESTED_TOO_DEEPLY);
1081 preprocessor.error(loc, "message", simplecpp::Output::FILE_NOT_FOUND);
1082 preprocessor.error(loc, "message", simplecpp::Output::EXPLICIT_INCLUDE_NOT_FOUND);
1083 preprocessor.invalidSuppression(loc, "message");
1084}
1085
1086void Preprocessor::dump(std::ostream &out) const
1087{

Callers

nothing calls this directly

Calls 3

missingIncludeMethod · 0.80
invalidSuppressionMethod · 0.80
errorMethod · 0.45

Tested by

no test coverage detected