Skip to content

Commit 0be0ca2

Browse files
committed
removed unnecessary --clang related output file
1 parent e89c55a commit 0be0ca2

File tree

1 file changed

+0
-11
lines changed

1 file changed

+0
-11
lines changed

lib/cppcheck.cpp

Lines changed: 0 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -659,9 +659,7 @@ unsigned int CppCheck::checkClang(const FileWithDetails &file)
659659

660660
// TODO: get language from FileWithDetails object
661661
const std::string analyzerInfo = mSettings.buildDir.empty() ? std::string() : AnalyzerInformation::getAnalyzerInfoFile(mSettings.buildDir, file.spath(), "");
662-
const std::string clangcmd = analyzerInfo + ".clang-cmd" + "." + std::to_string(mSettings.pid);
663662
const std::string clangStderr = analyzerInfo + ".clang-stderr" + "." + std::to_string(mSettings.pid);
664-
const std::string clangAst = analyzerInfo + ".clang-ast" + "." + std::to_string(mSettings.pid);
665663
std::string exe = mSettings.clangExecutable;
666664
#ifdef _WIN32
667665
// append .exe if it is not a path
@@ -674,10 +672,6 @@ unsigned int CppCheck::checkClang(const FileWithDetails &file)
674672
getClangFlags(Path::identify(file.spath(), mSettings.cppHeaderProbe)) +
675673
file.spath();
676674
const std::string redirect2 = analyzerInfo.empty() ? std::string("2>&1") : ("2> " + clangStderr);
677-
if (!mSettings.buildDir.empty()) {
678-
std::ofstream fout(clangcmd);
679-
fout << exe << " " << args2 << " " << redirect2 << std::endl;
680-
}
681675
if (mSettings.verbose && !mSettings.quiet) {
682676
mErrorLogger.reportOut(exe + " " + args2);
683677
}
@@ -714,11 +708,6 @@ unsigned int CppCheck::checkClang(const FileWithDetails &file)
714708
return 0; // TODO: report as failure?
715709
}
716710

717-
if (!mSettings.buildDir.empty()) {
718-
std::ofstream fout(clangAst);
719-
fout << output2 << std::endl;
720-
}
721-
722711
try {
723712
Tokenizer tokenizer(mSettings, mErrorLogger);
724713
tokenizer.list.appendFileIfNew(file.spath());

0 commit comments

Comments
 (0)