summaryrefslogtreecommitdiffstats
path: root/tools/libclang/CIndex.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'tools/libclang/CIndex.cpp')
-rw-r--r--tools/libclang/CIndex.cpp17
1 files changed, 14 insertions, 3 deletions
diff --git a/tools/libclang/CIndex.cpp b/tools/libclang/CIndex.cpp
index 05287bd..2216ec6 100644
--- a/tools/libclang/CIndex.cpp
+++ b/tools/libclang/CIndex.cpp
@@ -1879,6 +1879,7 @@ public:
void VisitOMPTaskyieldDirective(const OMPTaskyieldDirective *D);
void VisitOMPBarrierDirective(const OMPBarrierDirective *D);
void VisitOMPTaskwaitDirective(const OMPTaskwaitDirective *D);
+ void VisitOMPTaskgroupDirective(const OMPTaskgroupDirective *D);
void VisitOMPFlushDirective(const OMPFlushDirective *D);
void VisitOMPOrderedDirective(const OMPOrderedDirective *D);
void VisitOMPAtomicDirective(const OMPAtomicDirective *D);
@@ -2478,6 +2479,11 @@ void EnqueueVisitor::VisitOMPTaskwaitDirective(const OMPTaskwaitDirective *D) {
VisitOMPExecutableDirective(D);
}
+void EnqueueVisitor::VisitOMPTaskgroupDirective(
+ const OMPTaskgroupDirective *D) {
+ VisitOMPExecutableDirective(D);
+}
+
void EnqueueVisitor::VisitOMPFlushDirective(const OMPFlushDirective *D) {
VisitOMPExecutableDirective(D);
}
@@ -2883,7 +2889,8 @@ enum CXErrorCode clang_createTranslationUnit2(CXIndex CIdx,
IntrusiveRefCntPtr<DiagnosticsEngine> Diags =
CompilerInstance::createDiagnostics(new DiagnosticOptions());
std::unique_ptr<ASTUnit> AU = ASTUnit::LoadFromASTFile(
- ast_filename, Diags, FileSystemOpts, CXXIdx->getOnlyLocalDecls(), None,
+ ast_filename, CXXIdx->getPCHContainerOperations(), Diags, FileSystemOpts,
+ CXXIdx->getOnlyLocalDecls(), None,
/*CaptureDiagnostics=*/true,
/*AllowPCHWithCompilerErrors=*/true,
/*UserFilesAreVolatile=*/true);
@@ -3021,7 +3028,8 @@ static void clang_parseTranslationUnit_Impl(void *UserData) {
unsigned NumErrors = Diags->getClient()->getNumErrors();
std::unique_ptr<ASTUnit> ErrUnit;
std::unique_ptr<ASTUnit> Unit(ASTUnit::LoadFromCommandLine(
- Args->data(), Args->data() + Args->size(), Diags,
+ Args->data(), Args->data() + Args->size(),
+ CXXIdx->getPCHContainerOperations(), Diags,
CXXIdx->getClangResourcesPath(), CXXIdx->getOnlyLocalDecls(),
/*CaptureDiagnostics=*/true, *RemappedFiles.get(),
/*RemappedFilesKeepOriginalName=*/true, PrecompilePreamble, TUKind,
@@ -3262,7 +3270,8 @@ static void clang_reparseTranslationUnit_Impl(void *UserData) {
RemappedFiles->push_back(std::make_pair(UF.Filename, MB.release()));
}
- if (!CXXUnit->Reparse(*RemappedFiles.get()))
+ if (!CXXUnit->Reparse(CXXIdx->getPCHContainerOperations(),
+ *RemappedFiles.get()))
RTUI->result = CXError_Success;
else if (isASTReadError(CXXUnit))
RTUI->result = CXError_ASTReadError;
@@ -4260,6 +4269,8 @@ CXString clang_getCursorKindSpelling(enum CXCursorKind Kind) {
return cxstring::createRef("OMPBarrierDirective");
case CXCursor_OMPTaskwaitDirective:
return cxstring::createRef("OMPTaskwaitDirective");
+ case CXCursor_OMPTaskgroupDirective:
+ return cxstring::createRef("OMPTaskgroupDirective");
case CXCursor_OMPFlushDirective:
return cxstring::createRef("OMPFlushDirective");
case CXCursor_OMPOrderedDirective:
OpenPOWER on IntegriCloud