#include "clang/Frontend/Utils.h"
#include "clang/Basic/FileManager.h"
#include "clang/Basic/SourceManager.h"
#include "clang/Frontend/FrontendDiagnostic.h"
#include "clang/Lex/PPCallbacks.h"
#include "clang/Lex/Preprocessor.h"
#include "llvm/ADT/SetVector.h"
#include "llvm/Support/GraphWriter.h"
#include "llvm/Support/raw_ostream.h"
usingnamespaceclang;
DOT;
namespace {
class DependencyGraphCallback : public PPCallbacks { … };
}
void clang::AttachDependencyGraphGen(Preprocessor &PP, StringRef OutputFile,
StringRef SysRoot) { … }
void DependencyGraphCallback::InclusionDirective(
SourceLocation HashLoc, const Token &IncludeTok, StringRef FileName,
bool IsAngled, CharSourceRange FilenameRange, OptionalFileEntryRef File,
StringRef SearchPath, StringRef RelativePath, const Module *SuggestedModule,
bool ModuleImported, SrcMgr::CharacteristicKind FileType) { … }
void DependencyGraphCallback::EmbedDirective(SourceLocation HashLoc, StringRef,
bool, OptionalFileEntryRef File,
const LexEmbedParametersResult &) { … }
raw_ostream &
DependencyGraphCallback::writeNodeReference(raw_ostream &OS,
const FileEntry *Node) { … }
void DependencyGraphCallback::OutputGraphFile() { … }