From 295e4fdfc21c2f61a3e9b9e79ddd81c97ce91c84 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Daniel=20Marjam=C3=A4ki?= Date: Tue, 2 May 2017 22:18:24 +0200 Subject: [PATCH] Fixed #8049 (Preprocessor: Comment in system include not removed properly) --- lib/preprocessor.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/lib/preprocessor.cpp b/lib/preprocessor.cpp index fa7297fb0..cde6f6526 100644 --- a/lib/preprocessor.cpp +++ b/lib/preprocessor.cpp @@ -611,6 +611,8 @@ std::string Preprocessor::getcode(const simplecpp::TokenList &tokens1, const std if (hasErrors(outputList)) return ""; + tokens2.removeComments(); + // ensure that guessed define macros without value are not used in the code if (!validateCfg(cfg, macroUsage)) return "";