Home | History | Annotate | Download | only in Frontend

Lines Matching refs:Clang

14 #include "clang/Frontend/ASTUnit.h"
15 #include "clang/AST/ASTConsumer.h"
16 #include "clang/AST/ASTContext.h"
17 #include "clang/AST/DeclVisitor.h"
18 #include "clang/AST/StmtVisitor.h"
19 #include "clang/AST/TypeOrdering.h"
20 #include "clang/Basic/Diagnostic.h"
21 #include "clang/Basic/TargetInfo.h"
22 #include "clang/Basic/TargetOptions.h"
23 #include "clang/Frontend/CompilerInstance.h"
24 #include "clang/Frontend/FrontendActions.h"
25 #include "clang/Frontend/FrontendDiagnostic.h"
26 #include "clang/Frontend/FrontendOptions.h"
27 #include "clang/Frontend/MultiplexConsumer.h"
28 #include "clang/Frontend/Utils.h"
29 #include "clang/Lex/HeaderSearch.h"
30 #include "clang/Lex/Preprocessor.h"
31 #include "clang/Lex/PreprocessorOptions.h"
32 #include "clang/Serialization/ASTReader.h"
33 #include "clang/Serialization/ASTWriter.h"
50 using namespace clang;
1110 OwningPtr<CompilerInstance> Clang(new CompilerInstance());
1114 CICleanup(Clang.get());
1119 Clang->setInvocation(CCInvocation.getPtr());
1120 OriginalSourceFile = Clang->getFrontendOpts().Inputs[0].getFile();
1124 Clang->setDiagnostics(&getDiagnostics());
1127 Clang->setTarget(TargetInfo::CreateTargetInfo(Clang->getDiagnostics(),
1128 &Clang->getTargetOpts()));
1129 if (!Clang->hasTarget()) {
1138 Clang->getTarget().setForcedLangOptions(Clang->getLangOpts());
1140 assert(Clang->getFrontendOpts().Inputs.size() == 1 &&
1142 assert(Clang->getFrontendOpts().Inputs[0].getKind() != IK_AST &&
1144 assert(Clang->getFrontendOpts().Inputs[0].getKind() != IK_LLVM_IR &&
1149 LangOpts = &Clang->getLangOpts();
1150 FileSystemOpts = Clang->getFileSystemOpts();
1170 Clang->setFileManager(&getFileManager());
1173 Clang->setSourceManager(&getSourceManager());
1177 PreprocessorOptions &PreprocessorOpts = Clang->getPreprocessorOpts();
1204 if (!Act->BeginSourceFile(*Clang.get(), Clang->getFrontendOpts().Inputs[0]))
1209 TranslateStoredDiagnostics(Clang->getModuleManager(), ModName,
1217 transferASTDataFromCompilerInstance(*Clang);
1234 transferASTDataFromCompilerInstance(*Clang);
1568 OwningPtr<CompilerInstance> Clang(new CompilerInstance());
1572 CICleanup(Clang.get());
1574 Clang->setInvocation(&*PreambleInvocation);
1575 OriginalSourceFile = Clang->getFrontendOpts().Inputs[0].getFile();
1578 Clang->setDiagnostics(&getDiagnostics());
1581 Clang->setTarget(TargetInfo::CreateTargetInfo(Clang->getDiagnostics(),
1582 &Clang->getTargetOpts()));
1583 if (!Clang->hasTarget()) {
1596 Clang->getTarget().setForcedLangOptions(Clang->getLangOpts());
1598 assert(Clang->getFrontendOpts().Inputs.size() == 1 &&
1600 assert(Clang->getFrontendOpts().Inputs[0].getKind() != IK_AST &&
1602 assert(Clang->getFrontendOpts().Inputs[0].getKind() != IK_LLVM_IR &&
1607 ProcessWarningOptions(getDiagnostics(), Clang->getDiagnosticOpts());
1613 Clang->setFileManager(new FileManager(Clang->getFileSystemOpts()));
1616 Clang->setSourceManager(new SourceManager(getDiagnostics(),
1617 Clang->getFileManager()));
1621 if (!Act->BeginSourceFile(*Clang.get(), Clang->getFrontendOpts().Inputs[0])) {
1660 SourceManager &SourceMgr = Clang->getSourceManager();
1814 OwningPtr<CompilerInstance> Clang(new CompilerInstance());
1818 CICleanup(Clang.get());
1820 Clang->setInvocation(CI);
1821 AST->OriginalSourceFile = Clang->getFrontendOpts().Inputs[0].getFile();
1825 Clang->setDiagnostics(&AST->getDiagnostics());
1828 Clang->setTarget(TargetInfo::CreateTargetInfo(Clang->getDiagnostics(),
1829 &Clang->getTargetOpts()));
1830 if (!Clang->hasTarget())
1837 Clang->getTarget().setForcedLangOptions(Clang->getLangOpts());
1839 assert(Clang->getFrontendOpts().Inputs.size() == 1 &&
1841 assert(Clang->getFrontendOpts().Inputs[0].getKind() != IK_AST &&
1843 assert(Clang->getFrontendOpts().Inputs[0].getKind() != IK_LLVM_IR &&
1853 Clang->setFileManager(&AST->getFileManager());
1856 Clang->setSourceManager(&AST->getSourceManager());
1870 if (!Act->BeginSourceFile(*Clang.get(), Clang->getFrontendOpts().Inputs[0])) {
1871 AST->transferASTDataFromCompilerInstance(*Clang);
1879 Clang->getPreprocessor().addPPCallbacks(
1882 if (Clang->hasASTConsumer())
1883 Consumers.push_back(Clang->takeASTConsumer());
1886 Clang->setASTConsumer(new MultiplexConsumer(Consumers));
1889 AST->transferASTDataFromCompilerInstance(*Clang);
1897 AST->transferASTDataFromCompilerInstance(*Clang);
2001 CI = clang::createInvocationFromCommandLine(
2407 OwningPtr<CompilerInstance> Clang(new CompilerInstance());
2411 CICleanup(Clang.get());
2413 Clang->setInvocation(&*CCInvocation);
2414 OriginalSourceFile = Clang->getFrontendOpts().Inputs[0].getFile();
2417 Clang->setDiagnostics(&Diag);
2419 Clang->getDiagnostics(),
2424 Clang->setTarget(TargetInfo::CreateTargetInfo(Clang->getDiagnostics(),
2425 &Clang->getTargetOpts()));
2426 if (!Clang->hasTarget()) {
2427 Clang->setInvocation(0);
2435 Clang->getTarget().setForcedLangOptions(Clang->getLangOpts());
2437 assert(Clang->getFrontendOpts().Inputs.size() == 1 &&
2439 assert(Clang->getFrontendOpts().Inputs[0].getKind() != IK_AST &&
2441 assert(Clang->getFrontendOpts().Inputs[0].getKind() != IK_LLVM_IR &&
2446 Clang->setFileManager(&FileMgr);
2447 Clang->setSourceManager(&SourceMgr);
2468 Clang->setCodeCompletionConsumer(AugmentedConsumer);
2508 if (!Clang->getLangOpts().Modules)
2513 if (Act->BeginSourceFile(*Clang.get(), Clang->getFrontendOpts().Inputs[0])) {