From 88cd9921591d8a9d61cd0a7f7ebc9149fa363a4b Mon Sep 17 00:00:00 2001 From: "royqh1979@gmail.com" Date: Sat, 9 Oct 2021 18:04:31 +0800 Subject: [PATCH] - fix: should use c++ syntax to check ".h" files --- NEWS.md | 3 +++ RedPandaIDE/compiler/stdincompiler.cpp | 2 +- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/NEWS.md b/NEWS.md index 0df866a5..9eaf8ecf 100644 --- a/NEWS.md +++ b/NEWS.md @@ -1,3 +1,6 @@ +Version 0.6.3 + - fix: should use c++ syntax to check ".h" files + Version 0.6.2 - fix: The Enter key in the numpad doesn't work - fix: The compiled executable not fully write to the disk before run it diff --git a/RedPandaIDE/compiler/stdincompiler.cpp b/RedPandaIDE/compiler/stdincompiler.cpp index 46bfb8d3..ff7cb435 100644 --- a/RedPandaIDE/compiler/stdincompiler.cpp +++ b/RedPandaIDE/compiler/stdincompiler.cpp @@ -27,7 +27,6 @@ bool StdinCompiler::prepareForCompile() mArguments += getCharsetArgument(pCharsetInfoManager->getDefaultSystemEncoding()); switch(fileType) { case FileType::CSource: - case FileType::CHeader: mArguments += " -x c - "; mArguments += getCCompileArguments(mOnlyCheckSyntax); mArguments += getCIncludeArguments(); @@ -37,6 +36,7 @@ bool StdinCompiler::prepareForCompile() break; case FileType::CppSource: case FileType::CppHeader: + case FileType::CHeader: mArguments += " -x c++ - "; mArguments += getCppCompileArguments(mOnlyCheckSyntax); mArguments += getCppIncludeArguments();