From 94454df14ff9fda84377d999b8963fc693182170 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Daniel=20Marjam=C3=A4ki?= Date: Tue, 11 Mar 2014 16:05:19 +0100 Subject: [PATCH] Fixed #2732 (Make it easier for users to tell 'How to supply header files') --- lib/preprocessor.cpp | 2 +- test/testpreprocessor.cpp | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/lib/preprocessor.cpp b/lib/preprocessor.cpp index 7edb84062..ffdd9ce42 100644 --- a/lib/preprocessor.cpp +++ b/lib/preprocessor.cpp @@ -2378,7 +2378,7 @@ void Preprocessor::missingInclude(const std::string &filename, unsigned int line locationList.push_back(loc); } ErrorLogger::ErrorMessage errmsg(locationList, Severity::information, - (headerType==SystemHeader) ? "Include file: <" + header + "> not found." : "Include file: \"" + header + "\" not found.", + (headerType==SystemHeader) ? "Include file: <" + header + "> not found." : "Include file: \"" + header + "\" not found. Use -I to configure include paths.", msgtype, false); errmsg.file0 = file0; _errorLogger->reportInfo(errmsg); diff --git a/test/testpreprocessor.cpp b/test/testpreprocessor.cpp index c21dfe5f2..3f9e63ca5 100644 --- a/test/testpreprocessor.cpp +++ b/test/testpreprocessor.cpp @@ -3535,7 +3535,7 @@ private: errout.str(""); settings.checkConfiguration = true; preprocessor.handleIncludes(code,"test.c",includePaths,defs,pragmaOnce,std::list()); - ASSERT_EQUALS("[test.c:1]: (information) Include file: \"missing-include!!.h\" not found.\n", errout.str()); + ASSERT_EQUALS("[test.c:1]: (information) Include file: \"missing-include!!.h\" not found. Use -I to configure include paths.\n", errout.str()); pragmaOnce.clear(); errout.str(""); @@ -3882,7 +3882,7 @@ private: preprocessor.preprocess(istr, actual, "file.c"); // Compare results.. - ASSERT_EQUALS("[file.c:2]: (information) Include file: \"config.h\" not found.\n", errout.str()); + ASSERT_EQUALS("[file.c:2]: (information) Include file: \"config.h\" not found. Use -I to configure include paths.\n", errout.str()); ASSERT_EQUALS("\n\n\n\n\n", actual[""]); }