llvm-project/clang/lib/Frontend
David Stenberg d45d7eae05 Fix emission of phony dependency targets when adding extra deps
Summary:
This commit fixes a bug where passing extra dependency entries
(using -fdepfile-entry) would result in -MP incorrectly emitting
a phony target for the input file, and no phony target for the
first extra dependency.

The extra dependencies are added first to the filename vector in
DFGImpl. That clashed with the emission of the phony targets, as
the code assumed that the first index always correspond to the
input file.

Reviewers: rsmith, pcc, krasin, bruno, vsapsai

Reviewed By: vsapsai

Subscribers: vsapsai, bruno, cfe-commits

Differential Revision: https://reviews.llvm.org/D44568

llvm-svn: 333413
2018-05-29 13:07:58 +00:00
..
Rewrite Reland '[clang] Adding CharacteristicKind to PPCallbacks::InclusionDirective' 2018-05-10 19:05:36 +00:00
ASTConsumers.cpp [AST] Fix -ast-print for _Bool when have diagnostics 2018-05-14 18:41:44 +00:00
ASTMerge.cpp Revert r329684 (and follow-ups 329693, 329714). See discussion on https://reviews.llvm.org/D43578. 2018-04-10 18:53:28 +00:00
ASTUnit.cpp Optionally add code completion results for arrow instead of dot 2018-05-25 12:56:26 +00:00
CMakeLists.txt Use special new Clang flag 'FrontendTimesIsEnabled' instead of 'llvm::TimePassesIsEnabled' inside -ftime-report feature. 2018-04-23 09:22:30 +00:00
CacheTokens.cpp Support: Simplify endian stream interface. NFCI. 2018-05-18 19:46:24 +00:00
ChainedDiagnosticConsumer.cpp
ChainedIncludesSource.cpp Teach ASTReader how to read only the Preprocessor state from an AST file, not the ASTContext state. 2017-06-29 23:23:46 +00:00
CodeGenOptions.cpp Use an enum value instead of a string. 2018-01-18 00:20:03 +00:00
CompilerInstance.cpp Improve diagnostics for config mismatches with -fmodule-file. 2018-05-24 20:03:51 +00:00
CompilerInvocation.cpp [Support] Avoid normalization in sys::getDefaultTargetTriple 2018-05-25 20:39:37 +00:00
CreateInvocationFromCommandLine.cpp Use vfs::FileSystem in ASTUnit when creating CompilerInvocation. 2017-06-28 15:06:34 +00:00
DependencyFile.cpp Fix emission of phony dependency targets when adding extra deps 2018-05-29 13:07:58 +00:00
DependencyGraph.cpp Reland '[clang] Adding CharacteristicKind to PPCallbacks::InclusionDirective' 2018-05-10 19:05:36 +00:00
DiagnosticRenderer.cpp Remove \brief commands from doxygen comments. 2018-05-09 01:00:01 +00:00
FrontendAction.cpp Print the qualified name when dumping deserialized decls. 2018-05-20 09:38:52 +00:00
FrontendActions.cpp Remove \brief commands from doxygen comments. 2018-05-09 01:00:01 +00:00
FrontendOptions.cpp [Frontend] Fix some Clang-tidy modernize and Include What You Use warnings; other minor fixes (NFC). 2018-03-26 21:45:04 +00:00
FrontendTiming.cpp Use special new Clang flag 'FrontendTimesIsEnabled' instead of 'llvm::TimePassesIsEnabled' inside -ftime-report feature. 2018-04-23 09:22:30 +00:00
HeaderIncludeGen.cpp [clang-cl] Print /showIncludes to stderr, if used in combination with /E, /EP or /P 2018-05-04 15:58:31 +00:00
InitHeaderSearch.cpp s/LLVM_ON_WIN32/_WIN32/, clang 2018-04-27 19:11:14 +00:00
InitPreprocessor.cpp Revert "Revert r332955 "GNUstep Objective-C ABI version 2"" 2018-05-22 10:13:06 +00:00
LangStandards.cpp Don't accept -std= values that would switch us to a different source language. 2017-04-26 23:44:33 +00:00
LayoutOverrideSource.cpp Remove \brief commands from doxygen comments. 2018-05-09 01:00:01 +00:00
LogDiagnosticPrinter.cpp Replace double negation of !FileID.isInvalid() with FileID.isValid(). 2015-10-03 10:46:20 +00:00
ModuleDependencyCollector.cpp Reland '[clang] Adding CharacteristicKind to PPCallbacks::InclusionDirective' 2018-05-10 19:05:36 +00:00
MultiplexConsumer.cpp Make MultiplexASTDeserializationListener part of the API [NFC] 2018-04-27 07:05:40 +00:00
PCHContainerOperations.cpp Remove \brief commands from doxygen comments. 2018-05-09 01:00:01 +00:00
PrecompiledPreamble.cpp s/LLVM_ON_WIN32/_WIN32/, clang 2018-04-27 19:11:14 +00:00
PrintPreprocessedOutput.cpp Reland '[clang] Adding CharacteristicKind to PPCallbacks::InclusionDirective' 2018-05-10 19:05:36 +00:00
SerializedDiagnosticPrinter.cpp Remove \brief commands from doxygen comments. 2018-05-09 01:00:01 +00:00
SerializedDiagnosticReader.cpp [Frontend] Fix some Clang-tidy modernize and Include What You Use warnings; other minor fixes (NFC). 2018-03-26 21:45:04 +00:00
TestModuleFileExtension.cpp Fix for LLVM Bitcode API change (to use std::shared_ptr) 2017-01-04 22:36:43 +00:00
TestModuleFileExtension.h Module file extensions: pass a Sema through to the extension writer. 2015-12-08 22:43:32 +00:00
TextDiagnostic.cpp Remove \brief commands from doxygen comments. 2018-05-09 01:00:01 +00:00
TextDiagnosticBuffer.cpp [Frontend] Fix some Clang-tidy modernize and Include What You Use warnings; other minor fixes (NFC). 2018-03-22 00:53:26 +00:00
TextDiagnosticPrinter.cpp Remove \brief commands from doxygen comments. 2018-05-09 01:00:01 +00:00
VerifyDiagnosticConsumer.cpp Remove \brief commands from doxygen comments. 2018-05-09 01:00:01 +00:00