/Users/buildslave/jenkins/workspace/coverage/llvm-project/clang/lib/AST/ASTImporter.cpp
Line | Count | Source (jump to first uncovered line) |
1 | | //===- ASTImporter.cpp - Importing ASTs from other Contexts ---------------===// |
2 | | // |
3 | | // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. |
4 | | // See https://llvm.org/LICENSE.txt for license information. |
5 | | // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception |
6 | | // |
7 | | //===----------------------------------------------------------------------===// |
8 | | // |
9 | | // This file defines the ASTImporter class which imports AST nodes from one |
10 | | // context into another context. |
11 | | // |
12 | | //===----------------------------------------------------------------------===// |
13 | | |
14 | | #include "clang/AST/ASTImporter.h" |
15 | | #include "clang/AST/ASTImporterSharedState.h" |
16 | | #include "clang/AST/ASTContext.h" |
17 | | #include "clang/AST/ASTDiagnostic.h" |
18 | | #include "clang/AST/ASTStructuralEquivalence.h" |
19 | | #include "clang/AST/Attr.h" |
20 | | #include "clang/AST/Decl.h" |
21 | | #include "clang/AST/DeclAccessPair.h" |
22 | | #include "clang/AST/DeclBase.h" |
23 | | #include "clang/AST/DeclCXX.h" |
24 | | #include "clang/AST/DeclFriend.h" |
25 | | #include "clang/AST/DeclGroup.h" |
26 | | #include "clang/AST/DeclObjC.h" |
27 | | #include "clang/AST/DeclTemplate.h" |
28 | | #include "clang/AST/DeclVisitor.h" |
29 | | #include "clang/AST/DeclarationName.h" |
30 | | #include "clang/AST/Expr.h" |
31 | | #include "clang/AST/ExprCXX.h" |
32 | | #include "clang/AST/ExprObjC.h" |
33 | | #include "clang/AST/ExternalASTSource.h" |
34 | | #include "clang/AST/LambdaCapture.h" |
35 | | #include "clang/AST/NestedNameSpecifier.h" |
36 | | #include "clang/AST/OperationKinds.h" |
37 | | #include "clang/AST/Stmt.h" |
38 | | #include "clang/AST/StmtCXX.h" |
39 | | #include "clang/AST/StmtObjC.h" |
40 | | #include "clang/AST/StmtVisitor.h" |
41 | | #include "clang/AST/TemplateBase.h" |
42 | | #include "clang/AST/TemplateName.h" |
43 | | #include "clang/AST/Type.h" |
44 | | #include "clang/AST/TypeLoc.h" |
45 | | #include "clang/AST/TypeVisitor.h" |
46 | | #include "clang/AST/UnresolvedSet.h" |
47 | | #include "clang/Basic/Builtins.h" |
48 | | #include "clang/Basic/ExceptionSpecificationType.h" |
49 | | #include "clang/Basic/FileManager.h" |
50 | | #include "clang/Basic/IdentifierTable.h" |
51 | | #include "clang/Basic/LLVM.h" |
52 | | #include "clang/Basic/LangOptions.h" |
53 | | #include "clang/Basic/SourceLocation.h" |
54 | | #include "clang/Basic/SourceManager.h" |
55 | | #include "clang/Basic/Specifiers.h" |
56 | | #include "llvm/ADT/APSInt.h" |
57 | | #include "llvm/ADT/ArrayRef.h" |
58 | | #include "llvm/ADT/DenseMap.h" |
59 | | #include "llvm/ADT/None.h" |
60 | | #include "llvm/ADT/Optional.h" |
61 | | #include "llvm/ADT/ScopeExit.h" |
62 | | #include "llvm/ADT/STLExtras.h" |
63 | | #include "llvm/ADT/SmallVector.h" |
64 | | #include "llvm/Support/Casting.h" |
65 | | #include "llvm/Support/ErrorHandling.h" |
66 | | #include "llvm/Support/MemoryBuffer.h" |
67 | | #include <algorithm> |
68 | | #include <cassert> |
69 | | #include <cstddef> |
70 | | #include <memory> |
71 | | #include <type_traits> |
72 | | #include <utility> |
73 | | |
74 | | namespace clang { |
75 | | |
76 | | using llvm::make_error; |
77 | | using llvm::Error; |
78 | | using llvm::Expected; |
79 | | using ExpectedTypePtr = llvm::Expected<const Type *>; |
80 | | using ExpectedType = llvm::Expected<QualType>; |
81 | | using ExpectedStmt = llvm::Expected<Stmt *>; |
82 | | using ExpectedExpr = llvm::Expected<Expr *>; |
83 | | using ExpectedDecl = llvm::Expected<Decl *>; |
84 | | using ExpectedSLoc = llvm::Expected<SourceLocation>; |
85 | | using ExpectedName = llvm::Expected<DeclarationName>; |
86 | | |
87 | 92 | std::string ImportError::toString() const { |
88 | | // FIXME: Improve error texts. |
89 | 92 | switch (Error) { |
90 | 92 | case NameConflict: |
91 | 92 | return "NameConflict"; |
92 | 0 | case UnsupportedConstruct: |
93 | 0 | return "UnsupportedConstruct"; |
94 | 0 | case Unknown: |
95 | 0 | return "Unknown error"; |
96 | 92 | } |
97 | 0 | llvm_unreachable("Invalid error code."); |
98 | 0 | return "Invalid error code."; |
99 | 92 | } |
100 | | |
101 | 0 | void ImportError::log(raw_ostream &OS) const { |
102 | 0 | OS << toString(); |
103 | 0 | } |
104 | | |
105 | 0 | std::error_code ImportError::convertToErrorCode() const { |
106 | 0 | llvm_unreachable("Function not implemented."); |
107 | 0 | } |
108 | | |
109 | | char ImportError::ID; |
110 | | |
111 | | template <class T> |
112 | | SmallVector<Decl *, 2> |
113 | 1.40M | getCanonicalForwardRedeclChain(Redeclarable<T>* D) { |
114 | 1.40M | SmallVector<Decl *, 2> Redecls; |
115 | 1.66M | for (auto *R : D->getFirstDecl()->redecls()) { |
116 | 1.66M | if (R != D->getFirstDecl()) |
117 | 263k | Redecls.push_back(R); |
118 | 1.66M | } |
119 | 1.40M | Redecls.push_back(D->getFirstDecl()); |
120 | 1.40M | std::reverse(Redecls.begin(), Redecls.end()); |
121 | 1.40M | return Redecls; |
122 | 1.40M | } llvm::SmallVector<clang::Decl*, 2u> clang::getCanonicalForwardRedeclChain<clang::FunctionDecl>(clang::Redeclarable<clang::FunctionDecl>*) Line | Count | Source | 113 | 1.08M | getCanonicalForwardRedeclChain(Redeclarable<T>* D) { | 114 | 1.08M | SmallVector<Decl *, 2> Redecls; | 115 | 1.31M | for (auto *R : D->getFirstDecl()->redecls()) { | 116 | 1.31M | if (R != D->getFirstDecl()) | 117 | 226k | Redecls.push_back(R); | 118 | 1.31M | } | 119 | 1.08M | Redecls.push_back(D->getFirstDecl()); | 120 | 1.08M | std::reverse(Redecls.begin(), Redecls.end()); | 121 | 1.08M | return Redecls; | 122 | 1.08M | } |
llvm::SmallVector<clang::Decl*, 2u> clang::getCanonicalForwardRedeclChain<clang::VarDecl>(clang::Redeclarable<clang::VarDecl>*) Line | Count | Source | 113 | 254k | getCanonicalForwardRedeclChain(Redeclarable<T>* D) { | 114 | 254k | SmallVector<Decl *, 2> Redecls; | 115 | 267k | for (auto *R : D->getFirstDecl()->redecls()) { | 116 | 267k | if (R != D->getFirstDecl()) | 117 | 12.9k | Redecls.push_back(R); | 118 | 267k | } | 119 | 254k | Redecls.push_back(D->getFirstDecl()); | 120 | 254k | std::reverse(Redecls.begin(), Redecls.end()); | 121 | 254k | return Redecls; | 122 | 254k | } |
llvm::SmallVector<clang::Decl*, 2u> clang::getCanonicalForwardRedeclChain<clang::TagDecl>(clang::Redeclarable<clang::TagDecl>*) Line | Count | Source | 113 | 64.5k | getCanonicalForwardRedeclChain(Redeclarable<T>* D) { | 114 | 64.5k | SmallVector<Decl *, 2> Redecls; | 115 | 88.3k | for (auto *R : D->getFirstDecl()->redecls()) { | 116 | 88.3k | if (R != D->getFirstDecl()) | 117 | 23.7k | Redecls.push_back(R); | 118 | 88.3k | } | 119 | 64.5k | Redecls.push_back(D->getFirstDecl()); | 120 | 64.5k | std::reverse(Redecls.begin(), Redecls.end()); | 121 | 64.5k | return Redecls; | 122 | 64.5k | } |
|
123 | | |
124 | 1.40M | SmallVector<Decl*, 2> getCanonicalForwardRedeclChain(Decl* D) { |
125 | 1.40M | if (auto *FD = dyn_cast<FunctionDecl>(D)) |
126 | 1.08M | return getCanonicalForwardRedeclChain<FunctionDecl>(FD); |
127 | 319k | if (auto *VD = dyn_cast<VarDecl>(D)) |
128 | 254k | return getCanonicalForwardRedeclChain<VarDecl>(VD); |
129 | 64.5k | if (auto *TD = dyn_cast<TagDecl>(D)) |
130 | 64.5k | return getCanonicalForwardRedeclChain<TagDecl>(TD); |
131 | 0 | llvm_unreachable("Bad declaration kind"); |
132 | 0 | } |
133 | | |
134 | 22.3M | void updateFlags(const Decl *From, Decl *To) { |
135 | | // Check if some flags or attrs are new in 'From' and copy into 'To'. |
136 | | // FIXME: Other flags or attrs? |
137 | 22.3M | if (From->isUsed(false) && !To->isUsed(false)629k ) |
138 | 483 | To->setIsUsed(); |
139 | 22.3M | } |
140 | | |
141 | | /// How to handle import errors that occur when import of a child declaration |
142 | | /// of a DeclContext fails. |
143 | | class ChildErrorHandlingStrategy { |
144 | | /// This context is imported (in the 'from' domain). |
145 | | /// It is nullptr if a non-DeclContext is imported. |
146 | | const DeclContext *const FromDC; |
147 | | /// Ignore import errors of the children. |
148 | | /// If true, the context can be imported successfully if a child |
149 | | /// of it failed to import. Otherwise the import errors of the child nodes |
150 | | /// are accumulated (joined) into the import error object of the parent. |
151 | | /// (Import of a parent can fail in other ways.) |
152 | | bool const IgnoreChildErrors; |
153 | | |
154 | | public: |
155 | | ChildErrorHandlingStrategy(const DeclContext *FromDC) |
156 | 111k | : FromDC(FromDC), IgnoreChildErrors(!isa<TagDecl>(FromDC)) {} |
157 | | ChildErrorHandlingStrategy(const Decl *FromD) |
158 | | : FromDC(dyn_cast<DeclContext>(FromD)), |
159 | 260 | IgnoreChildErrors(!isa<TagDecl>(FromD)) {} |
160 | | |
161 | | /// Process the import result of a child (of the current declaration). |
162 | | /// \param ResultErr The import error that can be used as result of |
163 | | /// importing the parent. This may be changed by the function. |
164 | | /// \param ChildErr Result of importing a child. Can be success or error. |
165 | 395 | void handleChildImportResult(Error &ResultErr, Error &&ChildErr) { |
166 | 395 | if (ChildErr && !IgnoreChildErrors383 ) |
167 | 36 | ResultErr = joinErrors(std::move(ResultErr), std::move(ChildErr)); |
168 | 359 | else |
169 | 359 | consumeError(std::move(ChildErr)); |
170 | 395 | } |
171 | | |
172 | | /// Determine if import failure of a child does not cause import failure of |
173 | | /// its parent. |
174 | 260 | bool ignoreChildErrorOnParent(Decl *FromChildD) const { |
175 | 260 | if (!IgnoreChildErrors || !FromDC180 ) |
176 | 156 | return false; |
177 | 104 | return FromDC->containsDecl(FromChildD); |
178 | 260 | } |
179 | | }; |
180 | | |
181 | | class ASTNodeImporter : public TypeVisitor<ASTNodeImporter, ExpectedType>, |
182 | | public DeclVisitor<ASTNodeImporter, ExpectedDecl>, |
183 | | public StmtVisitor<ASTNodeImporter, ExpectedStmt> { |
184 | | ASTImporter &Importer; |
185 | | |
186 | | // Use this instead of Importer.importInto . |
187 | | template <typename ImportT> |
188 | 5.25M | LLVM_NODISCARD Error importInto(ImportT &To, const ImportT &From) { |
189 | 5.25M | return Importer.importInto(To, From); |
190 | 5.25M | } llvm::Error clang::ASTNodeImporter::importInto<clang::SourceLocation>(clang::SourceLocation&, clang::SourceLocation const&) Line | Count | Source | 188 | 2.62M | LLVM_NODISCARD Error importInto(ImportT &To, const ImportT &From) { | 189 | 2.62M | return Importer.importInto(To, From); | 190 | 2.62M | } |
llvm::Error clang::ASTNodeImporter::importInto<clang::DeclarationName>(clang::DeclarationName&, clang::DeclarationName const&) Line | Count | Source | 188 | 2.62M | LLVM_NODISCARD Error importInto(ImportT &To, const ImportT &From) { | 189 | 2.62M | return Importer.importInto(To, From); | 190 | 2.62M | } |
llvm::Error clang::ASTNodeImporter::importInto<clang::QualType>(clang::QualType&, clang::QualType const&) Line | Count | Source | 188 | 991 | LLVM_NODISCARD Error importInto(ImportT &To, const ImportT &From) { | 189 | 991 | return Importer.importInto(To, From); | 190 | 991 | } |
|
191 | | |
192 | | // Use this to import pointers of specific type. |
193 | | template <typename ImportT> |
194 | 800k | LLVM_NODISCARD Error importInto(ImportT *&To, ImportT *From) { |
195 | 800k | auto ToOrErr = Importer.Import(From); |
196 | 800k | if (ToOrErr) |
197 | 800k | To = cast_or_null<ImportT>(*ToOrErr); |
198 | 800k | return ToOrErr.takeError(); |
199 | 800k | } llvm::Error clang::ASTNodeImporter::importInto<clang::FunctionTemplateDecl>(clang::FunctionTemplateDecl*&, clang::FunctionTemplateDecl*) Line | Count | Source | 194 | 32.1k | LLVM_NODISCARD Error importInto(ImportT *&To, ImportT *From) { | 195 | 32.1k | auto ToOrErr = Importer.Import(From); | 196 | 32.1k | if (ToOrErr) | 197 | 32.1k | To = cast_or_null<ImportT>(*ToOrErr); | 198 | 32.1k | return ToOrErr.takeError(); | 199 | 32.1k | } |
llvm::Error clang::ASTNodeImporter::importInto<clang::Decl>(clang::Decl*&, clang::Decl*) Line | Count | Source | 194 | 36.6k | LLVM_NODISCARD Error importInto(ImportT *&To, ImportT *From) { | 195 | 36.6k | auto ToOrErr = Importer.Import(From); | 196 | 36.6k | if (ToOrErr) | 197 | 36.6k | To = cast_or_null<ImportT>(*ToOrErr); | 198 | 36.6k | return ToOrErr.takeError(); | 199 | 36.6k | } |
llvm::Error clang::ASTNodeImporter::importInto<clang::ClassTemplateDecl>(clang::ClassTemplateDecl*&, clang::ClassTemplateDecl*) Line | Count | Source | 194 | 199k | LLVM_NODISCARD Error importInto(ImportT *&To, ImportT *From) { | 195 | 199k | auto ToOrErr = Importer.Import(From); | 196 | 199k | if (ToOrErr) | 197 | 199k | To = cast_or_null<ImportT>(*ToOrErr); | 198 | 199k | return ToOrErr.takeError(); | 199 | 199k | } |
llvm::Error clang::ASTNodeImporter::importInto<clang::NamedDecl>(clang::NamedDecl*&, clang::NamedDecl*) Line | Count | Source | 194 | 33.6k | LLVM_NODISCARD Error importInto(ImportT *&To, ImportT *From) { | 195 | 33.6k | auto ToOrErr = Importer.Import(From); | 196 | 33.6k | if (ToOrErr) | 197 | 33.6k | To = cast_or_null<ImportT>(*ToOrErr); | 198 | 33.6k | return ToOrErr.takeError(); | 199 | 33.6k | } |
llvm::Error clang::ASTNodeImporter::importInto<clang::ObjCInterfaceDecl>(clang::ObjCInterfaceDecl*&, clang::ObjCInterfaceDecl*) Line | Count | Source | 194 | 2.47k | LLVM_NODISCARD Error importInto(ImportT *&To, ImportT *From) { | 195 | 2.47k | auto ToOrErr = Importer.Import(From); | 196 | 2.47k | if (ToOrErr) | 197 | 2.47k | To = cast_or_null<ImportT>(*ToOrErr); | 198 | 2.47k | return ToOrErr.takeError(); | 199 | 2.47k | } |
llvm::Error clang::ASTNodeImporter::importInto<clang::ObjCCategoryDecl>(clang::ObjCCategoryDecl*&, clang::ObjCCategoryDecl*) Line | Count | Source | 194 | 6 | LLVM_NODISCARD Error importInto(ImportT *&To, ImportT *From) { | 195 | 6 | auto ToOrErr = Importer.Import(From); | 196 | 6 | if (ToOrErr) | 197 | 6 | To = cast_or_null<ImportT>(*ToOrErr); | 198 | 6 | return ToOrErr.takeError(); | 199 | 6 | } |
llvm::Error clang::ASTNodeImporter::importInto<clang::ObjCPropertyDecl>(clang::ObjCPropertyDecl*&, clang::ObjCPropertyDecl*) Line | Count | Source | 194 | 8 | LLVM_NODISCARD Error importInto(ImportT *&To, ImportT *From) { | 195 | 8 | auto ToOrErr = Importer.Import(From); | 196 | 8 | if (ToOrErr) | 197 | 8 | To = cast_or_null<ImportT>(*ToOrErr); | 198 | 8 | return ToOrErr.takeError(); | 199 | 8 | } |
llvm::Error clang::ASTNodeImporter::importInto<clang::ObjCIvarDecl>(clang::ObjCIvarDecl*&, clang::ObjCIvarDecl*) Line | Count | Source | 194 | 8 | LLVM_NODISCARD Error importInto(ImportT *&To, ImportT *From) { | 195 | 8 | auto ToOrErr = Importer.Import(From); | 196 | 8 | if (ToOrErr) | 197 | 8 | To = cast_or_null<ImportT>(*ToOrErr); | 198 | 8 | return ToOrErr.takeError(); | 199 | 8 | } |
llvm::Error clang::ASTNodeImporter::importInto<clang::CXXRecordDecl>(clang::CXXRecordDecl*&, clang::CXXRecordDecl*) Line | Count | Source | 194 | 148k | LLVM_NODISCARD Error importInto(ImportT *&To, ImportT *From) { | 195 | 148k | auto ToOrErr = Importer.Import(From); | 196 | 148k | if (ToOrErr) | 197 | 148k | To = cast_or_null<ImportT>(*ToOrErr); | 198 | 148k | return ToOrErr.takeError(); | 199 | 148k | } |
llvm::Error clang::ASTNodeImporter::importInto<clang::VarDecl>(clang::VarDecl*&, clang::VarDecl*) Line | Count | Source | 194 | 414 | LLVM_NODISCARD Error importInto(ImportT *&To, ImportT *From) { | 195 | 414 | auto ToOrErr = Importer.Import(From); | 196 | 414 | if (ToOrErr) | 197 | 414 | To = cast_or_null<ImportT>(*ToOrErr); | 198 | 414 | return ToOrErr.takeError(); | 199 | 414 | } |
llvm::Error clang::ASTNodeImporter::importInto<clang::VarTemplateDecl>(clang::VarTemplateDecl*&, clang::VarTemplateDecl*) Line | Count | Source | 194 | 26 | LLVM_NODISCARD Error importInto(ImportT *&To, ImportT *From) { | 195 | 26 | auto ToOrErr = Importer.Import(From); | 196 | 26 | if (ToOrErr) | 197 | 26 | To = cast_or_null<ImportT>(*ToOrErr); | 198 | 26 | return ToOrErr.takeError(); | 199 | 26 | } |
llvm::Error clang::ASTNodeImporter::importInto<clang::FunctionDecl>(clang::FunctionDecl*&, clang::FunctionDecl*) Line | Count | Source | 194 | 345k | LLVM_NODISCARD Error importInto(ImportT *&To, ImportT *From) { | 195 | 345k | auto ToOrErr = Importer.Import(From); | 196 | 345k | if (ToOrErr) | 197 | 345k | To = cast_or_null<ImportT>(*ToOrErr); | 198 | 345k | return ToOrErr.takeError(); | 199 | 345k | } |
|
200 | | |
201 | | // Call the import function of ASTImporter for a baseclass of type `T` and |
202 | | // cast the return value to `T`. |
203 | | template <typename T> |
204 | | auto import(T *From) |
205 | | -> std::conditional_t<std::is_base_of<Type, T>::value, |
206 | 34.4M | Expected<const T *>, Expected<T *>> { |
207 | 34.4M | auto ToOrErr = Importer.Import(From); |
208 | 34.4M | if (!ToOrErr) |
209 | 537 | return ToOrErr.takeError(); |
210 | 34.4M | return cast_or_null<T>(*ToOrErr); |
211 | 34.4M | } std::__1::conditional<std::is_base_of<clang::Type, clang::Type>::value, llvm::Expected<clang::Type const*>, llvm::Expected<clang::Type*> >::type clang::ASTNodeImporter::import<clang::Type>(clang::Type*) Line | Count | Source | 206 | 2 | Expected<const T *>, Expected<T *>> { | 207 | 2 | auto ToOrErr = Importer.Import(From); | 208 | 2 | if (!ToOrErr) | 209 | 0 | return ToOrErr.takeError(); | 210 | 2 | return cast_or_null<T>(*ToOrErr); | 211 | 2 | } |
std::__1::conditional<std::is_base_of<clang::Type, clang::TemplateTypeParmType>::value, llvm::Expected<clang::TemplateTypeParmType const*>, llvm::Expected<clang::TemplateTypeParmType*> >::type clang::ASTNodeImporter::import<clang::TemplateTypeParmType>(clang::TemplateTypeParmType*) Line | Count | Source | 206 | 97.2k | Expected<const T *>, Expected<T *>> { | 207 | 97.2k | auto ToOrErr = Importer.Import(From); | 208 | 97.2k | if (!ToOrErr) | 209 | 0 | return ToOrErr.takeError(); | 210 | 97.2k | return cast_or_null<T>(*ToOrErr); | 211 | 97.2k | } |
std::__1::conditional<std::is_base_of<clang::Type, clang::CXXDestructorDecl>::value, llvm::Expected<clang::CXXDestructorDecl const*>, llvm::Expected<clang::CXXDestructorDecl*> >::type clang::ASTNodeImporter::import<clang::CXXDestructorDecl>(clang::CXXDestructorDecl*) Line | Count | Source | 206 | 1.81k | Expected<const T *>, Expected<T *>> { | 207 | 1.81k | auto ToOrErr = Importer.Import(From); | 208 | 1.81k | if (!ToOrErr) | 209 | 0 | return ToOrErr.takeError(); | 210 | 1.81k | return cast_or_null<T>(*ToOrErr); | 211 | 1.81k | } |
std::__1::conditional<std::is_base_of<clang::Type, clang::Expr>::value, llvm::Expected<clang::Expr const*>, llvm::Expected<clang::Expr*> >::type clang::ASTNodeImporter::import<clang::Expr>(clang::Expr*) Line | Count | Source | 206 | 9.67M | Expected<const T *>, Expected<T *>> { | 207 | 9.67M | auto ToOrErr = Importer.Import(From); | 208 | 9.67M | if (!ToOrErr) | 209 | 16 | return ToOrErr.takeError(); | 210 | 9.67M | return cast_or_null<T>(*ToOrErr); | 211 | 9.67M | } |
std::__1::conditional<std::is_base_of<clang::Type, clang::ValueDecl>::value, llvm::Expected<clang::ValueDecl const*>, llvm::Expected<clang::ValueDecl*> >::type clang::ASTNodeImporter::import<clang::ValueDecl>(clang::ValueDecl*) Line | Count | Source | 206 | 2.20M | Expected<const T *>, Expected<T *>> { | 207 | 2.20M | auto ToOrErr = Importer.Import(From); | 208 | 2.20M | if (!ToOrErr) | 209 | 0 | return ToOrErr.takeError(); | 210 | 2.20M | return cast_or_null<T>(*ToOrErr); | 211 | 2.20M | } |
std::__1::conditional<std::is_base_of<clang::Type, clang::TypeSourceInfo>::value, llvm::Expected<clang::TypeSourceInfo const*>, llvm::Expected<clang::TypeSourceInfo*> >::type clang::ASTNodeImporter::import<clang::TypeSourceInfo>(clang::TypeSourceInfo*) Line | Count | Source | 206 | 3.65M | Expected<const T *>, Expected<T *>> { | 207 | 3.65M | auto ToOrErr = Importer.Import(From); | 208 | 3.65M | if (!ToOrErr) | 209 | 0 | return ToOrErr.takeError(); | 210 | 3.65M | return cast_or_null<T>(*ToOrErr); | 211 | 3.65M | } |
std::__1::conditional<std::is_base_of<clang::Type, clang::Decl>::value, llvm::Expected<clang::Decl const*>, llvm::Expected<clang::Decl*> >::type clang::ASTNodeImporter::import<clang::Decl>(clang::Decl*) Line | Count | Source | 206 | 2.11M | Expected<const T *>, Expected<T *>> { | 207 | 2.11M | auto ToOrErr = Importer.Import(From); | 208 | 2.11M | if (!ToOrErr) | 209 | 395 | return ToOrErr.takeError(); | 210 | 2.11M | return cast_or_null<T>(*ToOrErr); | 211 | 2.11M | } |
std::__1::conditional<std::is_base_of<clang::Type, clang::VarDecl>::value, llvm::Expected<clang::VarDecl const*>, llvm::Expected<clang::VarDecl*> >::type clang::ASTNodeImporter::import<clang::VarDecl>(clang::VarDecl*) Line | Count | Source | 206 | 453k | Expected<const T *>, Expected<T *>> { | 207 | 453k | auto ToOrErr = Importer.Import(From); | 208 | 453k | if (!ToOrErr) | 209 | 0 | return ToOrErr.takeError(); | 210 | 453k | return cast_or_null<T>(*ToOrErr); | 211 | 453k | } |
std::__1::conditional<std::is_base_of<clang::Type, clang::UnresolvedUsingTypenameDecl>::value, llvm::Expected<clang::UnresolvedUsingTypenameDecl const*>, llvm::Expected<clang::UnresolvedUsingTypenameDecl*> >::type clang::ASTNodeImporter::import<clang::UnresolvedUsingTypenameDecl>(clang::UnresolvedUsingTypenameDecl*) Line | Count | Source | 206 | 268 | Expected<const T *>, Expected<T *>> { | 207 | 268 | auto ToOrErr = Importer.Import(From); | 208 | 268 | if (!ToOrErr) | 209 | 0 | return ToOrErr.takeError(); | 210 | 268 | return cast_or_null<T>(*ToOrErr); | 211 | 268 | } |
std::__1::conditional<std::is_base_of<clang::Type, clang::TypedefNameDecl>::value, llvm::Expected<clang::TypedefNameDecl const*>, llvm::Expected<clang::TypedefNameDecl*> >::type clang::ASTNodeImporter::import<clang::TypedefNameDecl>(clang::TypedefNameDecl*) Line | Count | Source | 206 | 249k | Expected<const T *>, Expected<T *>> { | 207 | 249k | auto ToOrErr = Importer.Import(From); | 208 | 249k | if (!ToOrErr) | 209 | 4 | return ToOrErr.takeError(); | 210 | 249k | return cast_or_null<T>(*ToOrErr); | 211 | 249k | } |
std::__1::conditional<std::is_base_of<clang::Type, clang::UsingShadowDecl>::value, llvm::Expected<clang::UsingShadowDecl const*>, llvm::Expected<clang::UsingShadowDecl*> >::type clang::ASTNodeImporter::import<clang::UsingShadowDecl>(clang::UsingShadowDecl*) Line | Count | Source | 206 | 42.9k | Expected<const T *>, Expected<T *>> { | 207 | 42.9k | auto ToOrErr = Importer.Import(From); | 208 | 42.9k | if (!ToOrErr) | 209 | 0 | return ToOrErr.takeError(); | 210 | 42.9k | return cast_or_null<T>(*ToOrErr); | 211 | 42.9k | } |
std::__1::conditional<std::is_base_of<clang::Type, clang::ConceptDecl>::value, llvm::Expected<clang::ConceptDecl const*>, llvm::Expected<clang::ConceptDecl*> >::type clang::ASTNodeImporter::import<clang::ConceptDecl>(clang::ConceptDecl*) Line | Count | Source | 206 | 986 | Expected<const T *>, Expected<T *>> { | 207 | 986 | auto ToOrErr = Importer.Import(From); | 208 | 986 | if (!ToOrErr) | 209 | 0 | return ToOrErr.takeError(); | 210 | 986 | return cast_or_null<T>(*ToOrErr); | 211 | 986 | } |
std::__1::conditional<std::is_base_of<clang::Type, clang::CXXRecordDecl>::value, llvm::Expected<clang::CXXRecordDecl const*>, llvm::Expected<clang::CXXRecordDecl*> >::type clang::ASTNodeImporter::import<clang::CXXRecordDecl>(clang::CXXRecordDecl*) Line | Count | Source | 206 | 532k | Expected<const T *>, Expected<T *>> { | 207 | 532k | auto ToOrErr = Importer.Import(From); | 208 | 532k | if (!ToOrErr) | 209 | 0 | return ToOrErr.takeError(); | 210 | 532k | return cast_or_null<T>(*ToOrErr); | 211 | 532k | } |
std::__1::conditional<std::is_base_of<clang::Type, clang::RecordDecl>::value, llvm::Expected<clang::RecordDecl const*>, llvm::Expected<clang::RecordDecl*> >::type clang::ASTNodeImporter::import<clang::RecordDecl>(clang::RecordDecl*) Line | Count | Source | 206 | 122k | Expected<const T *>, Expected<T *>> { | 207 | 122k | auto ToOrErr = Importer.Import(From); | 208 | 122k | if (!ToOrErr) | 209 | 27 | return ToOrErr.takeError(); | 210 | 122k | return cast_or_null<T>(*ToOrErr); | 211 | 122k | } |
std::__1::conditional<std::is_base_of<clang::Type, clang::EnumDecl>::value, llvm::Expected<clang::EnumDecl const*>, llvm::Expected<clang::EnumDecl*> >::type clang::ASTNodeImporter::import<clang::EnumDecl>(clang::EnumDecl*) Line | Count | Source | 206 | 5.40k | Expected<const T *>, Expected<T *>> { | 207 | 5.40k | auto ToOrErr = Importer.Import(From); | 208 | 5.40k | if (!ToOrErr) | 209 | 0 | return ToOrErr.takeError(); | 210 | 5.40k | return cast_or_null<T>(*ToOrErr); | 211 | 5.40k | } |
std::__1::conditional<std::is_base_of<clang::Type, clang::TemplateTypeParmDecl>::value, llvm::Expected<clang::TemplateTypeParmDecl const*>, llvm::Expected<clang::TemplateTypeParmDecl*> >::type clang::ASTNodeImporter::import<clang::TemplateTypeParmDecl>(clang::TemplateTypeParmDecl*) Line | Count | Source | 206 | 528k | Expected<const T *>, Expected<T *>> { | 207 | 528k | auto ToOrErr = Importer.Import(From); | 208 | 528k | if (!ToOrErr) | 209 | 0 | return ToOrErr.takeError(); | 210 | 528k | return cast_or_null<T>(*ToOrErr); | 211 | 528k | } |
std::__1::conditional<std::is_base_of<clang::Type, clang::NestedNameSpecifier>::value, llvm::Expected<clang::NestedNameSpecifier const*>, llvm::Expected<clang::NestedNameSpecifier*> >::type clang::ASTNodeImporter::import<clang::NestedNameSpecifier>(clang::NestedNameSpecifier*) Line | Count | Source | 206 | 281k | Expected<const T *>, Expected<T *>> { | 207 | 281k | auto ToOrErr = Importer.Import(From); | 208 | 281k | if (!ToOrErr) | 209 | 0 | return ToOrErr.takeError(); | 210 | 281k | return cast_or_null<T>(*ToOrErr); | 211 | 281k | } |
std::__1::conditional<std::is_base_of<clang::Type, clang::TagDecl>::value, llvm::Expected<clang::TagDecl const*>, llvm::Expected<clang::TagDecl*> >::type clang::ASTNodeImporter::import<clang::TagDecl>(clang::TagDecl*) Line | Count | Source | 206 | 81.8k | Expected<const T *>, Expected<T *>> { | 207 | 81.8k | auto ToOrErr = Importer.Import(From); | 208 | 81.8k | if (!ToOrErr) | 209 | 0 | return ToOrErr.takeError(); | 210 | 81.8k | return cast_or_null<T>(*ToOrErr); | 211 | 81.8k | } |
std::__1::conditional<std::is_base_of<clang::Type, clang::ObjCInterfaceDecl>::value, llvm::Expected<clang::ObjCInterfaceDecl const*>, llvm::Expected<clang::ObjCInterfaceDecl*> >::type clang::ASTNodeImporter::import<clang::ObjCInterfaceDecl>(clang::ObjCInterfaceDecl*) Line | Count | Source | 206 | 2.99k | Expected<const T *>, Expected<T *>> { | 207 | 2.99k | auto ToOrErr = Importer.Import(From); | 208 | 2.99k | if (!ToOrErr) | 209 | 0 | return ToOrErr.takeError(); | 210 | 2.99k | return cast_or_null<T>(*ToOrErr); | 211 | 2.99k | } |
std::__1::conditional<std::is_base_of<clang::Type, clang::ObjCProtocolDecl>::value, llvm::Expected<clang::ObjCProtocolDecl const*>, llvm::Expected<clang::ObjCProtocolDecl*> >::type clang::ASTNodeImporter::import<clang::ObjCProtocolDecl>(clang::ObjCProtocolDecl*) Line | Count | Source | 206 | 823 | Expected<const T *>, Expected<T *>> { | 207 | 823 | auto ToOrErr = Importer.Import(From); | 208 | 823 | if (!ToOrErr) | 209 | 0 | return ToOrErr.takeError(); | 210 | 823 | return cast_or_null<T>(*ToOrErr); | 211 | 823 | } |
std::__1::conditional<std::is_base_of<clang::Type, clang::CXXMethodDecl>::value, llvm::Expected<clang::CXXMethodDecl const*>, llvm::Expected<clang::CXXMethodDecl*> >::type clang::ASTNodeImporter::import<clang::CXXMethodDecl>(clang::CXXMethodDecl*) Line | Count | Source | 206 | 30.7k | Expected<const T *>, Expected<T *>> { | 207 | 30.7k | auto ToOrErr = Importer.Import(From); | 208 | 30.7k | if (!ToOrErr) | 209 | 4 | return ToOrErr.takeError(); | 210 | 30.7k | return cast_or_null<T>(*ToOrErr); | 211 | 30.7k | } |
std::__1::conditional<std::is_base_of<clang::Type, clang::NamespaceDecl>::value, llvm::Expected<clang::NamespaceDecl const*>, llvm::Expected<clang::NamespaceDecl*> >::type clang::ASTNodeImporter::import<clang::NamespaceDecl>(clang::NamespaceDecl*) Line | Count | Source | 206 | 272 | Expected<const T *>, Expected<T *>> { | 207 | 272 | auto ToOrErr = Importer.Import(From); | 208 | 272 | if (!ToOrErr) | 209 | 0 | return ToOrErr.takeError(); | 210 | 272 | return cast_or_null<T>(*ToOrErr); | 211 | 272 | } |
std::__1::conditional<std::is_base_of<clang::Type, clang::TypeAliasDecl>::value, llvm::Expected<clang::TypeAliasDecl const*>, llvm::Expected<clang::TypeAliasDecl*> >::type clang::ASTNodeImporter::import<clang::TypeAliasDecl>(clang::TypeAliasDecl*) Line | Count | Source | 206 | 8.58k | Expected<const T *>, Expected<T *>> { | 207 | 8.58k | auto ToOrErr = Importer.Import(From); | 208 | 8.58k | if (!ToOrErr) | 209 | 0 | return ToOrErr.takeError(); | 210 | 8.58k | return cast_or_null<T>(*ToOrErr); | 211 | 8.58k | } |
std::__1::conditional<std::is_base_of<clang::Type, clang::LabelStmt>::value, llvm::Expected<clang::LabelStmt const*>, llvm::Expected<clang::LabelStmt*> >::type clang::ASTNodeImporter::import<clang::LabelStmt>(clang::LabelStmt*) Line | Count | Source | 206 | 258 | Expected<const T *>, Expected<T *>> { | 207 | 258 | auto ToOrErr = Importer.Import(From); | 208 | 258 | if (!ToOrErr) | 209 | 0 | return ToOrErr.takeError(); | 210 | 258 | return cast_or_null<T>(*ToOrErr); | 211 | 258 | } |
std::__1::conditional<std::is_base_of<clang::Type, clang::FunctionDecl>::value, llvm::Expected<clang::FunctionDecl const*>, llvm::Expected<clang::FunctionDecl*> >::type clang::ASTNodeImporter::import<clang::FunctionDecl>(clang::FunctionDecl*) Line | Count | Source | 206 | 1.70M | Expected<const T *>, Expected<T *>> { | 207 | 1.70M | auto ToOrErr = Importer.Import(From); | 208 | 1.70M | if (!ToOrErr) | 209 | 0 | return ToOrErr.takeError(); | 210 | 1.70M | return cast_or_null<T>(*ToOrErr); | 211 | 1.70M | } |
std::__1::conditional<std::is_base_of<clang::Type, clang::FunctionTemplateDecl>::value, llvm::Expected<clang::FunctionTemplateDecl const*>, llvm::Expected<clang::FunctionTemplateDecl*> >::type clang::ASTNodeImporter::import<clang::FunctionTemplateDecl>(clang::FunctionTemplateDecl*) Line | Count | Source | 206 | 190k | Expected<const T *>, Expected<T *>> { | 207 | 190k | auto ToOrErr = Importer.Import(From); | 208 | 190k | if (!ToOrErr) | 209 | 0 | return ToOrErr.takeError(); | 210 | 190k | return cast_or_null<T>(*ToOrErr); | 211 | 190k | } |
std::__1::conditional<std::is_base_of<clang::Type, clang::Stmt>::value, llvm::Expected<clang::Stmt const*>, llvm::Expected<clang::Stmt*> >::type clang::ASTNodeImporter::import<clang::Stmt>(clang::Stmt*) Line | Count | Source | 206 | 1.89M | Expected<const T *>, Expected<T *>> { | 207 | 1.89M | auto ToOrErr = Importer.Import(From); | 208 | 1.89M | if (!ToOrErr) | 209 | 56 | return ToOrErr.takeError(); | 210 | 1.89M | return cast_or_null<T>(*ToOrErr); | 211 | 1.89M | } |
std::__1::conditional<std::is_base_of<clang::Type, clang::ParmVarDecl>::value, llvm::Expected<clang::ParmVarDecl const*>, llvm::Expected<clang::ParmVarDecl*> >::type clang::ASTNodeImporter::import<clang::ParmVarDecl>(clang::ParmVarDecl*) Line | Count | Source | 206 | 1.22M | Expected<const T *>, Expected<T *>> { | 207 | 1.22M | auto ToOrErr = Importer.Import(From); | 208 | 1.22M | if (!ToOrErr) | 209 | 35 | return ToOrErr.takeError(); | 210 | 1.22M | return cast_or_null<T>(*ToOrErr); | 211 | 1.22M | } |
std::__1::conditional<std::is_base_of<clang::Type, clang::CXXConstructorDecl>::value, llvm::Expected<clang::CXXConstructorDecl const*>, llvm::Expected<clang::CXXConstructorDecl*> >::type clang::ASTNodeImporter::import<clang::CXXConstructorDecl>(clang::CXXConstructorDecl*) Line | Count | Source | 206 | 27.2k | Expected<const T *>, Expected<T *>> { | 207 | 27.2k | auto ToOrErr = Importer.Import(From); | 208 | 27.2k | if (!ToOrErr) | 209 | 0 | return ToOrErr.takeError(); | 210 | 27.2k | return cast_or_null<T>(*ToOrErr); | 211 | 27.2k | } |
std::__1::conditional<std::is_base_of<clang::Type, clang::CXXCtorInitializer>::value, llvm::Expected<clang::CXXCtorInitializer const*>, llvm::Expected<clang::CXXCtorInitializer*> >::type clang::ASTNodeImporter::import<clang::CXXCtorInitializer>(clang::CXXCtorInitializer*) Line | Count | Source | 206 | 80.8k | Expected<const T *>, Expected<T *>> { | 207 | 80.8k | auto ToOrErr = Importer.Import(From); | 208 | 80.8k | if (!ToOrErr) | 209 | 0 | return ToOrErr.takeError(); | 210 | 80.8k | return cast_or_null<T>(*ToOrErr); | 211 | 80.8k | } |
std::__1::conditional<std::is_base_of<clang::Type, clang::NamedDecl>::value, llvm::Expected<clang::NamedDecl const*>, llvm::Expected<clang::NamedDecl*> >::type clang::ASTNodeImporter::import<clang::NamedDecl>(clang::NamedDecl*) Line | Count | Source | 206 | 9.09M | Expected<const T *>, Expected<T *>> { | 207 | 9.09M | auto ToOrErr = Importer.Import(From); | 208 | 9.09M | if (!ToOrErr) | 209 | 0 | return ToOrErr.takeError(); | 210 | 9.09M | return cast_or_null<T>(*ToOrErr); | 211 | 9.09M | } |
std::__1::conditional<std::is_base_of<clang::Type, clang::BindingDecl>::value, llvm::Expected<clang::BindingDecl const*>, llvm::Expected<clang::BindingDecl*> >::type clang::ASTNodeImporter::import<clang::BindingDecl>(clang::BindingDecl*) Line | Count | Source | 206 | 96 | Expected<const T *>, Expected<T *>> { | 207 | 96 | auto ToOrErr = Importer.Import(From); | 208 | 96 | if (!ToOrErr) | 209 | 0 | return ToOrErr.takeError(); | 210 | 96 | return cast_or_null<T>(*ToOrErr); | 211 | 96 | } |
std::__1::conditional<std::is_base_of<clang::Type, clang::VarTemplateDecl>::value, llvm::Expected<clang::VarTemplateDecl const*>, llvm::Expected<clang::VarTemplateDecl*> >::type clang::ASTNodeImporter::import<clang::VarTemplateDecl>(clang::VarTemplateDecl*) Line | Count | Source | 206 | 219 | Expected<const T *>, Expected<T *>> { | 207 | 219 | auto ToOrErr = Importer.Import(From); | 208 | 219 | if (!ToOrErr) | 209 | 0 | return ToOrErr.takeError(); | 210 | 219 | return cast_or_null<T>(*ToOrErr); | 211 | 219 | } |
std::__1::conditional<std::is_base_of<clang::Type, clang::ConstructorUsingShadowDecl>::value, llvm::Expected<clang::ConstructorUsingShadowDecl const*>, llvm::Expected<clang::ConstructorUsingShadowDecl*> >::type clang::ASTNodeImporter::import<clang::ConstructorUsingShadowDecl>(clang::ConstructorUsingShadowDecl*) Line | Count | Source | 206 | 171 | Expected<const T *>, Expected<T *>> { | 207 | 171 | auto ToOrErr = Importer.Import(From); | 208 | 171 | if (!ToOrErr) | 209 | 0 | return ToOrErr.takeError(); | 210 | 171 | return cast_or_null<T>(*ToOrErr); | 211 | 171 | } |
std::__1::conditional<std::is_base_of<clang::Type, clang::ObjCCategoryImplDecl>::value, llvm::Expected<clang::ObjCCategoryImplDecl const*>, llvm::Expected<clang::ObjCCategoryImplDecl*> >::type clang::ASTNodeImporter::import<clang::ObjCCategoryImplDecl>(clang::ObjCCategoryImplDecl*) Line | Count | Source | 206 | 6 | Expected<const T *>, Expected<T *>> { | 207 | 6 | auto ToOrErr = Importer.Import(From); | 208 | 6 | if (!ToOrErr) | 209 | 0 | return ToOrErr.takeError(); | 210 | 6 | return cast_or_null<T>(*ToOrErr); | 211 | 6 | } |
Unexecuted instantiation: std::__1::conditional<std::is_base_of<clang::Type, clang::UsingEnumDecl>::value, llvm::Expected<clang::UsingEnumDecl const*>, llvm::Expected<clang::UsingEnumDecl*> >::type clang::ASTNodeImporter::import<clang::UsingEnumDecl>(clang::UsingEnumDecl*) std::__1::conditional<std::is_base_of<clang::Type, clang::BaseUsingDecl>::value, llvm::Expected<clang::BaseUsingDecl const*>, llvm::Expected<clang::BaseUsingDecl*> >::type clang::ASTNodeImporter::import<clang::BaseUsingDecl>(clang::BaseUsingDecl*) Line | Count | Source | 206 | 45.7k | Expected<const T *>, Expected<T *>> { | 207 | 45.7k | auto ToOrErr = Importer.Import(From); | 208 | 45.7k | if (!ToOrErr) | 209 | 0 | return ToOrErr.takeError(); | 210 | 45.7k | return cast_or_null<T>(*ToOrErr); | 211 | 45.7k | } |
std::__1::conditional<std::is_base_of<clang::Type, clang::ObjCCategoryDecl>::value, llvm::Expected<clang::ObjCCategoryDecl const*>, llvm::Expected<clang::ObjCCategoryDecl*> >::type clang::ASTNodeImporter::import<clang::ObjCCategoryDecl>(clang::ObjCCategoryDecl*) Line | Count | Source | 206 | 2.42k | Expected<const T *>, Expected<T *>> { | 207 | 2.42k | auto ToOrErr = Importer.Import(From); | 208 | 2.42k | if (!ToOrErr) | 209 | 0 | return ToOrErr.takeError(); | 210 | 2.42k | return cast_or_null<T>(*ToOrErr); | 211 | 2.42k | } |
std::__1::conditional<std::is_base_of<clang::Type, clang::ObjCImplementationDecl>::value, llvm::Expected<clang::ObjCImplementationDecl const*>, llvm::Expected<clang::ObjCImplementationDecl*> >::type clang::ASTNodeImporter::import<clang::ObjCImplementationDecl>(clang::ObjCImplementationDecl*) Line | Count | Source | 206 | 8 | Expected<const T *>, Expected<T *>> { | 207 | 8 | auto ToOrErr = Importer.Import(From); | 208 | 8 | if (!ToOrErr) | 209 | 0 | return ToOrErr.takeError(); | 210 | 8 | return cast_or_null<T>(*ToOrErr); | 211 | 8 | } |
std::__1::conditional<std::is_base_of<clang::Type, clang::ObjCTypeParamDecl>::value, llvm::Expected<clang::ObjCTypeParamDecl const*>, llvm::Expected<clang::ObjCTypeParamDecl*> >::type clang::ASTNodeImporter::import<clang::ObjCTypeParamDecl>(clang::ObjCTypeParamDecl*) Line | Count | Source | 206 | 390 | Expected<const T *>, Expected<T *>> { | 207 | 390 | auto ToOrErr = Importer.Import(From); | 208 | 390 | if (!ToOrErr) | 209 | 0 | return ToOrErr.takeError(); | 210 | 390 | return cast_or_null<T>(*ToOrErr); | 211 | 390 | } |
std::__1::conditional<std::is_base_of<clang::Type, clang::ObjCMethodDecl>::value, llvm::Expected<clang::ObjCMethodDecl const*>, llvm::Expected<clang::ObjCMethodDecl*> >::type clang::ASTNodeImporter::import<clang::ObjCMethodDecl>(clang::ObjCMethodDecl*) Line | Count | Source | 206 | 4.62k | Expected<const T *>, Expected<T *>> { | 207 | 4.62k | auto ToOrErr = Importer.Import(From); | 208 | 4.62k | if (!ToOrErr) | 209 | 0 | return ToOrErr.takeError(); | 210 | 4.62k | return cast_or_null<T>(*ToOrErr); | 211 | 4.62k | } |
std::__1::conditional<std::is_base_of<clang::Type, clang::ObjCIvarDecl>::value, llvm::Expected<clang::ObjCIvarDecl const*>, llvm::Expected<clang::ObjCIvarDecl*> >::type clang::ASTNodeImporter::import<clang::ObjCIvarDecl>(clang::ObjCIvarDecl*) Line | Count | Source | 206 | 2.31k | Expected<const T *>, Expected<T *>> { | 207 | 2.31k | auto ToOrErr = Importer.Import(From); | 208 | 2.31k | if (!ToOrErr) | 209 | 0 | return ToOrErr.takeError(); | 210 | 2.31k | return cast_or_null<T>(*ToOrErr); | 211 | 2.31k | } |
std::__1::conditional<std::is_base_of<clang::Type, clang::FieldDecl>::value, llvm::Expected<clang::FieldDecl const*>, llvm::Expected<clang::FieldDecl*> >::type clang::ASTNodeImporter::import<clang::FieldDecl>(clang::FieldDecl*) Line | Count | Source | 206 | 1.13k | Expected<const T *>, Expected<T *>> { | 207 | 1.13k | auto ToOrErr = Importer.Import(From); | 208 | 1.13k | if (!ToOrErr) | 209 | 0 | return ToOrErr.takeError(); | 210 | 1.13k | return cast_or_null<T>(*ToOrErr); | 211 | 1.13k | } |
std::__1::conditional<std::is_base_of<clang::Type, clang::VarTemplatePartialSpecializationDecl>::value, llvm::Expected<clang::VarTemplatePartialSpecializationDecl const*>, llvm::Expected<clang::VarTemplatePartialSpecializationDecl*> >::type clang::ASTNodeImporter::import<clang::VarTemplatePartialSpecializationDecl>(clang::VarTemplatePartialSpecializationDecl*) Line | Count | Source | 206 | 10 | Expected<const T *>, Expected<T *>> { | 207 | 10 | auto ToOrErr = Importer.Import(From); | 208 | 10 | if (!ToOrErr) | 209 | 0 | return ToOrErr.takeError(); | 210 | 10 | return cast_or_null<T>(*ToOrErr); | 211 | 10 | } |
std::__1::conditional<std::is_base_of<clang::Type, clang::StringLiteral>::value, llvm::Expected<clang::StringLiteral const*>, llvm::Expected<clang::StringLiteral*> >::type clang::ASTNodeImporter::import<clang::StringLiteral>(clang::StringLiteral*) Line | Count | Source | 206 | 18.8k | Expected<const T *>, Expected<T *>> { | 207 | 18.8k | auto ToOrErr = Importer.Import(From); | 208 | 18.8k | if (!ToOrErr) | 209 | 0 | return ToOrErr.takeError(); | 210 | 18.8k | return cast_or_null<T>(*ToOrErr); | 211 | 18.8k | } |
Unexecuted instantiation: std::__1::conditional<std::is_base_of<clang::Type, clang::AddrLabelExpr>::value, llvm::Expected<clang::AddrLabelExpr const*>, llvm::Expected<clang::AddrLabelExpr*> >::type clang::ASTNodeImporter::import<clang::AddrLabelExpr>(clang::AddrLabelExpr*) std::__1::conditional<std::is_base_of<clang::Type, clang::LabelDecl>::value, llvm::Expected<clang::LabelDecl const*>, llvm::Expected<clang::LabelDecl*> >::type clang::ASTNodeImporter::import<clang::LabelDecl>(clang::LabelDecl*) Line | Count | Source | 206 | 1.15k | Expected<const T *>, Expected<T *>> { | 207 | 1.15k | auto ToOrErr = Importer.Import(From); | 208 | 1.15k | if (!ToOrErr) | 209 | 0 | return ToOrErr.takeError(); | 210 | 1.15k | return cast_or_null<T>(*ToOrErr); | 211 | 1.15k | } |
std::__1::conditional<std::is_base_of<clang::Type, clang::Attr>::value, llvm::Expected<clang::Attr const*>, llvm::Expected<clang::Attr*> >::type clang::ASTNodeImporter::import<clang::Attr>(clang::Attr*) Line | Count | Source | 206 | 65 | Expected<const T *>, Expected<T *>> { | 207 | 65 | auto ToOrErr = Importer.Import(From); | 208 | 65 | if (!ToOrErr) | 209 | 0 | return ToOrErr.takeError(); | 210 | 65 | return cast_or_null<T>(*ToOrErr); | 211 | 65 | } |
std::__1::conditional<std::is_base_of<clang::Type, clang::SwitchCase>::value, llvm::Expected<clang::SwitchCase const*>, llvm::Expected<clang::SwitchCase*> >::type clang::ASTNodeImporter::import<clang::SwitchCase>(clang::SwitchCase*) Line | Count | Source | 206 | 15.3k | Expected<const T *>, Expected<T *>> { | 207 | 15.3k | auto ToOrErr = Importer.Import(From); | 208 | 15.3k | if (!ToOrErr) | 209 | 0 | return ToOrErr.takeError(); | 210 | 15.3k | return cast_or_null<T>(*ToOrErr); | 211 | 15.3k | } |
std::__1::conditional<std::is_base_of<clang::Type, clang::CompoundStmt>::value, llvm::Expected<clang::CompoundStmt const*>, llvm::Expected<clang::CompoundStmt*> >::type clang::ASTNodeImporter::import<clang::CompoundStmt>(clang::CompoundStmt*) Line | Count | Source | 206 | 12 | Expected<const T *>, Expected<T *>> { | 207 | 12 | auto ToOrErr = Importer.Import(From); | 208 | 12 | if (!ToOrErr) | 209 | 0 | return ToOrErr.takeError(); | 210 | 12 | return cast_or_null<T>(*ToOrErr); | 211 | 12 | } |
std::__1::conditional<std::is_base_of<clang::Type, clang::CXXCatchStmt>::value, llvm::Expected<clang::CXXCatchStmt const*>, llvm::Expected<clang::CXXCatchStmt*> >::type clang::ASTNodeImporter::import<clang::CXXCatchStmt>(clang::CXXCatchStmt*) Line | Count | Source | 206 | 10 | Expected<const T *>, Expected<T *>> { | 207 | 10 | auto ToOrErr = Importer.Import(From); | 208 | 10 | if (!ToOrErr) | 209 | 0 | return ToOrErr.takeError(); | 210 | 10 | return cast_or_null<T>(*ToOrErr); | 211 | 10 | } |
std::__1::conditional<std::is_base_of<clang::Type, clang::DeclStmt>::value, llvm::Expected<clang::DeclStmt const*>, llvm::Expected<clang::DeclStmt*> >::type clang::ASTNodeImporter::import<clang::DeclStmt>(clang::DeclStmt*) Line | Count | Source | 206 | 1.32k | Expected<const T *>, Expected<T *>> { | 207 | 1.32k | auto ToOrErr = Importer.Import(From); | 208 | 1.32k | if (!ToOrErr) | 209 | 0 | return ToOrErr.takeError(); | 210 | 1.32k | return cast_or_null<T>(*ToOrErr); | 211 | 1.32k | } |
std::__1::conditional<std::is_base_of<clang::Type, clang::ObjCAtFinallyStmt>::value, llvm::Expected<clang::ObjCAtFinallyStmt const*>, llvm::Expected<clang::ObjCAtFinallyStmt*> >::type clang::ASTNodeImporter::import<clang::ObjCAtFinallyStmt>(clang::ObjCAtFinallyStmt*) Line | Count | Source | 206 | 6 | Expected<const T *>, Expected<T *>> { | 207 | 6 | auto ToOrErr = Importer.Import(From); | 208 | 6 | if (!ToOrErr) | 209 | 0 | return ToOrErr.takeError(); | 210 | 6 | return cast_or_null<T>(*ToOrErr); | 211 | 6 | } |
std::__1::conditional<std::is_base_of<clang::Type, clang::ObjCAtCatchStmt>::value, llvm::Expected<clang::ObjCAtCatchStmt const*>, llvm::Expected<clang::ObjCAtCatchStmt*> >::type clang::ASTNodeImporter::import<clang::ObjCAtCatchStmt>(clang::ObjCAtCatchStmt*) Line | Count | Source | 206 | 6 | Expected<const T *>, Expected<T *>> { | 207 | 6 | auto ToOrErr = Importer.Import(From); | 208 | 6 | if (!ToOrErr) | 209 | 0 | return ToOrErr.takeError(); | 210 | 6 | return cast_or_null<T>(*ToOrErr); | 211 | 6 | } |
std::__1::conditional<std::is_base_of<clang::Type, clang::OpaqueValueExpr>::value, llvm::Expected<clang::OpaqueValueExpr const*>, llvm::Expected<clang::OpaqueValueExpr*> >::type clang::ASTNodeImporter::import<clang::OpaqueValueExpr>(clang::OpaqueValueExpr*) Line | Count | Source | 206 | 144 | Expected<const T *>, Expected<T *>> { | 207 | 144 | auto ToOrErr = Importer.Import(From); | 208 | 144 | if (!ToOrErr) | 209 | 0 | return ToOrErr.takeError(); | 210 | 144 | return cast_or_null<T>(*ToOrErr); | 211 | 144 | } |
std::__1::conditional<std::is_base_of<clang::Type, clang::CXXBaseSpecifier>::value, llvm::Expected<clang::CXXBaseSpecifier const*>, llvm::Expected<clang::CXXBaseSpecifier*> >::type clang::ASTNodeImporter::import<clang::CXXBaseSpecifier>(clang::CXXBaseSpecifier*) Line | Count | Source | 206 | 3.45k | Expected<const T *>, Expected<T *>> { | 207 | 3.45k | auto ToOrErr = Importer.Import(From); | 208 | 3.45k | if (!ToOrErr) | 209 | 0 | return ToOrErr.takeError(); | 210 | 3.45k | return cast_or_null<T>(*ToOrErr); | 211 | 3.45k | } |
std::__1::conditional<std::is_base_of<clang::Type, clang::LifetimeExtendedTemporaryDecl>::value, llvm::Expected<clang::LifetimeExtendedTemporaryDecl const*>, llvm::Expected<clang::LifetimeExtendedTemporaryDecl*> >::type clang::ASTNodeImporter::import<clang::LifetimeExtendedTemporaryDecl>(clang::LifetimeExtendedTemporaryDecl*) Line | Count | Source | 206 | 10.6k | Expected<const T *>, Expected<T *>> { | 207 | 10.6k | auto ToOrErr = Importer.Import(From); | 208 | 10.6k | if (!ToOrErr) | 209 | 0 | return ToOrErr.takeError(); | 210 | 10.6k | return cast_or_null<T>(*ToOrErr); | 211 | 10.6k | } |
std::__1::conditional<std::is_base_of<clang::Type, clang::InitListExpr>::value, llvm::Expected<clang::InitListExpr const*>, llvm::Expected<clang::InitListExpr*> >::type clang::ASTNodeImporter::import<clang::InitListExpr>(clang::InitListExpr*) Line | Count | Source | 206 | 969 | Expected<const T *>, Expected<T *>> { | 207 | 969 | auto ToOrErr = Importer.Import(From); | 208 | 969 | if (!ToOrErr) | 209 | 0 | return ToOrErr.takeError(); | 210 | 969 | return cast_or_null<T>(*ToOrErr); | 211 | 969 | } |
std::__1::conditional<std::is_base_of<clang::Type, clang::NonTypeTemplateParmDecl>::value, llvm::Expected<clang::NonTypeTemplateParmDecl const*>, llvm::Expected<clang::NonTypeTemplateParmDecl*> >::type clang::ASTNodeImporter::import<clang::NonTypeTemplateParmDecl>(clang::NonTypeTemplateParmDecl*) Line | Count | Source | 206 | 31.8k | Expected<const T *>, Expected<T *>> { | 207 | 31.8k | auto ToOrErr = Importer.Import(From); | 208 | 31.8k | if (!ToOrErr) | 209 | 0 | return ToOrErr.takeError(); | 210 | 31.8k | return cast_or_null<T>(*ToOrErr); | 211 | 31.8k | } |
std::__1::conditional<std::is_base_of<clang::Type, clang::UnresolvedLookupExpr>::value, llvm::Expected<clang::UnresolvedLookupExpr const*>, llvm::Expected<clang::UnresolvedLookupExpr*> >::type clang::ASTNodeImporter::import<clang::UnresolvedLookupExpr>(clang::UnresolvedLookupExpr*) Line | Count | Source | 206 | 16 | Expected<const T *>, Expected<T *>> { | 207 | 16 | auto ToOrErr = Importer.Import(From); | 208 | 16 | if (!ToOrErr) | 209 | 0 | return ToOrErr.takeError(); | 210 | 16 | return cast_or_null<T>(*ToOrErr); | 211 | 16 | } |
|
212 | | |
213 | | template <typename T> |
214 | 436k | auto import(const T *From) { |
215 | 436k | return import(const_cast<T *>(From)); |
216 | 436k | } auto clang::ASTNodeImporter::import<clang::Type>(clang::Type const*) Line | Count | Source | 214 | 2 | auto import(const T *From) { | 215 | 2 | return import(const_cast<T *>(From)); | 216 | 2 | } |
auto clang::ASTNodeImporter::import<clang::TemplateTypeParmType>(clang::TemplateTypeParmType const*) Line | Count | Source | 214 | 97.2k | auto import(const T *From) { | 215 | 97.2k | return import(const_cast<T *>(From)); | 216 | 97.2k | } |
auto clang::ASTNodeImporter::import<clang::Expr>(clang::Expr const*) Line | Count | Source | 214 | 67.6k | auto import(const T *From) { | 215 | 67.6k | return import(const_cast<T *>(From)); | 216 | 67.6k | } |
auto clang::ASTNodeImporter::import<clang::CXXDestructorDecl>(clang::CXXDestructorDecl const*) Line | Count | Source | 214 | 1.81k | auto import(const T *From) { | 215 | 1.81k | return import(const_cast<T *>(From)); | 216 | 1.81k | } |
auto clang::ASTNodeImporter::import<clang::CXXMethodDecl>(clang::CXXMethodDecl const*) Line | Count | Source | 214 | 2.15k | auto import(const T *From) { | 215 | 2.15k | return import(const_cast<T *>(From)); | 216 | 2.15k | } |
auto clang::ASTNodeImporter::import<clang::Attr>(clang::Attr const*) Line | Count | Source | 214 | 65 | auto import(const T *From) { | 215 | 65 | return import(const_cast<T *>(From)); | 216 | 65 | } |
auto clang::ASTNodeImporter::import<clang::VarDecl>(clang::VarDecl const*) Line | Count | Source | 214 | 267k | auto import(const T *From) { | 215 | 267k | return import(const_cast<T *>(From)); | 216 | 267k | } |
auto clang::ASTNodeImporter::import<clang::TypeSourceInfo>(clang::TypeSourceInfo const*) Line | Count | Source | 214 | 22 | auto import(const T *From) { | 215 | 22 | return import(const_cast<T *>(From)); | 216 | 22 | } |
Unexecuted instantiation: auto clang::ASTNodeImporter::import<clang::FieldDecl>(clang::FieldDecl const*) Unexecuted instantiation: auto clang::ASTNodeImporter::import<clang::AddrLabelExpr>(clang::AddrLabelExpr const*) Unexecuted instantiation: auto clang::ASTNodeImporter::import<clang::ValueDecl>(clang::ValueDecl const*) Unexecuted instantiation: auto clang::ASTNodeImporter::import<clang::CXXRecordDecl>(clang::CXXRecordDecl const*) Unexecuted instantiation: auto clang::ASTNodeImporter::import<clang::Decl>(clang::Decl const*) |
217 | | |
218 | | // Call the import function of ASTImporter for type `T`. |
219 | | template <typename T> |
220 | 50.7M | Expected<T> import(const T &From) { |
221 | 50.7M | return Importer.Import(From); |
222 | 50.7M | } llvm::Expected<clang::SourceLocation> clang::ASTNodeImporter::import<clang::SourceLocation>(clang::SourceLocation const&) Line | Count | Source | 220 | 23.9M | Expected<T> import(const T &From) { | 221 | 23.9M | return Importer.Import(From); | 222 | 23.9M | } |
llvm::Expected<clang::QualType> clang::ASTNodeImporter::import<clang::QualType>(clang::QualType const&) Line | Count | Source | 220 | 15.1M | Expected<T> import(const T &From) { | 221 | 15.1M | return Importer.Import(From); | 222 | 15.1M | } |
llvm::Expected<clang::TemplateName> clang::ASTNodeImporter::import<clang::TemplateName>(clang::TemplateName const&) Line | Count | Source | 220 | 1.01M | Expected<T> import(const T &From) { | 221 | 1.01M | return Importer.Import(From); | 222 | 1.01M | } |
llvm::Expected<clang::NestedNameSpecifierLoc> clang::ASTNodeImporter::import<clang::NestedNameSpecifierLoc>(clang::NestedNameSpecifierLoc const&) Line | Count | Source | 220 | 5.26M | Expected<T> import(const T &From) { | 221 | 5.26M | return Importer.Import(From); | 222 | 5.26M | } |
llvm::Expected<clang::SourceRange> clang::ASTNodeImporter::import<clang::SourceRange>(clang::SourceRange const&) Line | Count | Source | 220 | 2.11M | Expected<T> import(const T &From) { | 221 | 2.11M | return Importer.Import(From); | 222 | 2.11M | } |
llvm::Expected<clang::InheritedConstructor> clang::ASTNodeImporter::import<clang::InheritedConstructor>(clang::InheritedConstructor const&) Line | Count | Source | 220 | 6 | Expected<T> import(const T &From) { | 221 | 6 | return Importer.Import(From); | 222 | 6 | } |
llvm::Expected<clang::Selector> clang::ASTNodeImporter::import<clang::Selector>(clang::Selector const&) Line | Count | Source | 220 | 4.62k | Expected<T> import(const T &From) { | 221 | 4.62k | return Importer.Import(From); | 222 | 4.62k | } |
llvm::Expected<clang::DeclarationName> clang::ASTNodeImporter::import<clang::DeclarationName>(clang::DeclarationName const&) Line | Count | Source | 220 | 3.15M | Expected<T> import(const T &From) { | 221 | 3.15M | return Importer.Import(From); | 222 | 3.15M | } |
llvm::Expected<clang::APValue> clang::ASTNodeImporter::import<clang::APValue>(clang::APValue const&) Line | Count | Source | 220 | 57.7k | Expected<T> import(const T &From) { | 221 | 57.7k | return Importer.Import(From); | 222 | 57.7k | } |
llvm::Expected<llvm::PointerUnion<clang::BlockDecl*, clang::CompoundLiteralExpr*> > clang::ASTNodeImporter::import<llvm::PointerUnion<clang::BlockDecl*, clang::CompoundLiteralExpr*> >(llvm::PointerUnion<clang::BlockDecl*, clang::CompoundLiteralExpr*> const&) Line | Count | Source | 220 | 2 | Expected<T> import(const T &From) { | 221 | 2 | return Importer.Import(From); | 222 | 2 | } |
|
223 | | |
224 | | // Import an Optional<T> by importing the contained T, if any. |
225 | | template<typename T> |
226 | 4.69k | Expected<Optional<T>> import(Optional<T> From) { |
227 | 4.69k | if (!From) |
228 | 4.25k | return Optional<T>(); |
229 | 442 | return import(*From); |
230 | 4.69k | } |
231 | | |
232 | | ExplicitSpecifier importExplicitSpecifier(Error &Err, |
233 | | ExplicitSpecifier ESpec); |
234 | | |
235 | | // Wrapper for an overload set. |
236 | | template <typename ToDeclT> struct CallOverloadedCreateFun { |
237 | 4.39M | template <typename... Args> decltype(auto) operator()(Args &&... args) { |
238 | 4.39M | return ToDeclT::Create(std::forward<Args>(args)...); |
239 | 4.39M | } Unexecuted instantiation: decltype(auto) clang::ASTNodeImporter::CallOverloadedCreateFun<clang::EmptyDecl>::operator()<clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&>(clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&) decltype(auto) clang::ASTNodeImporter::CallOverloadedCreateFun<clang::BindingDecl>::operator()<clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::IdentifierInfo*>(clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::IdentifierInfo*&&) Line | Count | Source | 237 | 32 | template <typename... Args> decltype(auto) operator()(Args &&... args) { | 238 | 32 | return ToDeclT::Create(std::forward<Args>(args)...); | 239 | 32 | } |
decltype(auto) clang::ASTNodeImporter::CallOverloadedCreateFun<clang::AccessSpecDecl>::operator()<clang::ASTContext&, clang::AccessSpecifier, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&>(clang::ASTContext&, clang::AccessSpecifier&&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&) Line | Count | Source | 237 | 84.4k | template <typename... Args> decltype(auto) operator()(Args &&... args) { | 238 | 84.4k | return ToDeclT::Create(std::forward<Args>(args)...); | 239 | 84.4k | } |
decltype(auto) clang::ASTNodeImporter::CallOverloadedCreateFun<clang::StaticAssertDecl>::operator()<clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::Expr*&, clang::StringLiteral*&, clang::SourceLocation&, bool>(clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::Expr*&, clang::StringLiteral*&, clang::SourceLocation&, bool&&) Line | Count | Source | 237 | 18.8k | template <typename... Args> decltype(auto) operator()(Args &&... args) { | 238 | 18.8k | return ToDeclT::Create(std::forward<Args>(args)...); | 239 | 18.8k | } |
decltype(auto) clang::ASTNodeImporter::CallOverloadedCreateFun<clang::NamespaceDecl>::operator()<clang::ASTContext&, clang::DeclContext*&, bool, clang::SourceLocation&, clang::SourceLocation&, clang::IdentifierInfo*, std::nullptr_t>(clang::ASTContext&, clang::DeclContext*&, bool&&, clang::SourceLocation&, clang::SourceLocation&, clang::IdentifierInfo*&&, std::nullptr_t&&) Line | Count | Source | 237 | 4.18k | template <typename... Args> decltype(auto) operator()(Args &&... args) { | 238 | 4.18k | return ToDeclT::Create(std::forward<Args>(args)...); | 239 | 4.18k | } |
decltype(auto) clang::ASTNodeImporter::CallOverloadedCreateFun<clang::NamespaceAliasDecl>::operator()<clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::IdentifierInfo*&, clang::NestedNameSpecifierLoc&, clang::SourceLocation&, clang::NamespaceDecl*&>(clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::IdentifierInfo*&, clang::NestedNameSpecifierLoc&, clang::SourceLocation&, clang::NamespaceDecl*&) Line | Count | Source | 237 | 3 | template <typename... Args> decltype(auto) operator()(Args &&... args) { | 238 | 3 | return ToDeclT::Create(std::forward<Args>(args)...); | 239 | 3 | } |
decltype(auto) clang::ASTNodeImporter::CallOverloadedCreateFun<clang::TypeAliasDecl>::operator()<clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::IdentifierInfo*, clang::TypeSourceInfo*&>(clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::IdentifierInfo*&&, clang::TypeSourceInfo*&) Line | Count | Source | 237 | 33.0k | template <typename... Args> decltype(auto) operator()(Args &&... args) { | 238 | 33.0k | return ToDeclT::Create(std::forward<Args>(args)...); | 239 | 33.0k | } |
decltype(auto) clang::ASTNodeImporter::CallOverloadedCreateFun<clang::TypedefDecl>::operator()<clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::IdentifierInfo*, clang::TypeSourceInfo*&>(clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::IdentifierInfo*&&, clang::TypeSourceInfo*&) Line | Count | Source | 237 | 252k | template <typename... Args> decltype(auto) operator()(Args &&... args) { | 238 | 252k | return ToDeclT::Create(std::forward<Args>(args)...); | 239 | 252k | } |
decltype(auto) clang::ASTNodeImporter::CallOverloadedCreateFun<clang::TypeAliasTemplateDecl>::operator()<clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::DeclarationName&, clang::TemplateParameterList*&, clang::TypeAliasDecl*&>(clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::DeclarationName&, clang::TemplateParameterList*&, clang::TypeAliasDecl*&) Line | Count | Source | 237 | 8.38k | template <typename... Args> decltype(auto) operator()(Args &&... args) { | 238 | 8.38k | return ToDeclT::Create(std::forward<Args>(args)...); | 239 | 8.38k | } |
Unexecuted instantiation: decltype(auto) clang::ASTNodeImporter::CallOverloadedCreateFun<clang::LabelDecl>::operator()<clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::IdentifierInfo*, clang::SourceLocation&>(clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::IdentifierInfo*&&, clang::SourceLocation&) decltype(auto) clang::ASTNodeImporter::CallOverloadedCreateFun<clang::LabelDecl>::operator()<clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::IdentifierInfo*>(clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::IdentifierInfo*&&) Line | Count | Source | 237 | 258 | template <typename... Args> decltype(auto) operator()(Args &&... args) { | 238 | 258 | return ToDeclT::Create(std::forward<Args>(args)...); | 239 | 258 | } |
decltype(auto) clang::ASTNodeImporter::CallOverloadedCreateFun<clang::EnumDecl>::operator()<clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::IdentifierInfo*, clang::EnumDecl*&, bool, bool, bool>(clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::IdentifierInfo*&&, clang::EnumDecl*&, bool&&, bool&&, bool&&) Line | Count | Source | 237 | 3.09k | template <typename... Args> decltype(auto) operator()(Args &&... args) { | 238 | 3.09k | return ToDeclT::Create(std::forward<Args>(args)...); | 239 | 3.09k | } |
decltype(auto) clang::ASTNodeImporter::CallOverloadedCreateFun<clang::CXXRecordDecl>::operator()<clang::ASTContext&, clang::TagTypeKind, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::IdentifierInfo*, clang::CXXRecordDecl*, bool const&>(clang::ASTContext&, clang::TagTypeKind&&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::IdentifierInfo*&&, clang::CXXRecordDecl*&&, bool const&) Line | Count | Source | 237 | 97.4k | template <typename... Args> decltype(auto) operator()(Args &&... args) { | 238 | 97.4k | return ToDeclT::Create(std::forward<Args>(args)...); | 239 | 97.4k | } |
decltype(auto) clang::ASTNodeImporter::CallOverloadedCreateFun<clang::CXXRecordDecl>::operator()<clang::ASTContext&, clang::TagTypeKind, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::IdentifierInfo*, clang::CXXRecordDecl*>(clang::ASTContext&, clang::TagTypeKind&&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::IdentifierInfo*&&, clang::CXXRecordDecl*&&) Line | Count | Source | 237 | 100k | template <typename... Args> decltype(auto) operator()(Args &&... args) { | 238 | 100k | return ToDeclT::Create(std::forward<Args>(args)...); | 239 | 100k | } |
decltype(auto) clang::ASTNodeImporter::CallOverloadedCreateFun<clang::RecordDecl>::operator()<clang::ASTContext&, clang::TagTypeKind, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::IdentifierInfo*, clang::RecordDecl*&>(clang::ASTContext&, clang::TagTypeKind&&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::IdentifierInfo*&&, clang::RecordDecl*&) Line | Count | Source | 237 | 133 | template <typename... Args> decltype(auto) operator()(Args &&... args) { | 238 | 133 | return ToDeclT::Create(std::forward<Args>(args)...); | 239 | 133 | } |
decltype(auto) clang::ASTNodeImporter::CallOverloadedCreateFun<clang::EnumConstantDecl>::operator()<clang::ASTContext&, clang::EnumDecl*, clang::SourceLocation&, clang::IdentifierInfo*, clang::QualType&, clang::Expr*&, llvm::APSInt const&>(clang::ASTContext&, clang::EnumDecl*&&, clang::SourceLocation&, clang::IdentifierInfo*&&, clang::QualType&, clang::Expr*&, llvm::APSInt const&) Line | Count | Source | 237 | 9.19k | template <typename... Args> decltype(auto) operator()(Args &&... args) { | 238 | 9.19k | return ToDeclT::Create(std::forward<Args>(args)...); | 239 | 9.19k | } |
decltype(auto) clang::ASTNodeImporter::CallOverloadedCreateFun<clang::CXXConstructorDecl>::operator()<clang::ASTContext&, clang::CXXRecordDecl*, clang::SourceLocation&, clang::DeclarationNameInfo&, clang::QualType&, clang::TypeSourceInfo*&, clang::ExplicitSpecifier&, bool, bool, bool, clang::ConstexprSpecKind, clang::InheritedConstructor&, clang::Expr*&>(clang::ASTContext&, clang::CXXRecordDecl*&&, clang::SourceLocation&, clang::DeclarationNameInfo&, clang::QualType&, clang::TypeSourceInfo*&, clang::ExplicitSpecifier&, bool&&, bool&&, bool&&, clang::ConstexprSpecKind&&, clang::InheritedConstructor&, clang::Expr*&) Line | Count | Source | 237 | 191k | template <typename... Args> decltype(auto) operator()(Args &&... args) { | 238 | 191k | return ToDeclT::Create(std::forward<Args>(args)...); | 239 | 191k | } |
decltype(auto) clang::ASTNodeImporter::CallOverloadedCreateFun<clang::CXXDestructorDecl>::operator()<clang::ASTContext&, clang::CXXRecordDecl*, clang::SourceLocation&, clang::DeclarationNameInfo&, clang::QualType&, clang::TypeSourceInfo*&, bool, bool, bool, clang::ConstexprSpecKind, clang::Expr*&>(clang::ASTContext&, clang::CXXRecordDecl*&&, clang::SourceLocation&, clang::DeclarationNameInfo&, clang::QualType&, clang::TypeSourceInfo*&, bool&&, bool&&, bool&&, clang::ConstexprSpecKind&&, clang::Expr*&) Line | Count | Source | 237 | 21.1k | template <typename... Args> decltype(auto) operator()(Args &&... args) { | 238 | 21.1k | return ToDeclT::Create(std::forward<Args>(args)...); | 239 | 21.1k | } |
decltype(auto) clang::ASTNodeImporter::CallOverloadedCreateFun<clang::CXXConversionDecl>::operator()<clang::ASTContext&, clang::CXXRecordDecl*, clang::SourceLocation&, clang::DeclarationNameInfo&, clang::QualType&, clang::TypeSourceInfo*&, bool, bool, clang::ExplicitSpecifier&, clang::ConstexprSpecKind, clang::SourceLocation, clang::Expr*&>(clang::ASTContext&, clang::CXXRecordDecl*&&, clang::SourceLocation&, clang::DeclarationNameInfo&, clang::QualType&, clang::TypeSourceInfo*&, bool&&, bool&&, clang::ExplicitSpecifier&, clang::ConstexprSpecKind&&, clang::SourceLocation&&, clang::Expr*&) Line | Count | Source | 237 | 3.54k | template <typename... Args> decltype(auto) operator()(Args &&... args) { | 238 | 3.54k | return ToDeclT::Create(std::forward<Args>(args)...); | 239 | 3.54k | } |
decltype(auto) clang::ASTNodeImporter::CallOverloadedCreateFun<clang::CXXMethodDecl>::operator()<clang::ASTContext&, clang::CXXRecordDecl*, clang::SourceLocation&, clang::DeclarationNameInfo&, clang::QualType&, clang::TypeSourceInfo*&, clang::StorageClass, bool, bool, clang::ConstexprSpecKind, clang::SourceLocation, clang::Expr*&>(clang::ASTContext&, clang::CXXRecordDecl*&&, clang::SourceLocation&, clang::DeclarationNameInfo&, clang::QualType&, clang::TypeSourceInfo*&, clang::StorageClass&&, bool&&, bool&&, clang::ConstexprSpecKind&&, clang::SourceLocation&&, clang::Expr*&) Line | Count | Source | 237 | 709k | template <typename... Args> decltype(auto) operator()(Args &&... args) { | 238 | 709k | return ToDeclT::Create(std::forward<Args>(args)...); | 239 | 709k | } |
decltype(auto) clang::ASTNodeImporter::CallOverloadedCreateFun<clang::CXXDeductionGuideDecl>::operator()<clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::ExplicitSpecifier&, clang::DeclarationNameInfo&, clang::QualType&, clang::TypeSourceInfo*&, clang::SourceLocation&, clang::CXXConstructorDecl*&>(clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::ExplicitSpecifier&, clang::DeclarationNameInfo&, clang::QualType&, clang::TypeSourceInfo*&, clang::SourceLocation&, clang::CXXConstructorDecl*&) Line | Count | Source | 237 | 44 | template <typename... Args> decltype(auto) operator()(Args &&... args) { | 238 | 44 | return ToDeclT::Create(std::forward<Args>(args)...); | 239 | 44 | } |
decltype(auto) clang::ASTNodeImporter::CallOverloadedCreateFun<clang::FunctionDecl>::operator()<clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::DeclarationNameInfo&, clang::QualType&, clang::TypeSourceInfo*&, clang::StorageClass, bool, bool, bool, clang::ConstexprSpecKind, clang::Expr*&>(clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::DeclarationNameInfo&, clang::QualType&, clang::TypeSourceInfo*&, clang::StorageClass&&, bool&&, bool&&, bool&&, clang::ConstexprSpecKind&&, clang::Expr*&) Line | Count | Source | 237 | 112k | template <typename... Args> decltype(auto) operator()(Args &&... args) { | 238 | 112k | return ToDeclT::Create(std::forward<Args>(args)...); | 239 | 112k | } |
decltype(auto) clang::ASTNodeImporter::CallOverloadedCreateFun<clang::FieldDecl>::operator()<clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::IdentifierInfo*, clang::QualType&, clang::TypeSourceInfo*&, clang::Expr*&, bool, clang::InClassInitStyle>(clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::IdentifierInfo*&&, clang::QualType&, clang::TypeSourceInfo*&, clang::Expr*&, bool&&, clang::InClassInitStyle&&) Line | Count | Source | 237 | 80.5k | template <typename... Args> decltype(auto) operator()(Args &&... args) { | 238 | 80.5k | return ToDeclT::Create(std::forward<Args>(args)...); | 239 | 80.5k | } |
decltype(auto) clang::ASTNodeImporter::CallOverloadedCreateFun<clang::IndirectFieldDecl>::operator()<clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::IdentifierInfo*, clang::QualType&, llvm::MutableArrayRef<clang::NamedDecl*>&>(clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::IdentifierInfo*&&, clang::QualType&, llvm::MutableArrayRef<clang::NamedDecl*>&) Line | Count | Source | 237 | 1.45k | template <typename... Args> decltype(auto) operator()(Args &&... args) { | 238 | 1.45k | return ToDeclT::Create(std::forward<Args>(args)...); | 239 | 1.45k | } |
decltype(auto) clang::ASTNodeImporter::CallOverloadedCreateFun<clang::FriendDecl>::operator()<clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, llvm::PointerUnion<clang::NamedDecl*, clang::TypeSourceInfo*>&, clang::SourceLocation&, llvm::SmallVector<clang::TemplateParameterList*, 1u>&>(clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, llvm::PointerUnion<clang::NamedDecl*, clang::TypeSourceInfo*>&, clang::SourceLocation&, llvm::SmallVector<clang::TemplateParameterList*, 1u>&) Line | Count | Source | 237 | 36.5k | template <typename... Args> decltype(auto) operator()(Args &&... args) { | 238 | 36.5k | return ToDeclT::Create(std::forward<Args>(args)...); | 239 | 36.5k | } |
decltype(auto) clang::ASTNodeImporter::CallOverloadedCreateFun<clang::ObjCIvarDecl>::operator()<clang::ASTContext&, clang::ObjCContainerDecl*, clang::SourceLocation&, clang::SourceLocation&, clang::IdentifierInfo*, clang::QualType&, clang::TypeSourceInfo*&, clang::ObjCIvarDecl::AccessControl, clang::Expr*&, bool>(clang::ASTContext&, clang::ObjCContainerDecl*&&, clang::SourceLocation&, clang::SourceLocation&, clang::IdentifierInfo*&&, clang::QualType&, clang::TypeSourceInfo*&, clang::ObjCIvarDecl::AccessControl&&, clang::Expr*&, bool&&) Line | Count | Source | 237 | 1.63k | template <typename... Args> decltype(auto) operator()(Args &&... args) { | 238 | 1.63k | return ToDeclT::Create(std::forward<Args>(args)...); | 239 | 1.63k | } |
decltype(auto) clang::ASTNodeImporter::CallOverloadedCreateFun<clang::DecompositionDecl>::operator()<clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::QualType&, clang::TypeSourceInfo*&, clang::StorageClass, llvm::SmallVector<clang::BindingDecl*, 6u>&>(clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::QualType&, clang::TypeSourceInfo*&, clang::StorageClass&&, llvm::SmallVector<clang::BindingDecl*, 6u>&) Line | Count | Source | 237 | 16 | template <typename... Args> decltype(auto) operator()(Args &&... args) { | 238 | 16 | return ToDeclT::Create(std::forward<Args>(args)...); | 239 | 16 | } |
decltype(auto) clang::ASTNodeImporter::CallOverloadedCreateFun<clang::VarDecl>::operator()<clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::IdentifierInfo*, clang::QualType&, clang::TypeSourceInfo*&, clang::StorageClass>(clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::IdentifierInfo*&&, clang::QualType&, clang::TypeSourceInfo*&, clang::StorageClass&&) Line | Count | Source | 237 | 253k | template <typename... Args> decltype(auto) operator()(Args &&... args) { | 238 | 253k | return ToDeclT::Create(std::forward<Args>(args)...); | 239 | 253k | } |
Unexecuted instantiation: decltype(auto) clang::ASTNodeImporter::CallOverloadedCreateFun<clang::ImplicitParamDecl>::operator()<clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::IdentifierInfo*, clang::QualType&, clang::ImplicitParamDecl::ImplicitParamKind>(clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::IdentifierInfo*&&, clang::QualType&, clang::ImplicitParamDecl::ImplicitParamKind&&) decltype(auto) clang::ASTNodeImporter::CallOverloadedCreateFun<clang::ParmVarDecl>::operator()<clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::IdentifierInfo*, clang::QualType&, clang::TypeSourceInfo*&, clang::StorageClass, std::nullptr_t>(clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::IdentifierInfo*&&, clang::QualType&, clang::TypeSourceInfo*&, clang::StorageClass&&, std::nullptr_t&&) Line | Count | Source | 237 | 1.22M | template <typename... Args> decltype(auto) operator()(Args &&... args) { | 238 | 1.22M | return ToDeclT::Create(std::forward<Args>(args)...); | 239 | 1.22M | } |
decltype(auto) clang::ASTNodeImporter::CallOverloadedCreateFun<clang::ObjCMethodDecl>::operator()<clang::ASTContext&, clang::SourceLocation&, clang::SourceLocation&, clang::Selector, clang::QualType&, clang::TypeSourceInfo*&, clang::DeclContext*&, bool, bool, bool, bool, bool, bool, clang::ObjCMethodDecl::ImplementationControl, bool>(clang::ASTContext&, clang::SourceLocation&, clang::SourceLocation&, clang::Selector&&, clang::QualType&, clang::TypeSourceInfo*&, clang::DeclContext*&, bool&&, bool&&, bool&&, bool&&, bool&&, bool&&, clang::ObjCMethodDecl::ImplementationControl&&, bool&&) Line | Count | Source | 237 | 8.63k | template <typename... Args> decltype(auto) operator()(Args &&... args) { | 238 | 8.63k | return ToDeclT::Create(std::forward<Args>(args)...); | 239 | 8.63k | } |
decltype(auto) clang::ASTNodeImporter::CallOverloadedCreateFun<clang::ObjCTypeParamDecl>::operator()<clang::ASTContext&, clang::DeclContext*&, clang::ObjCTypeParamVariance, clang::SourceLocation&, unsigned int, clang::SourceLocation&, clang::IdentifierInfo*, clang::SourceLocation&, clang::TypeSourceInfo*&>(clang::ASTContext&, clang::DeclContext*&, clang::ObjCTypeParamVariance&&, clang::SourceLocation&, unsigned int&&, clang::SourceLocation&, clang::IdentifierInfo*&&, clang::SourceLocation&, clang::TypeSourceInfo*&) Line | Count | Source | 237 | 390 | template <typename... Args> decltype(auto) operator()(Args &&... args) { | 238 | 390 | return ToDeclT::Create(std::forward<Args>(args)...); | 239 | 390 | } |
decltype(auto) clang::ASTNodeImporter::CallOverloadedCreateFun<clang::ObjCCategoryDecl>::operator()<clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::SourceLocation&, clang::IdentifierInfo*, clang::ObjCInterfaceDecl*&, std::nullptr_t, clang::SourceLocation&, clang::SourceLocation&>(clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::SourceLocation&, clang::IdentifierInfo*&&, clang::ObjCInterfaceDecl*&, std::nullptr_t&&, clang::SourceLocation&, clang::SourceLocation&) Line | Count | Source | 237 | 2.44k | template <typename... Args> decltype(auto) operator()(Args &&... args) { | 238 | 2.44k | return ToDeclT::Create(std::forward<Args>(args)...); | 239 | 2.44k | } |
decltype(auto) clang::ASTNodeImporter::CallOverloadedCreateFun<clang::ObjCProtocolDecl>::operator()<clang::ASTContext&, clang::DeclContext*&, clang::IdentifierInfo*, clang::SourceLocation&, clang::SourceLocation&, std::nullptr_t>(clang::ASTContext&, clang::DeclContext*&, clang::IdentifierInfo*&&, clang::SourceLocation&, clang::SourceLocation&, std::nullptr_t&&) Line | Count | Source | 237 | 375 | template <typename... Args> decltype(auto) operator()(Args &&... args) { | 238 | 375 | return ToDeclT::Create(std::forward<Args>(args)...); | 239 | 375 | } |
decltype(auto) clang::ASTNodeImporter::CallOverloadedCreateFun<clang::LinkageSpecDecl>::operator()<clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::LinkageSpecDecl::LanguageIDs, bool&>(clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::LinkageSpecDecl::LanguageIDs&&, bool&) Line | Count | Source | 237 | 6.51k | template <typename... Args> decltype(auto) operator()(Args &&... args) { | 238 | 6.51k | return ToDeclT::Create(std::forward<Args>(args)...); | 239 | 6.51k | } |
decltype(auto) clang::ASTNodeImporter::CallOverloadedCreateFun<clang::UsingDecl>::operator()<clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::NestedNameSpecifierLoc&, clang::DeclarationNameInfo&, bool>(clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::NestedNameSpecifierLoc&, clang::DeclarationNameInfo&, bool&&) Line | Count | Source | 237 | 5.79k | template <typename... Args> decltype(auto) operator()(Args &&... args) { | 238 | 5.79k | return ToDeclT::Create(std::forward<Args>(args)...); | 239 | 5.79k | } |
decltype(auto) clang::ASTNodeImporter::CallOverloadedCreateFun<clang::UsingEnumDecl>::operator()<clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::SourceLocation&, clang::EnumDecl*&>(clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::SourceLocation&, clang::EnumDecl*&) Line | Count | Source | 237 | 8 | template <typename... Args> decltype(auto) operator()(Args &&... args) { | 238 | 8 | return ToDeclT::Create(std::forward<Args>(args)...); | 239 | 8 | } |
decltype(auto) clang::ASTNodeImporter::CallOverloadedCreateFun<clang::ConstructorUsingShadowDecl>::operator()<clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::UsingDecl*, clang::NamedDecl*, bool>(clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::UsingDecl*&&, clang::NamedDecl*&&, bool&&) Line | Count | Source | 237 | 165 | template <typename... Args> decltype(auto) operator()(Args &&... args) { | 238 | 165 | return ToDeclT::Create(std::forward<Args>(args)...); | 239 | 165 | } |
decltype(auto) clang::ASTNodeImporter::CallOverloadedCreateFun<clang::UsingShadowDecl>::operator()<clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::DeclarationName&, clang::BaseUsingDecl*&, clang::NamedDecl*&>(clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::DeclarationName&, clang::BaseUsingDecl*&, clang::NamedDecl*&) Line | Count | Source | 237 | 40.9k | template <typename... Args> decltype(auto) operator()(Args &&... args) { | 238 | 40.9k | return ToDeclT::Create(std::forward<Args>(args)...); | 239 | 40.9k | } |
decltype(auto) clang::ASTNodeImporter::CallOverloadedCreateFun<clang::UsingDirectiveDecl>::operator()<clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::NestedNameSpecifierLoc&, clang::SourceLocation&, clang::NamespaceDecl*&, clang::DeclContext*&>(clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::NestedNameSpecifierLoc&, clang::SourceLocation&, clang::NamespaceDecl*&, clang::DeclContext*&) Line | Count | Source | 237 | 269 | template <typename... Args> decltype(auto) operator()(Args &&... args) { | 238 | 269 | return ToDeclT::Create(std::forward<Args>(args)...); | 239 | 269 | } |
decltype(auto) clang::ASTNodeImporter::CallOverloadedCreateFun<clang::UnresolvedUsingValueDecl>::operator()<clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::NestedNameSpecifierLoc&, clang::DeclarationNameInfo&, clang::SourceLocation&>(clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::NestedNameSpecifierLoc&, clang::DeclarationNameInfo&, clang::SourceLocation&) Line | Count | Source | 237 | 2 | template <typename... Args> decltype(auto) operator()(Args &&... args) { | 238 | 2 | return ToDeclT::Create(std::forward<Args>(args)...); | 239 | 2 | } |
decltype(auto) clang::ASTNodeImporter::CallOverloadedCreateFun<clang::UnresolvedUsingTypenameDecl>::operator()<clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::NestedNameSpecifierLoc&, clang::SourceLocation&, clang::DeclarationName&, clang::SourceLocation&>(clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::NestedNameSpecifierLoc&, clang::SourceLocation&, clang::DeclarationName&, clang::SourceLocation&) Line | Count | Source | 237 | 268 | template <typename... Args> decltype(auto) operator()(Args &&... args) { | 238 | 268 | return ToDeclT::Create(std::forward<Args>(args)...); | 239 | 268 | } |
decltype(auto) clang::ASTNodeImporter::CallOverloadedCreateFun<clang::ObjCInterfaceDecl>::operator()<clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::IdentifierInfo*, std::nullptr_t, std::nullptr_t, clang::SourceLocation&, bool>(clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::IdentifierInfo*&&, std::nullptr_t&&, std::nullptr_t&&, clang::SourceLocation&, bool&&) Line | Count | Source | 237 | 2.32k | template <typename... Args> decltype(auto) operator()(Args &&... args) { | 238 | 2.32k | return ToDeclT::Create(std::forward<Args>(args)...); | 239 | 2.32k | } |
decltype(auto) clang::ASTNodeImporter::CallOverloadedCreateFun<clang::ObjCCategoryImplDecl>::operator()<clang::ASTContext&, clang::DeclContext*&, clang::IdentifierInfo*, clang::ObjCInterfaceDecl*, clang::SourceLocation&, clang::SourceLocation&, clang::SourceLocation&>(clang::ASTContext&, clang::DeclContext*&, clang::IdentifierInfo*&&, clang::ObjCInterfaceDecl*&&, clang::SourceLocation&, clang::SourceLocation&, clang::SourceLocation&) Line | Count | Source | 237 | 4 | template <typename... Args> decltype(auto) operator()(Args &&... args) { | 238 | 4 | return ToDeclT::Create(std::forward<Args>(args)...); | 239 | 4 | } |
decltype(auto) clang::ASTNodeImporter::CallOverloadedCreateFun<clang::ObjCImplementationDecl>::operator()<clang::ASTContext&, clang::DeclContext*&, clang::ObjCInterfaceDecl*&, clang::ObjCInterfaceDecl*&, clang::SourceLocation&, clang::SourceLocation&, clang::SourceLocation&, clang::SourceLocation&, clang::SourceLocation&>(clang::ASTContext&, clang::DeclContext*&, clang::ObjCInterfaceDecl*&, clang::ObjCInterfaceDecl*&, clang::SourceLocation&, clang::SourceLocation&, clang::SourceLocation&, clang::SourceLocation&, clang::SourceLocation&) Line | Count | Source | 237 | 8 | template <typename... Args> decltype(auto) operator()(Args &&... args) { | 238 | 8 | return ToDeclT::Create(std::forward<Args>(args)...); | 239 | 8 | } |
decltype(auto) clang::ASTNodeImporter::CallOverloadedCreateFun<clang::ObjCPropertyDecl>::operator()<clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::IdentifierInfo*, clang::SourceLocation&, clang::SourceLocation&, clang::QualType&, clang::TypeSourceInfo*&, clang::ObjCPropertyDecl::PropertyControl>(clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::IdentifierInfo*&&, clang::SourceLocation&, clang::SourceLocation&, clang::QualType&, clang::TypeSourceInfo*&, clang::ObjCPropertyDecl::PropertyControl&&) Line | Count | Source | 237 | 2.31k | template <typename... Args> decltype(auto) operator()(Args &&... args) { | 238 | 2.31k | return ToDeclT::Create(std::forward<Args>(args)...); | 239 | 2.31k | } |
decltype(auto) clang::ASTNodeImporter::CallOverloadedCreateFun<clang::ObjCPropertyImplDecl>::operator()<clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::ObjCPropertyDecl*&, clang::ObjCPropertyImplDecl::Kind, clang::ObjCIvarDecl*&, clang::SourceLocation&>(clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::ObjCPropertyDecl*&, clang::ObjCPropertyImplDecl::Kind&&, clang::ObjCIvarDecl*&, clang::SourceLocation&) Line | Count | Source | 237 | 4 | template <typename... Args> decltype(auto) operator()(Args &&... args) { | 238 | 4 | return ToDeclT::Create(std::forward<Args>(args)...); | 239 | 4 | } |
decltype(auto) clang::ASTNodeImporter::CallOverloadedCreateFun<clang::TemplateTypeParmDecl>::operator()<clang::ASTContext&, clang::TranslationUnitDecl*, clang::SourceLocation&, clang::SourceLocation&, unsigned int, unsigned int, clang::IdentifierInfo*, bool, bool, bool>(clang::ASTContext&, clang::TranslationUnitDecl*&&, clang::SourceLocation&, clang::SourceLocation&, unsigned int&&, unsigned int&&, clang::IdentifierInfo*&&, bool&&, bool&&, bool&&) Line | Count | Source | 237 | 626k | template <typename... Args> decltype(auto) operator()(Args &&... args) { | 238 | 626k | return ToDeclT::Create(std::forward<Args>(args)...); | 239 | 626k | } |
decltype(auto) clang::ASTNodeImporter::CallOverloadedCreateFun<clang::NonTypeTemplateParmDecl>::operator()<clang::ASTContext&, clang::TranslationUnitDecl*, clang::SourceLocation&, clang::SourceLocation&, unsigned int, unsigned int, clang::IdentifierInfo*, clang::QualType&, bool, clang::TypeSourceInfo*&>(clang::ASTContext&, clang::TranslationUnitDecl*&&, clang::SourceLocation&, clang::SourceLocation&, unsigned int&&, unsigned int&&, clang::IdentifierInfo*&&, clang::QualType&, bool&&, clang::TypeSourceInfo*&) Line | Count | Source | 237 | 93.3k | template <typename... Args> decltype(auto) operator()(Args &&... args) { | 238 | 93.3k | return ToDeclT::Create(std::forward<Args>(args)...); | 239 | 93.3k | } |
decltype(auto) clang::ASTNodeImporter::CallOverloadedCreateFun<clang::TemplateTemplateParmDecl>::operator()<clang::ASTContext&, clang::TranslationUnitDecl*, clang::SourceLocation&, unsigned int, unsigned int, bool, clang::IdentifierInfo*, clang::TemplateParameterList*&>(clang::ASTContext&, clang::TranslationUnitDecl*&&, clang::SourceLocation&, unsigned int&&, unsigned int&&, bool&&, clang::IdentifierInfo*&&, clang::TemplateParameterList*&) Line | Count | Source | 237 | 1.77k | template <typename... Args> decltype(auto) operator()(Args &&... args) { | 238 | 1.77k | return ToDeclT::Create(std::forward<Args>(args)...); | 239 | 1.77k | } |
decltype(auto) clang::ASTNodeImporter::CallOverloadedCreateFun<clang::ClassTemplateDecl>::operator()<clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::DeclarationName&, clang::TemplateParameterList*&, clang::CXXRecordDecl*&>(clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::DeclarationName&, clang::TemplateParameterList*&, clang::CXXRecordDecl*&) Line | Count | Source | 237 | 74.4k | template <typename... Args> decltype(auto) operator()(Args &&... args) { | 238 | 74.4k | return ToDeclT::Create(std::forward<Args>(args)...); | 239 | 74.4k | } |
decltype(auto) clang::ASTNodeImporter::CallOverloadedCreateFun<clang::ClassTemplatePartialSpecializationDecl>::operator()<clang::ASTContext&, clang::TagTypeKind, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::TemplateParameterList*&, clang::ClassTemplateDecl*&, llvm::ArrayRef<clang::TemplateArgument>, clang::TemplateArgumentListInfo&, clang::QualType&, clang::ClassTemplatePartialSpecializationDecl*>(clang::ASTContext&, clang::TagTypeKind&&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::TemplateParameterList*&, clang::ClassTemplateDecl*&, llvm::ArrayRef<clang::TemplateArgument>&&, clang::TemplateArgumentListInfo&, clang::QualType&, clang::ClassTemplatePartialSpecializationDecl*&&) Line | Count | Source | 237 | 970 | template <typename... Args> decltype(auto) operator()(Args &&... args) { | 238 | 970 | return ToDeclT::Create(std::forward<Args>(args)...); | 239 | 970 | } |
decltype(auto) clang::ASTNodeImporter::CallOverloadedCreateFun<clang::ClassTemplateSpecializationDecl>::operator()<clang::ASTContext&, clang::TagTypeKind, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::ClassTemplateDecl*&, llvm::SmallVector<clang::TemplateArgument, 2u>&, clang::ClassTemplateSpecializationDecl*&>(clang::ASTContext&, clang::TagTypeKind&&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::ClassTemplateDecl*&, llvm::SmallVector<clang::TemplateArgument, 2u>&, clang::ClassTemplateSpecializationDecl*&) Line | Count | Source | 237 | 91.0k | template <typename... Args> decltype(auto) operator()(Args &&... args) { | 238 | 91.0k | return ToDeclT::Create(std::forward<Args>(args)...); | 239 | 91.0k | } |
decltype(auto) clang::ASTNodeImporter::CallOverloadedCreateFun<clang::VarTemplateDecl>::operator()<clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::DeclarationName&, clang::TemplateParameterList*&, clang::VarDecl*&>(clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::DeclarationName&, clang::TemplateParameterList*&, clang::VarDecl*&) Line | Count | Source | 237 | 219 | template <typename... Args> decltype(auto) operator()(Args &&... args) { | 238 | 219 | return ToDeclT::Create(std::forward<Args>(args)...); | 239 | 219 | } |
decltype(auto) clang::ASTNodeImporter::CallOverloadedCreateFun<clang::VarTemplatePartialSpecializationDecl>::operator()<clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::TemplateParameterList*&, clang::VarTemplateDecl*&, clang::QualType&, clang::TypeSourceInfo*&, clang::StorageClass, llvm::SmallVector<clang::TemplateArgument, 2u>&, clang::TemplateArgumentListInfo&>(clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::TemplateParameterList*&, clang::VarTemplateDecl*&, clang::QualType&, clang::TypeSourceInfo*&, clang::StorageClass&&, llvm::SmallVector<clang::TemplateArgument, 2u>&, clang::TemplateArgumentListInfo&) Line | Count | Source | 237 | 10 | template <typename... Args> decltype(auto) operator()(Args &&... args) { | 238 | 10 | return ToDeclT::Create(std::forward<Args>(args)...); | 239 | 10 | } |
decltype(auto) clang::ASTNodeImporter::CallOverloadedCreateFun<clang::VarTemplateSpecializationDecl>::operator()<clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::VarTemplateDecl*&, clang::QualType&, clang::TypeSourceInfo*&, clang::StorageClass, llvm::SmallVector<clang::TemplateArgument, 2u>&>(clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::VarTemplateDecl*&, clang::QualType&, clang::TypeSourceInfo*&, clang::StorageClass&&, llvm::SmallVector<clang::TemplateArgument, 2u>&) Line | Count | Source | 237 | 11 | template <typename... Args> decltype(auto) operator()(Args &&... args) { | 238 | 11 | return ToDeclT::Create(std::forward<Args>(args)...); | 239 | 11 | } |
decltype(auto) clang::ASTNodeImporter::CallOverloadedCreateFun<clang::FunctionTemplateDecl>::operator()<clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::DeclarationName&, clang::TemplateParameterList*&, clang::FunctionDecl*&>(clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::DeclarationName&, clang::TemplateParameterList*&, clang::FunctionDecl*&) Line | Count | Source | 237 | 188k | template <typename... Args> decltype(auto) operator()(Args &&... args) { | 238 | 188k | return ToDeclT::Create(std::forward<Args>(args)...); | 239 | 188k | } |
decltype(auto) clang::ASTNodeImporter::CallOverloadedCreateFun<clang::LifetimeExtendedTemporaryDecl>::operator()<clang::Expr*&, clang::ValueDecl*&, unsigned int>(clang::Expr*&, clang::ValueDecl*&, unsigned int&&) Line | Count | Source | 237 | 2 | template <typename... Args> decltype(auto) operator()(Args &&... args) { | 238 | 2 | return ToDeclT::Create(std::forward<Args>(args)...); | 239 | 2 | } |
|
240 | | }; |
241 | | |
242 | | // Always use these functions to create a Decl during import. There are |
243 | | // certain tasks which must be done after the Decl was created, e.g. we |
244 | | // must immediately register that as an imported Decl. The parameter `ToD` |
245 | | // will be set to the newly created Decl or if had been imported before |
246 | | // then to the already imported Decl. Returns a bool value set to true if |
247 | | // the `FromD` had been imported before. |
248 | | template <typename ToDeclT, typename FromDeclT, typename... Args> |
249 | | LLVM_NODISCARD bool GetImportedOrCreateDecl(ToDeclT *&ToD, FromDeclT *FromD, |
250 | 3.42M | Args &&... args) { |
251 | | // There may be several overloads of ToDeclT::Create. We must make sure |
252 | | // to call the one which would be chosen by the arguments, thus we use a |
253 | | // wrapper for the overload set. |
254 | 3.42M | CallOverloadedCreateFun<ToDeclT> OC; |
255 | 3.42M | return GetImportedOrCreateSpecialDecl(ToD, OC, FromD, |
256 | 3.42M | std::forward<Args>(args)...); |
257 | 3.42M | } Unexecuted instantiation: bool clang::ASTNodeImporter::GetImportedOrCreateDecl<clang::EmptyDecl, clang::EmptyDecl, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&>(clang::EmptyDecl*&, clang::EmptyDecl*, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&) bool clang::ASTNodeImporter::GetImportedOrCreateDecl<clang::BindingDecl, clang::BindingDecl, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::IdentifierInfo*>(clang::BindingDecl*&, clang::BindingDecl*, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::IdentifierInfo*&&) Line | Count | Source | 250 | 32 | Args &&... args) { | 251 | | // There may be several overloads of ToDeclT::Create. We must make sure | 252 | | // to call the one which would be chosen by the arguments, thus we use a | 253 | | // wrapper for the overload set. | 254 | 32 | CallOverloadedCreateFun<ToDeclT> OC; | 255 | 32 | return GetImportedOrCreateSpecialDecl(ToD, OC, FromD, | 256 | 32 | std::forward<Args>(args)...); | 257 | 32 | } |
bool clang::ASTNodeImporter::GetImportedOrCreateDecl<clang::AccessSpecDecl, clang::AccessSpecDecl, clang::ASTContext&, clang::AccessSpecifier, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&>(clang::AccessSpecDecl*&, clang::AccessSpecDecl*, clang::ASTContext&, clang::AccessSpecifier&&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&) Line | Count | Source | 250 | 84.4k | Args &&... args) { | 251 | | // There may be several overloads of ToDeclT::Create. We must make sure | 252 | | // to call the one which would be chosen by the arguments, thus we use a | 253 | | // wrapper for the overload set. | 254 | 84.4k | CallOverloadedCreateFun<ToDeclT> OC; | 255 | 84.4k | return GetImportedOrCreateSpecialDecl(ToD, OC, FromD, | 256 | 84.4k | std::forward<Args>(args)...); | 257 | 84.4k | } |
bool clang::ASTNodeImporter::GetImportedOrCreateDecl<clang::StaticAssertDecl, clang::StaticAssertDecl, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::Expr*&, clang::StringLiteral*&, clang::SourceLocation&, bool>(clang::StaticAssertDecl*&, clang::StaticAssertDecl*, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::Expr*&, clang::StringLiteral*&, clang::SourceLocation&, bool&&) Line | Count | Source | 250 | 18.8k | Args &&... args) { | 251 | | // There may be several overloads of ToDeclT::Create. We must make sure | 252 | | // to call the one which would be chosen by the arguments, thus we use a | 253 | | // wrapper for the overload set. | 254 | 18.8k | CallOverloadedCreateFun<ToDeclT> OC; | 255 | 18.8k | return GetImportedOrCreateSpecialDecl(ToD, OC, FromD, | 256 | 18.8k | std::forward<Args>(args)...); | 257 | 18.8k | } |
bool clang::ASTNodeImporter::GetImportedOrCreateDecl<clang::NamespaceDecl, clang::NamespaceDecl, clang::ASTContext&, clang::DeclContext*&, bool, clang::SourceLocation&, clang::SourceLocation&, clang::IdentifierInfo*, std::nullptr_t>(clang::NamespaceDecl*&, clang::NamespaceDecl*, clang::ASTContext&, clang::DeclContext*&, bool&&, clang::SourceLocation&, clang::SourceLocation&, clang::IdentifierInfo*&&, std::nullptr_t&&) Line | Count | Source | 250 | 4.18k | Args &&... args) { | 251 | | // There may be several overloads of ToDeclT::Create. We must make sure | 252 | | // to call the one which would be chosen by the arguments, thus we use a | 253 | | // wrapper for the overload set. | 254 | 4.18k | CallOverloadedCreateFun<ToDeclT> OC; | 255 | 4.18k | return GetImportedOrCreateSpecialDecl(ToD, OC, FromD, | 256 | 4.18k | std::forward<Args>(args)...); | 257 | 4.18k | } |
bool clang::ASTNodeImporter::GetImportedOrCreateDecl<clang::NamespaceAliasDecl, clang::NamespaceAliasDecl, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::IdentifierInfo*&, clang::NestedNameSpecifierLoc&, clang::SourceLocation&, clang::NamespaceDecl*&>(clang::NamespaceAliasDecl*&, clang::NamespaceAliasDecl*, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::IdentifierInfo*&, clang::NestedNameSpecifierLoc&, clang::SourceLocation&, clang::NamespaceDecl*&) Line | Count | Source | 250 | 3 | Args &&... args) { | 251 | | // There may be several overloads of ToDeclT::Create. We must make sure | 252 | | // to call the one which would be chosen by the arguments, thus we use a | 253 | | // wrapper for the overload set. | 254 | 3 | CallOverloadedCreateFun<ToDeclT> OC; | 255 | 3 | return GetImportedOrCreateSpecialDecl(ToD, OC, FromD, | 256 | 3 | std::forward<Args>(args)...); | 257 | 3 | } |
bool clang::ASTNodeImporter::GetImportedOrCreateDecl<clang::TypeAliasTemplateDecl, clang::TypeAliasTemplateDecl, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::DeclarationName&, clang::TemplateParameterList*&, clang::TypeAliasDecl*&>(clang::TypeAliasTemplateDecl*&, clang::TypeAliasTemplateDecl*, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::DeclarationName&, clang::TemplateParameterList*&, clang::TypeAliasDecl*&) Line | Count | Source | 250 | 8.58k | Args &&... args) { | 251 | | // There may be several overloads of ToDeclT::Create. We must make sure | 252 | | // to call the one which would be chosen by the arguments, thus we use a | 253 | | // wrapper for the overload set. | 254 | 8.58k | CallOverloadedCreateFun<ToDeclT> OC; | 255 | 8.58k | return GetImportedOrCreateSpecialDecl(ToD, OC, FromD, | 256 | 8.58k | std::forward<Args>(args)...); | 257 | 8.58k | } |
Unexecuted instantiation: bool clang::ASTNodeImporter::GetImportedOrCreateDecl<clang::LabelDecl, clang::LabelDecl, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::IdentifierInfo*, clang::SourceLocation&>(clang::LabelDecl*&, clang::LabelDecl*, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::IdentifierInfo*&&, clang::SourceLocation&) bool clang::ASTNodeImporter::GetImportedOrCreateDecl<clang::LabelDecl, clang::LabelDecl, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::IdentifierInfo*>(clang::LabelDecl*&, clang::LabelDecl*, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::IdentifierInfo*&&) Line | Count | Source | 250 | 258 | Args &&... args) { | 251 | | // There may be several overloads of ToDeclT::Create. We must make sure | 252 | | // to call the one which would be chosen by the arguments, thus we use a | 253 | | // wrapper for the overload set. | 254 | 258 | CallOverloadedCreateFun<ToDeclT> OC; | 255 | 258 | return GetImportedOrCreateSpecialDecl(ToD, OC, FromD, | 256 | 258 | std::forward<Args>(args)...); | 257 | 258 | } |
bool clang::ASTNodeImporter::GetImportedOrCreateDecl<clang::EnumDecl, clang::EnumDecl, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::IdentifierInfo*, clang::EnumDecl*&, bool, bool, bool>(clang::EnumDecl*&, clang::EnumDecl*, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::IdentifierInfo*&&, clang::EnumDecl*&, bool&&, bool&&, bool&&) Line | Count | Source | 250 | 3.09k | Args &&... args) { | 251 | | // There may be several overloads of ToDeclT::Create. We must make sure | 252 | | // to call the one which would be chosen by the arguments, thus we use a | 253 | | // wrapper for the overload set. | 254 | 3.09k | CallOverloadedCreateFun<ToDeclT> OC; | 255 | 3.09k | return GetImportedOrCreateSpecialDecl(ToD, OC, FromD, | 256 | 3.09k | std::forward<Args>(args)...); | 257 | 3.09k | } |
bool clang::ASTNodeImporter::GetImportedOrCreateDecl<clang::CXXRecordDecl, clang::RecordDecl, clang::ASTContext&, clang::TagTypeKind, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::IdentifierInfo*, clang::CXXRecordDecl*, bool const&>(clang::CXXRecordDecl*&, clang::RecordDecl*, clang::ASTContext&, clang::TagTypeKind&&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::IdentifierInfo*&&, clang::CXXRecordDecl*&&, bool const&) Line | Count | Source | 250 | 97.4k | Args &&... args) { | 251 | | // There may be several overloads of ToDeclT::Create. We must make sure | 252 | | // to call the one which would be chosen by the arguments, thus we use a | 253 | | // wrapper for the overload set. | 254 | 97.4k | CallOverloadedCreateFun<ToDeclT> OC; | 255 | 97.4k | return GetImportedOrCreateSpecialDecl(ToD, OC, FromD, | 256 | 97.4k | std::forward<Args>(args)...); | 257 | 97.4k | } |
bool clang::ASTNodeImporter::GetImportedOrCreateDecl<clang::CXXRecordDecl, clang::RecordDecl, clang::ASTContext&, clang::TagTypeKind, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::IdentifierInfo*, clang::CXXRecordDecl*>(clang::CXXRecordDecl*&, clang::RecordDecl*, clang::ASTContext&, clang::TagTypeKind&&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::IdentifierInfo*&&, clang::CXXRecordDecl*&&) Line | Count | Source | 250 | 101k | Args &&... args) { | 251 | | // There may be several overloads of ToDeclT::Create. We must make sure | 252 | | // to call the one which would be chosen by the arguments, thus we use a | 253 | | // wrapper for the overload set. | 254 | 101k | CallOverloadedCreateFun<ToDeclT> OC; | 255 | 101k | return GetImportedOrCreateSpecialDecl(ToD, OC, FromD, | 256 | 101k | std::forward<Args>(args)...); | 257 | 101k | } |
bool clang::ASTNodeImporter::GetImportedOrCreateDecl<clang::RecordDecl, clang::RecordDecl, clang::ASTContext&, clang::TagTypeKind, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::IdentifierInfo*, clang::RecordDecl*&>(clang::RecordDecl*&, clang::RecordDecl*, clang::ASTContext&, clang::TagTypeKind&&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::IdentifierInfo*&&, clang::RecordDecl*&) Line | Count | Source | 250 | 146 | Args &&... args) { | 251 | | // There may be several overloads of ToDeclT::Create. We must make sure | 252 | | // to call the one which would be chosen by the arguments, thus we use a | 253 | | // wrapper for the overload set. | 254 | 146 | CallOverloadedCreateFun<ToDeclT> OC; | 255 | 146 | return GetImportedOrCreateSpecialDecl(ToD, OC, FromD, | 256 | 146 | std::forward<Args>(args)...); | 257 | 146 | } |
bool clang::ASTNodeImporter::GetImportedOrCreateDecl<clang::EnumConstantDecl, clang::EnumConstantDecl, clang::ASTContext&, clang::EnumDecl*, clang::SourceLocation&, clang::IdentifierInfo*, clang::QualType&, clang::Expr*&, llvm::APSInt const&>(clang::EnumConstantDecl*&, clang::EnumConstantDecl*, clang::ASTContext&, clang::EnumDecl*&&, clang::SourceLocation&, clang::IdentifierInfo*&&, clang::QualType&, clang::Expr*&, llvm::APSInt const&) Line | Count | Source | 250 | 9.19k | Args &&... args) { | 251 | | // There may be several overloads of ToDeclT::Create. We must make sure | 252 | | // to call the one which would be chosen by the arguments, thus we use a | 253 | | // wrapper for the overload set. | 254 | 9.19k | CallOverloadedCreateFun<ToDeclT> OC; | 255 | 9.19k | return GetImportedOrCreateSpecialDecl(ToD, OC, FromD, | 256 | 9.19k | std::forward<Args>(args)...); | 257 | 9.19k | } |
bool clang::ASTNodeImporter::GetImportedOrCreateDecl<clang::FunctionDecl, clang::FunctionDecl, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::DeclarationNameInfo&, clang::QualType&, clang::TypeSourceInfo*&, clang::StorageClass, bool, bool, bool, clang::ConstexprSpecKind, clang::Expr*&>(clang::FunctionDecl*&, clang::FunctionDecl*, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::DeclarationNameInfo&, clang::QualType&, clang::TypeSourceInfo*&, clang::StorageClass&&, bool&&, bool&&, bool&&, clang::ConstexprSpecKind&&, clang::Expr*&) Line | Count | Source | 250 | 112k | Args &&... args) { | 251 | | // There may be several overloads of ToDeclT::Create. We must make sure | 252 | | // to call the one which would be chosen by the arguments, thus we use a | 253 | | // wrapper for the overload set. | 254 | 112k | CallOverloadedCreateFun<ToDeclT> OC; | 255 | 112k | return GetImportedOrCreateSpecialDecl(ToD, OC, FromD, | 256 | 112k | std::forward<Args>(args)...); | 257 | 112k | } |
bool clang::ASTNodeImporter::GetImportedOrCreateDecl<clang::FieldDecl, clang::FieldDecl, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::IdentifierInfo*, clang::QualType&, clang::TypeSourceInfo*&, clang::Expr*&, bool, clang::InClassInitStyle>(clang::FieldDecl*&, clang::FieldDecl*, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::IdentifierInfo*&&, clang::QualType&, clang::TypeSourceInfo*&, clang::Expr*&, bool&&, clang::InClassInitStyle&&) Line | Count | Source | 250 | 80.8k | Args &&... args) { | 251 | | // There may be several overloads of ToDeclT::Create. We must make sure | 252 | | // to call the one which would be chosen by the arguments, thus we use a | 253 | | // wrapper for the overload set. | 254 | 80.8k | CallOverloadedCreateFun<ToDeclT> OC; | 255 | 80.8k | return GetImportedOrCreateSpecialDecl(ToD, OC, FromD, | 256 | 80.8k | std::forward<Args>(args)...); | 257 | 80.8k | } |
bool clang::ASTNodeImporter::GetImportedOrCreateDecl<clang::IndirectFieldDecl, clang::IndirectFieldDecl, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::IdentifierInfo*, clang::QualType&, llvm::MutableArrayRef<clang::NamedDecl*>&>(clang::IndirectFieldDecl*&, clang::IndirectFieldDecl*, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::IdentifierInfo*&&, clang::QualType&, llvm::MutableArrayRef<clang::NamedDecl*>&) Line | Count | Source | 250 | 1.45k | Args &&... args) { | 251 | | // There may be several overloads of ToDeclT::Create. We must make sure | 252 | | // to call the one which would be chosen by the arguments, thus we use a | 253 | | // wrapper for the overload set. | 254 | 1.45k | CallOverloadedCreateFun<ToDeclT> OC; | 255 | 1.45k | return GetImportedOrCreateSpecialDecl(ToD, OC, FromD, | 256 | 1.45k | std::forward<Args>(args)...); | 257 | 1.45k | } |
bool clang::ASTNodeImporter::GetImportedOrCreateDecl<clang::FriendDecl, clang::FriendDecl, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, llvm::PointerUnion<clang::NamedDecl*, clang::TypeSourceInfo*>&, clang::SourceLocation&, llvm::SmallVector<clang::TemplateParameterList*, 1u>&>(clang::FriendDecl*&, clang::FriendDecl*, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, llvm::PointerUnion<clang::NamedDecl*, clang::TypeSourceInfo*>&, clang::SourceLocation&, llvm::SmallVector<clang::TemplateParameterList*, 1u>&) Line | Count | Source | 250 | 36.5k | Args &&... args) { | 251 | | // There may be several overloads of ToDeclT::Create. We must make sure | 252 | | // to call the one which would be chosen by the arguments, thus we use a | 253 | | // wrapper for the overload set. | 254 | 36.5k | CallOverloadedCreateFun<ToDeclT> OC; | 255 | 36.5k | return GetImportedOrCreateSpecialDecl(ToD, OC, FromD, | 256 | 36.5k | std::forward<Args>(args)...); | 257 | 36.5k | } |
bool clang::ASTNodeImporter::GetImportedOrCreateDecl<clang::ObjCIvarDecl, clang::ObjCIvarDecl, clang::ASTContext&, clang::ObjCContainerDecl*, clang::SourceLocation&, clang::SourceLocation&, clang::IdentifierInfo*, clang::QualType&, clang::TypeSourceInfo*&, clang::ObjCIvarDecl::AccessControl, clang::Expr*&, bool>(clang::ObjCIvarDecl*&, clang::ObjCIvarDecl*, clang::ASTContext&, clang::ObjCContainerDecl*&&, clang::SourceLocation&, clang::SourceLocation&, clang::IdentifierInfo*&&, clang::QualType&, clang::TypeSourceInfo*&, clang::ObjCIvarDecl::AccessControl&&, clang::Expr*&, bool&&) Line | Count | Source | 250 | 1.63k | Args &&... args) { | 251 | | // There may be several overloads of ToDeclT::Create. We must make sure | 252 | | // to call the one which would be chosen by the arguments, thus we use a | 253 | | // wrapper for the overload set. | 254 | 1.63k | CallOverloadedCreateFun<ToDeclT> OC; | 255 | 1.63k | return GetImportedOrCreateSpecialDecl(ToD, OC, FromD, | 256 | 1.63k | std::forward<Args>(args)...); | 257 | 1.63k | } |
bool clang::ASTNodeImporter::GetImportedOrCreateDecl<clang::DecompositionDecl, clang::DecompositionDecl, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::QualType&, clang::TypeSourceInfo*&, clang::StorageClass, llvm::SmallVector<clang::BindingDecl*, 6u>&>(clang::DecompositionDecl*&, clang::DecompositionDecl*, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::QualType&, clang::TypeSourceInfo*&, clang::StorageClass&&, llvm::SmallVector<clang::BindingDecl*, 6u>&) Line | Count | Source | 250 | 48 | Args &&... args) { | 251 | | // There may be several overloads of ToDeclT::Create. We must make sure | 252 | | // to call the one which would be chosen by the arguments, thus we use a | 253 | | // wrapper for the overload set. | 254 | 48 | CallOverloadedCreateFun<ToDeclT> OC; | 255 | 48 | return GetImportedOrCreateSpecialDecl(ToD, OC, FromD, | 256 | 48 | std::forward<Args>(args)...); | 257 | 48 | } |
bool clang::ASTNodeImporter::GetImportedOrCreateDecl<clang::VarDecl, clang::VarDecl, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::IdentifierInfo*, clang::QualType&, clang::TypeSourceInfo*&, clang::StorageClass>(clang::VarDecl*&, clang::VarDecl*, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::IdentifierInfo*&&, clang::QualType&, clang::TypeSourceInfo*&, clang::StorageClass&&) Line | Count | Source | 250 | 253k | Args &&... args) { | 251 | | // There may be several overloads of ToDeclT::Create. We must make sure | 252 | | // to call the one which would be chosen by the arguments, thus we use a | 253 | | // wrapper for the overload set. | 254 | 253k | CallOverloadedCreateFun<ToDeclT> OC; | 255 | 253k | return GetImportedOrCreateSpecialDecl(ToD, OC, FromD, | 256 | 253k | std::forward<Args>(args)...); | 257 | 253k | } |
Unexecuted instantiation: bool clang::ASTNodeImporter::GetImportedOrCreateDecl<clang::ImplicitParamDecl, clang::ImplicitParamDecl, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::IdentifierInfo*, clang::QualType&, clang::ImplicitParamDecl::ImplicitParamKind>(clang::ImplicitParamDecl*&, clang::ImplicitParamDecl*, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::IdentifierInfo*&&, clang::QualType&, clang::ImplicitParamDecl::ImplicitParamKind&&) bool clang::ASTNodeImporter::GetImportedOrCreateDecl<clang::ParmVarDecl, clang::ParmVarDecl, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::IdentifierInfo*, clang::QualType&, clang::TypeSourceInfo*&, clang::StorageClass, std::nullptr_t>(clang::ParmVarDecl*&, clang::ParmVarDecl*, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::IdentifierInfo*&&, clang::QualType&, clang::TypeSourceInfo*&, clang::StorageClass&&, std::nullptr_t&&) Line | Count | Source | 250 | 1.22M | Args &&... args) { | 251 | | // There may be several overloads of ToDeclT::Create. We must make sure | 252 | | // to call the one which would be chosen by the arguments, thus we use a | 253 | | // wrapper for the overload set. | 254 | 1.22M | CallOverloadedCreateFun<ToDeclT> OC; | 255 | 1.22M | return GetImportedOrCreateSpecialDecl(ToD, OC, FromD, | 256 | 1.22M | std::forward<Args>(args)...); | 257 | 1.22M | } |
bool clang::ASTNodeImporter::GetImportedOrCreateDecl<clang::ObjCMethodDecl, clang::ObjCMethodDecl, clang::ASTContext&, clang::SourceLocation&, clang::SourceLocation&, clang::Selector, clang::QualType&, clang::TypeSourceInfo*&, clang::DeclContext*&, bool, bool, bool, bool, bool, bool, clang::ObjCMethodDecl::ImplementationControl, bool>(clang::ObjCMethodDecl*&, clang::ObjCMethodDecl*, clang::ASTContext&, clang::SourceLocation&, clang::SourceLocation&, clang::Selector&&, clang::QualType&, clang::TypeSourceInfo*&, clang::DeclContext*&, bool&&, bool&&, bool&&, bool&&, bool&&, bool&&, clang::ObjCMethodDecl::ImplementationControl&&, bool&&) Line | Count | Source | 250 | 8.63k | Args &&... args) { | 251 | | // There may be several overloads of ToDeclT::Create. We must make sure | 252 | | // to call the one which would be chosen by the arguments, thus we use a | 253 | | // wrapper for the overload set. | 254 | 8.63k | CallOverloadedCreateFun<ToDeclT> OC; | 255 | 8.63k | return GetImportedOrCreateSpecialDecl(ToD, OC, FromD, | 256 | 8.63k | std::forward<Args>(args)...); | 257 | 8.63k | } |
bool clang::ASTNodeImporter::GetImportedOrCreateDecl<clang::ObjCTypeParamDecl, clang::ObjCTypeParamDecl, clang::ASTContext&, clang::DeclContext*&, clang::ObjCTypeParamVariance, clang::SourceLocation&, unsigned int, clang::SourceLocation&, clang::IdentifierInfo*, clang::SourceLocation&, clang::TypeSourceInfo*&>(clang::ObjCTypeParamDecl*&, clang::ObjCTypeParamDecl*, clang::ASTContext&, clang::DeclContext*&, clang::ObjCTypeParamVariance&&, clang::SourceLocation&, unsigned int&&, clang::SourceLocation&, clang::IdentifierInfo*&&, clang::SourceLocation&, clang::TypeSourceInfo*&) Line | Count | Source | 250 | 390 | Args &&... args) { | 251 | | // There may be several overloads of ToDeclT::Create. We must make sure | 252 | | // to call the one which would be chosen by the arguments, thus we use a | 253 | | // wrapper for the overload set. | 254 | 390 | CallOverloadedCreateFun<ToDeclT> OC; | 255 | 390 | return GetImportedOrCreateSpecialDecl(ToD, OC, FromD, | 256 | 390 | std::forward<Args>(args)...); | 257 | 390 | } |
bool clang::ASTNodeImporter::GetImportedOrCreateDecl<clang::ObjCCategoryDecl, clang::ObjCCategoryDecl, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::SourceLocation&, clang::IdentifierInfo*, clang::ObjCInterfaceDecl*&, std::nullptr_t, clang::SourceLocation&, clang::SourceLocation&>(clang::ObjCCategoryDecl*&, clang::ObjCCategoryDecl*, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::SourceLocation&, clang::IdentifierInfo*&&, clang::ObjCInterfaceDecl*&, std::nullptr_t&&, clang::SourceLocation&, clang::SourceLocation&) Line | Count | Source | 250 | 2.44k | Args &&... args) { | 251 | | // There may be several overloads of ToDeclT::Create. We must make sure | 252 | | // to call the one which would be chosen by the arguments, thus we use a | 253 | | // wrapper for the overload set. | 254 | 2.44k | CallOverloadedCreateFun<ToDeclT> OC; | 255 | 2.44k | return GetImportedOrCreateSpecialDecl(ToD, OC, FromD, | 256 | 2.44k | std::forward<Args>(args)...); | 257 | 2.44k | } |
bool clang::ASTNodeImporter::GetImportedOrCreateDecl<clang::ObjCProtocolDecl, clang::ObjCProtocolDecl, clang::ASTContext&, clang::DeclContext*&, clang::IdentifierInfo*, clang::SourceLocation&, clang::SourceLocation&, std::nullptr_t>(clang::ObjCProtocolDecl*&, clang::ObjCProtocolDecl*, clang::ASTContext&, clang::DeclContext*&, clang::IdentifierInfo*&&, clang::SourceLocation&, clang::SourceLocation&, std::nullptr_t&&) Line | Count | Source | 250 | 375 | Args &&... args) { | 251 | | // There may be several overloads of ToDeclT::Create. We must make sure | 252 | | // to call the one which would be chosen by the arguments, thus we use a | 253 | | // wrapper for the overload set. | 254 | 375 | CallOverloadedCreateFun<ToDeclT> OC; | 255 | 375 | return GetImportedOrCreateSpecialDecl(ToD, OC, FromD, | 256 | 375 | std::forward<Args>(args)...); | 257 | 375 | } |
bool clang::ASTNodeImporter::GetImportedOrCreateDecl<clang::LinkageSpecDecl, clang::LinkageSpecDecl, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::LinkageSpecDecl::LanguageIDs, bool&>(clang::LinkageSpecDecl*&, clang::LinkageSpecDecl*, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::LinkageSpecDecl::LanguageIDs&&, bool&) Line | Count | Source | 250 | 6.51k | Args &&... args) { | 251 | | // There may be several overloads of ToDeclT::Create. We must make sure | 252 | | // to call the one which would be chosen by the arguments, thus we use a | 253 | | // wrapper for the overload set. | 254 | 6.51k | CallOverloadedCreateFun<ToDeclT> OC; | 255 | 6.51k | return GetImportedOrCreateSpecialDecl(ToD, OC, FromD, | 256 | 6.51k | std::forward<Args>(args)...); | 257 | 6.51k | } |
bool clang::ASTNodeImporter::GetImportedOrCreateDecl<clang::UsingDecl, clang::UsingDecl, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::NestedNameSpecifierLoc&, clang::DeclarationNameInfo&, bool>(clang::UsingDecl*&, clang::UsingDecl*, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::NestedNameSpecifierLoc&, clang::DeclarationNameInfo&, bool&&) Line | Count | Source | 250 | 5.79k | Args &&... args) { | 251 | | // There may be several overloads of ToDeclT::Create. We must make sure | 252 | | // to call the one which would be chosen by the arguments, thus we use a | 253 | | // wrapper for the overload set. | 254 | 5.79k | CallOverloadedCreateFun<ToDeclT> OC; | 255 | 5.79k | return GetImportedOrCreateSpecialDecl(ToD, OC, FromD, | 256 | 5.79k | std::forward<Args>(args)...); | 257 | 5.79k | } |
bool clang::ASTNodeImporter::GetImportedOrCreateDecl<clang::UsingEnumDecl, clang::UsingEnumDecl, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::SourceLocation&, clang::EnumDecl*&>(clang::UsingEnumDecl*&, clang::UsingEnumDecl*, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::SourceLocation&, clang::EnumDecl*&) Line | Count | Source | 250 | 8 | Args &&... args) { | 251 | | // There may be several overloads of ToDeclT::Create. We must make sure | 252 | | // to call the one which would be chosen by the arguments, thus we use a | 253 | | // wrapper for the overload set. | 254 | 8 | CallOverloadedCreateFun<ToDeclT> OC; | 255 | 8 | return GetImportedOrCreateSpecialDecl(ToD, OC, FromD, | 256 | 8 | std::forward<Args>(args)...); | 257 | 8 | } |
bool clang::ASTNodeImporter::GetImportedOrCreateDecl<clang::UsingShadowDecl, clang::UsingShadowDecl, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::DeclarationName&, clang::BaseUsingDecl*&, clang::NamedDecl*&>(clang::UsingShadowDecl*&, clang::UsingShadowDecl*, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::DeclarationName&, clang::BaseUsingDecl*&, clang::NamedDecl*&) Line | Count | Source | 250 | 45.6k | Args &&... args) { | 251 | | // There may be several overloads of ToDeclT::Create. We must make sure | 252 | | // to call the one which would be chosen by the arguments, thus we use a | 253 | | // wrapper for the overload set. | 254 | 45.6k | CallOverloadedCreateFun<ToDeclT> OC; | 255 | 45.6k | return GetImportedOrCreateSpecialDecl(ToD, OC, FromD, | 256 | 45.6k | std::forward<Args>(args)...); | 257 | 45.6k | } |
bool clang::ASTNodeImporter::GetImportedOrCreateDecl<clang::UsingDirectiveDecl, clang::UsingDirectiveDecl, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::NestedNameSpecifierLoc&, clang::SourceLocation&, clang::NamespaceDecl*&, clang::DeclContext*&>(clang::UsingDirectiveDecl*&, clang::UsingDirectiveDecl*, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::NestedNameSpecifierLoc&, clang::SourceLocation&, clang::NamespaceDecl*&, clang::DeclContext*&) Line | Count | Source | 250 | 269 | Args &&... args) { | 251 | | // There may be several overloads of ToDeclT::Create. We must make sure | 252 | | // to call the one which would be chosen by the arguments, thus we use a | 253 | | // wrapper for the overload set. | 254 | 269 | CallOverloadedCreateFun<ToDeclT> OC; | 255 | 269 | return GetImportedOrCreateSpecialDecl(ToD, OC, FromD, | 256 | 269 | std::forward<Args>(args)...); | 257 | 269 | } |
bool clang::ASTNodeImporter::GetImportedOrCreateDecl<clang::UnresolvedUsingValueDecl, clang::UnresolvedUsingValueDecl, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::NestedNameSpecifierLoc&, clang::DeclarationNameInfo&, clang::SourceLocation&>(clang::UnresolvedUsingValueDecl*&, clang::UnresolvedUsingValueDecl*, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::NestedNameSpecifierLoc&, clang::DeclarationNameInfo&, clang::SourceLocation&) Line | Count | Source | 250 | 2 | Args &&... args) { | 251 | | // There may be several overloads of ToDeclT::Create. We must make sure | 252 | | // to call the one which would be chosen by the arguments, thus we use a | 253 | | // wrapper for the overload set. | 254 | 2 | CallOverloadedCreateFun<ToDeclT> OC; | 255 | 2 | return GetImportedOrCreateSpecialDecl(ToD, OC, FromD, | 256 | 2 | std::forward<Args>(args)...); | 257 | 2 | } |
bool clang::ASTNodeImporter::GetImportedOrCreateDecl<clang::UnresolvedUsingTypenameDecl, clang::UnresolvedUsingTypenameDecl, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::NestedNameSpecifierLoc&, clang::SourceLocation&, clang::DeclarationName&, clang::SourceLocation&>(clang::UnresolvedUsingTypenameDecl*&, clang::UnresolvedUsingTypenameDecl*, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::NestedNameSpecifierLoc&, clang::SourceLocation&, clang::DeclarationName&, clang::SourceLocation&) Line | Count | Source | 250 | 280 | Args &&... args) { | 251 | | // There may be several overloads of ToDeclT::Create. We must make sure | 252 | | // to call the one which would be chosen by the arguments, thus we use a | 253 | | // wrapper for the overload set. | 254 | 280 | CallOverloadedCreateFun<ToDeclT> OC; | 255 | 280 | return GetImportedOrCreateSpecialDecl(ToD, OC, FromD, | 256 | 280 | std::forward<Args>(args)...); | 257 | 280 | } |
bool clang::ASTNodeImporter::GetImportedOrCreateDecl<clang::ObjCInterfaceDecl, clang::ObjCInterfaceDecl, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::IdentifierInfo*, std::nullptr_t, std::nullptr_t, clang::SourceLocation&, bool>(clang::ObjCInterfaceDecl*&, clang::ObjCInterfaceDecl*, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::IdentifierInfo*&&, std::nullptr_t&&, std::nullptr_t&&, clang::SourceLocation&, bool&&) Line | Count | Source | 250 | 2.32k | Args &&... args) { | 251 | | // There may be several overloads of ToDeclT::Create. We must make sure | 252 | | // to call the one which would be chosen by the arguments, thus we use a | 253 | | // wrapper for the overload set. | 254 | 2.32k | CallOverloadedCreateFun<ToDeclT> OC; | 255 | 2.32k | return GetImportedOrCreateSpecialDecl(ToD, OC, FromD, | 256 | 2.32k | std::forward<Args>(args)...); | 257 | 2.32k | } |
bool clang::ASTNodeImporter::GetImportedOrCreateDecl<clang::ObjCCategoryImplDecl, clang::ObjCCategoryImplDecl, clang::ASTContext&, clang::DeclContext*&, clang::IdentifierInfo*, clang::ObjCInterfaceDecl*, clang::SourceLocation&, clang::SourceLocation&, clang::SourceLocation&>(clang::ObjCCategoryImplDecl*&, clang::ObjCCategoryImplDecl*, clang::ASTContext&, clang::DeclContext*&, clang::IdentifierInfo*&&, clang::ObjCInterfaceDecl*&&, clang::SourceLocation&, clang::SourceLocation&, clang::SourceLocation&) Line | Count | Source | 250 | 4 | Args &&... args) { | 251 | | // There may be several overloads of ToDeclT::Create. We must make sure | 252 | | // to call the one which would be chosen by the arguments, thus we use a | 253 | | // wrapper for the overload set. | 254 | 4 | CallOverloadedCreateFun<ToDeclT> OC; | 255 | 4 | return GetImportedOrCreateSpecialDecl(ToD, OC, FromD, | 256 | 4 | std::forward<Args>(args)...); | 257 | 4 | } |
bool clang::ASTNodeImporter::GetImportedOrCreateDecl<clang::ObjCImplementationDecl, clang::ObjCImplementationDecl, clang::ASTContext&, clang::DeclContext*&, clang::ObjCInterfaceDecl*&, clang::ObjCInterfaceDecl*&, clang::SourceLocation&, clang::SourceLocation&, clang::SourceLocation&, clang::SourceLocation&, clang::SourceLocation&>(clang::ObjCImplementationDecl*&, clang::ObjCImplementationDecl*, clang::ASTContext&, clang::DeclContext*&, clang::ObjCInterfaceDecl*&, clang::ObjCInterfaceDecl*&, clang::SourceLocation&, clang::SourceLocation&, clang::SourceLocation&, clang::SourceLocation&, clang::SourceLocation&) Line | Count | Source | 250 | 8 | Args &&... args) { | 251 | | // There may be several overloads of ToDeclT::Create. We must make sure | 252 | | // to call the one which would be chosen by the arguments, thus we use a | 253 | | // wrapper for the overload set. | 254 | 8 | CallOverloadedCreateFun<ToDeclT> OC; | 255 | 8 | return GetImportedOrCreateSpecialDecl(ToD, OC, FromD, | 256 | 8 | std::forward<Args>(args)...); | 257 | 8 | } |
bool clang::ASTNodeImporter::GetImportedOrCreateDecl<clang::ObjCPropertyDecl, clang::ObjCPropertyDecl, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::IdentifierInfo*, clang::SourceLocation&, clang::SourceLocation&, clang::QualType&, clang::TypeSourceInfo*&, clang::ObjCPropertyDecl::PropertyControl>(clang::ObjCPropertyDecl*&, clang::ObjCPropertyDecl*, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::IdentifierInfo*&&, clang::SourceLocation&, clang::SourceLocation&, clang::QualType&, clang::TypeSourceInfo*&, clang::ObjCPropertyDecl::PropertyControl&&) Line | Count | Source | 250 | 2.31k | Args &&... args) { | 251 | | // There may be several overloads of ToDeclT::Create. We must make sure | 252 | | // to call the one which would be chosen by the arguments, thus we use a | 253 | | // wrapper for the overload set. | 254 | 2.31k | CallOverloadedCreateFun<ToDeclT> OC; | 255 | 2.31k | return GetImportedOrCreateSpecialDecl(ToD, OC, FromD, | 256 | 2.31k | std::forward<Args>(args)...); | 257 | 2.31k | } |
bool clang::ASTNodeImporter::GetImportedOrCreateDecl<clang::ObjCPropertyImplDecl, clang::ObjCPropertyImplDecl, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::ObjCPropertyDecl*&, clang::ObjCPropertyImplDecl::Kind, clang::ObjCIvarDecl*&, clang::SourceLocation&>(clang::ObjCPropertyImplDecl*&, clang::ObjCPropertyImplDecl*, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::ObjCPropertyDecl*&, clang::ObjCPropertyImplDecl::Kind&&, clang::ObjCIvarDecl*&, clang::SourceLocation&) Line | Count | Source | 250 | 4 | Args &&... args) { | 251 | | // There may be several overloads of ToDeclT::Create. We must make sure | 252 | | // to call the one which would be chosen by the arguments, thus we use a | 253 | | // wrapper for the overload set. | 254 | 4 | CallOverloadedCreateFun<ToDeclT> OC; | 255 | 4 | return GetImportedOrCreateSpecialDecl(ToD, OC, FromD, | 256 | 4 | std::forward<Args>(args)...); | 257 | 4 | } |
bool clang::ASTNodeImporter::GetImportedOrCreateDecl<clang::TemplateTypeParmDecl, clang::TemplateTypeParmDecl, clang::ASTContext&, clang::TranslationUnitDecl*, clang::SourceLocation&, clang::SourceLocation&, unsigned int, unsigned int, clang::IdentifierInfo*, bool, bool, bool>(clang::TemplateTypeParmDecl*&, clang::TemplateTypeParmDecl*, clang::ASTContext&, clang::TranslationUnitDecl*&&, clang::SourceLocation&, clang::SourceLocation&, unsigned int&&, unsigned int&&, clang::IdentifierInfo*&&, bool&&, bool&&, bool&&) Line | Count | Source | 250 | 626k | Args &&... args) { | 251 | | // There may be several overloads of ToDeclT::Create. We must make sure | 252 | | // to call the one which would be chosen by the arguments, thus we use a | 253 | | // wrapper for the overload set. | 254 | 626k | CallOverloadedCreateFun<ToDeclT> OC; | 255 | 626k | return GetImportedOrCreateSpecialDecl(ToD, OC, FromD, | 256 | 626k | std::forward<Args>(args)...); | 257 | 626k | } |
bool clang::ASTNodeImporter::GetImportedOrCreateDecl<clang::NonTypeTemplateParmDecl, clang::NonTypeTemplateParmDecl, clang::ASTContext&, clang::TranslationUnitDecl*, clang::SourceLocation&, clang::SourceLocation&, unsigned int, unsigned int, clang::IdentifierInfo*, clang::QualType&, bool, clang::TypeSourceInfo*&>(clang::NonTypeTemplateParmDecl*&, clang::NonTypeTemplateParmDecl*, clang::ASTContext&, clang::TranslationUnitDecl*&&, clang::SourceLocation&, clang::SourceLocation&, unsigned int&&, unsigned int&&, clang::IdentifierInfo*&&, clang::QualType&, bool&&, clang::TypeSourceInfo*&) Line | Count | Source | 250 | 93.3k | Args &&... args) { | 251 | | // There may be several overloads of ToDeclT::Create. We must make sure | 252 | | // to call the one which would be chosen by the arguments, thus we use a | 253 | | // wrapper for the overload set. | 254 | 93.3k | CallOverloadedCreateFun<ToDeclT> OC; | 255 | 93.3k | return GetImportedOrCreateSpecialDecl(ToD, OC, FromD, | 256 | 93.3k | std::forward<Args>(args)...); | 257 | 93.3k | } |
bool clang::ASTNodeImporter::GetImportedOrCreateDecl<clang::TemplateTemplateParmDecl, clang::TemplateTemplateParmDecl, clang::ASTContext&, clang::TranslationUnitDecl*, clang::SourceLocation&, unsigned int, unsigned int, bool, clang::IdentifierInfo*, clang::TemplateParameterList*&>(clang::TemplateTemplateParmDecl*&, clang::TemplateTemplateParmDecl*, clang::ASTContext&, clang::TranslationUnitDecl*&&, clang::SourceLocation&, unsigned int&&, unsigned int&&, bool&&, clang::IdentifierInfo*&&, clang::TemplateParameterList*&) Line | Count | Source | 250 | 1.77k | Args &&... args) { | 251 | | // There may be several overloads of ToDeclT::Create. We must make sure | 252 | | // to call the one which would be chosen by the arguments, thus we use a | 253 | | // wrapper for the overload set. | 254 | 1.77k | CallOverloadedCreateFun<ToDeclT> OC; | 255 | 1.77k | return GetImportedOrCreateSpecialDecl(ToD, OC, FromD, | 256 | 1.77k | std::forward<Args>(args)...); | 257 | 1.77k | } |
bool clang::ASTNodeImporter::GetImportedOrCreateDecl<clang::ClassTemplateDecl, clang::ClassTemplateDecl, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::DeclarationName&, clang::TemplateParameterList*&, clang::CXXRecordDecl*&>(clang::ClassTemplateDecl*&, clang::ClassTemplateDecl*, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::DeclarationName&, clang::TemplateParameterList*&, clang::CXXRecordDecl*&) Line | Count | Source | 250 | 148k | Args &&... args) { | 251 | | // There may be several overloads of ToDeclT::Create. We must make sure | 252 | | // to call the one which would be chosen by the arguments, thus we use a | 253 | | // wrapper for the overload set. | 254 | 148k | CallOverloadedCreateFun<ToDeclT> OC; | 255 | 148k | return GetImportedOrCreateSpecialDecl(ToD, OC, FromD, | 256 | 148k | std::forward<Args>(args)...); | 257 | 148k | } |
bool clang::ASTNodeImporter::GetImportedOrCreateDecl<clang::ClassTemplateSpecializationDecl, clang::ClassTemplateSpecializationDecl, clang::ASTContext&, clang::TagTypeKind, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::ClassTemplateDecl*&, llvm::SmallVector<clang::TemplateArgument, 2u>&, clang::ClassTemplateSpecializationDecl*&>(clang::ClassTemplateSpecializationDecl*&, clang::ClassTemplateSpecializationDecl*, clang::ASTContext&, clang::TagTypeKind&&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::ClassTemplateDecl*&, llvm::SmallVector<clang::TemplateArgument, 2u>&, clang::ClassTemplateSpecializationDecl*&) Line | Count | Source | 250 | 91.0k | Args &&... args) { | 251 | | // There may be several overloads of ToDeclT::Create. We must make sure | 252 | | // to call the one which would be chosen by the arguments, thus we use a | 253 | | // wrapper for the overload set. | 254 | 91.0k | CallOverloadedCreateFun<ToDeclT> OC; | 255 | 91.0k | return GetImportedOrCreateSpecialDecl(ToD, OC, FromD, | 256 | 91.0k | std::forward<Args>(args)...); | 257 | 91.0k | } |
bool clang::ASTNodeImporter::GetImportedOrCreateDecl<clang::VarTemplateDecl, clang::VarTemplateDecl, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::DeclarationName&, clang::TemplateParameterList*&, clang::VarDecl*&>(clang::VarTemplateDecl*&, clang::VarTemplateDecl*, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::DeclarationName&, clang::TemplateParameterList*&, clang::VarDecl*&) Line | Count | Source | 250 | 414 | Args &&... args) { | 251 | | // There may be several overloads of ToDeclT::Create. We must make sure | 252 | | // to call the one which would be chosen by the arguments, thus we use a | 253 | | // wrapper for the overload set. | 254 | 414 | CallOverloadedCreateFun<ToDeclT> OC; | 255 | 414 | return GetImportedOrCreateSpecialDecl(ToD, OC, FromD, | 256 | 414 | std::forward<Args>(args)...); | 257 | 414 | } |
bool clang::ASTNodeImporter::GetImportedOrCreateDecl<clang::VarTemplatePartialSpecializationDecl, clang::VarTemplateSpecializationDecl, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::TemplateParameterList*&, clang::VarTemplateDecl*&, clang::QualType&, clang::TypeSourceInfo*&, clang::StorageClass, llvm::SmallVector<clang::TemplateArgument, 2u>&, clang::TemplateArgumentListInfo&>(clang::VarTemplatePartialSpecializationDecl*&, clang::VarTemplateSpecializationDecl*, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::TemplateParameterList*&, clang::VarTemplateDecl*&, clang::QualType&, clang::TypeSourceInfo*&, clang::StorageClass&&, llvm::SmallVector<clang::TemplateArgument, 2u>&, clang::TemplateArgumentListInfo&) Line | Count | Source | 250 | 10 | Args &&... args) { | 251 | | // There may be several overloads of ToDeclT::Create. We must make sure | 252 | | // to call the one which would be chosen by the arguments, thus we use a | 253 | | // wrapper for the overload set. | 254 | 10 | CallOverloadedCreateFun<ToDeclT> OC; | 255 | 10 | return GetImportedOrCreateSpecialDecl(ToD, OC, FromD, | 256 | 10 | std::forward<Args>(args)...); | 257 | 10 | } |
bool clang::ASTNodeImporter::GetImportedOrCreateDecl<clang::VarTemplateSpecializationDecl, clang::VarTemplateSpecializationDecl, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::VarTemplateDecl*&, clang::QualType&, clang::TypeSourceInfo*&, clang::StorageClass, llvm::SmallVector<clang::TemplateArgument, 2u>&>(clang::VarTemplateSpecializationDecl*&, clang::VarTemplateSpecializationDecl*, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::VarTemplateDecl*&, clang::QualType&, clang::TypeSourceInfo*&, clang::StorageClass&&, llvm::SmallVector<clang::TemplateArgument, 2u>&) Line | Count | Source | 250 | 11 | Args &&... args) { | 251 | | // There may be several overloads of ToDeclT::Create. We must make sure | 252 | | // to call the one which would be chosen by the arguments, thus we use a | 253 | | // wrapper for the overload set. | 254 | 11 | CallOverloadedCreateFun<ToDeclT> OC; | 255 | 11 | return GetImportedOrCreateSpecialDecl(ToD, OC, FromD, | 256 | 11 | std::forward<Args>(args)...); | 257 | 11 | } |
bool clang::ASTNodeImporter::GetImportedOrCreateDecl<clang::FunctionTemplateDecl, clang::FunctionTemplateDecl, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::DeclarationName&, clang::TemplateParameterList*&, clang::FunctionDecl*&>(clang::FunctionTemplateDecl*&, clang::FunctionTemplateDecl*, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::DeclarationName&, clang::TemplateParameterList*&, clang::FunctionDecl*&) Line | Count | Source | 250 | 345k | Args &&... args) { | 251 | | // There may be several overloads of ToDeclT::Create. We must make sure | 252 | | // to call the one which would be chosen by the arguments, thus we use a | 253 | | // wrapper for the overload set. | 254 | 345k | CallOverloadedCreateFun<ToDeclT> OC; | 255 | 345k | return GetImportedOrCreateSpecialDecl(ToD, OC, FromD, | 256 | 345k | std::forward<Args>(args)...); | 257 | 345k | } |
bool clang::ASTNodeImporter::GetImportedOrCreateDecl<clang::LifetimeExtendedTemporaryDecl, clang::LifetimeExtendedTemporaryDecl, clang::Expr*&, clang::ValueDecl*&, unsigned int>(clang::LifetimeExtendedTemporaryDecl*&, clang::LifetimeExtendedTemporaryDecl*, clang::Expr*&, clang::ValueDecl*&, unsigned int&&) Line | Count | Source | 250 | 2 | Args &&... args) { | 251 | | // There may be several overloads of ToDeclT::Create. We must make sure | 252 | | // to call the one which would be chosen by the arguments, thus we use a | 253 | | // wrapper for the overload set. | 254 | 2 | CallOverloadedCreateFun<ToDeclT> OC; | 255 | 2 | return GetImportedOrCreateSpecialDecl(ToD, OC, FromD, | 256 | 2 | std::forward<Args>(args)...); | 257 | 2 | } |
|
258 | | // Use this overload if a special Type is needed to be created. E.g if we |
259 | | // want to create a `TypeAliasDecl` and assign that to a `TypedefNameDecl` |
260 | | // then: |
261 | | // TypedefNameDecl *ToTypedef; |
262 | | // GetImportedOrCreateDecl<TypeAliasDecl>(ToTypedef, FromD, ...); |
263 | | template <typename NewDeclT, typename ToDeclT, typename FromDeclT, |
264 | | typename... Args> |
265 | | LLVM_NODISCARD bool GetImportedOrCreateDecl(ToDeclT *&ToD, FromDeclT *FromD, |
266 | 1.21M | Args &&... args) { |
267 | 1.21M | CallOverloadedCreateFun<NewDeclT> OC; |
268 | 1.21M | return GetImportedOrCreateSpecialDecl(ToD, OC, FromD, |
269 | 1.21M | std::forward<Args>(args)...); |
270 | 1.21M | } bool clang::ASTNodeImporter::GetImportedOrCreateDecl<clang::TypeAliasDecl, clang::TypedefNameDecl, clang::TypedefNameDecl, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::IdentifierInfo*, clang::TypeSourceInfo*&>(clang::TypedefNameDecl*&, clang::TypedefNameDecl*, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::IdentifierInfo*&&, clang::TypeSourceInfo*&) Line | Count | Source | 266 | 35.4k | Args &&... args) { | 267 | 35.4k | CallOverloadedCreateFun<NewDeclT> OC; | 268 | 35.4k | return GetImportedOrCreateSpecialDecl(ToD, OC, FromD, | 269 | 35.4k | std::forward<Args>(args)...); | 270 | 35.4k | } |
bool clang::ASTNodeImporter::GetImportedOrCreateDecl<clang::TypedefDecl, clang::TypedefNameDecl, clang::TypedefNameDecl, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::IdentifierInfo*, clang::TypeSourceInfo*&>(clang::TypedefNameDecl*&, clang::TypedefNameDecl*, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::IdentifierInfo*&&, clang::TypeSourceInfo*&) Line | Count | Source | 266 | 253k | Args &&... args) { | 267 | 253k | CallOverloadedCreateFun<NewDeclT> OC; | 268 | 253k | return GetImportedOrCreateSpecialDecl(ToD, OC, FromD, | 269 | 253k | std::forward<Args>(args)...); | 270 | 253k | } |
bool clang::ASTNodeImporter::GetImportedOrCreateDecl<clang::CXXConstructorDecl, clang::FunctionDecl, clang::FunctionDecl, clang::ASTContext&, clang::CXXRecordDecl*, clang::SourceLocation&, clang::DeclarationNameInfo&, clang::QualType&, clang::TypeSourceInfo*&, clang::ExplicitSpecifier&, bool, bool, bool, clang::ConstexprSpecKind, clang::InheritedConstructor&, clang::Expr*&>(clang::FunctionDecl*&, clang::FunctionDecl*, clang::ASTContext&, clang::CXXRecordDecl*&&, clang::SourceLocation&, clang::DeclarationNameInfo&, clang::QualType&, clang::TypeSourceInfo*&, clang::ExplicitSpecifier&, bool&&, bool&&, bool&&, clang::ConstexprSpecKind&&, clang::InheritedConstructor&, clang::Expr*&) Line | Count | Source | 266 | 191k | Args &&... args) { | 267 | 191k | CallOverloadedCreateFun<NewDeclT> OC; | 268 | 191k | return GetImportedOrCreateSpecialDecl(ToD, OC, FromD, | 269 | 191k | std::forward<Args>(args)...); | 270 | 191k | } |
bool clang::ASTNodeImporter::GetImportedOrCreateDecl<clang::CXXDestructorDecl, clang::FunctionDecl, clang::FunctionDecl, clang::ASTContext&, clang::CXXRecordDecl*, clang::SourceLocation&, clang::DeclarationNameInfo&, clang::QualType&, clang::TypeSourceInfo*&, bool, bool, bool, clang::ConstexprSpecKind, clang::Expr*&>(clang::FunctionDecl*&, clang::FunctionDecl*, clang::ASTContext&, clang::CXXRecordDecl*&&, clang::SourceLocation&, clang::DeclarationNameInfo&, clang::QualType&, clang::TypeSourceInfo*&, bool&&, bool&&, bool&&, clang::ConstexprSpecKind&&, clang::Expr*&) Line | Count | Source | 266 | 21.1k | Args &&... args) { | 267 | 21.1k | CallOverloadedCreateFun<NewDeclT> OC; | 268 | 21.1k | return GetImportedOrCreateSpecialDecl(ToD, OC, FromD, | 269 | 21.1k | std::forward<Args>(args)...); | 270 | 21.1k | } |
bool clang::ASTNodeImporter::GetImportedOrCreateDecl<clang::CXXConversionDecl, clang::FunctionDecl, clang::FunctionDecl, clang::ASTContext&, clang::CXXRecordDecl*, clang::SourceLocation&, clang::DeclarationNameInfo&, clang::QualType&, clang::TypeSourceInfo*&, bool, bool, clang::ExplicitSpecifier&, clang::ConstexprSpecKind, clang::SourceLocation, clang::Expr*&>(clang::FunctionDecl*&, clang::FunctionDecl*, clang::ASTContext&, clang::CXXRecordDecl*&&, clang::SourceLocation&, clang::DeclarationNameInfo&, clang::QualType&, clang::TypeSourceInfo*&, bool&&, bool&&, clang::ExplicitSpecifier&, clang::ConstexprSpecKind&&, clang::SourceLocation&&, clang::Expr*&) Line | Count | Source | 266 | 3.54k | Args &&... args) { | 267 | 3.54k | CallOverloadedCreateFun<NewDeclT> OC; | 268 | 3.54k | return GetImportedOrCreateSpecialDecl(ToD, OC, FromD, | 269 | 3.54k | std::forward<Args>(args)...); | 270 | 3.54k | } |
bool clang::ASTNodeImporter::GetImportedOrCreateDecl<clang::CXXMethodDecl, clang::FunctionDecl, clang::FunctionDecl, clang::ASTContext&, clang::CXXRecordDecl*, clang::SourceLocation&, clang::DeclarationNameInfo&, clang::QualType&, clang::TypeSourceInfo*&, clang::StorageClass, bool, bool, clang::ConstexprSpecKind, clang::SourceLocation, clang::Expr*&>(clang::FunctionDecl*&, clang::FunctionDecl*, clang::ASTContext&, clang::CXXRecordDecl*&&, clang::SourceLocation&, clang::DeclarationNameInfo&, clang::QualType&, clang::TypeSourceInfo*&, clang::StorageClass&&, bool&&, bool&&, clang::ConstexprSpecKind&&, clang::SourceLocation&&, clang::Expr*&) Line | Count | Source | 266 | 709k | Args &&... args) { | 267 | 709k | CallOverloadedCreateFun<NewDeclT> OC; | 268 | 709k | return GetImportedOrCreateSpecialDecl(ToD, OC, FromD, | 269 | 709k | std::forward<Args>(args)...); | 270 | 709k | } |
bool clang::ASTNodeImporter::GetImportedOrCreateDecl<clang::CXXDeductionGuideDecl, clang::FunctionDecl, clang::FunctionDecl, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::ExplicitSpecifier&, clang::DeclarationNameInfo&, clang::QualType&, clang::TypeSourceInfo*&, clang::SourceLocation&, clang::CXXConstructorDecl*&>(clang::FunctionDecl*&, clang::FunctionDecl*, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::ExplicitSpecifier&, clang::DeclarationNameInfo&, clang::QualType&, clang::TypeSourceInfo*&, clang::SourceLocation&, clang::CXXConstructorDecl*&) Line | Count | Source | 266 | 48 | Args &&... args) { | 267 | 48 | CallOverloadedCreateFun<NewDeclT> OC; | 268 | 48 | return GetImportedOrCreateSpecialDecl(ToD, OC, FromD, | 269 | 48 | std::forward<Args>(args)...); | 270 | 48 | } |
bool clang::ASTNodeImporter::GetImportedOrCreateDecl<clang::ConstructorUsingShadowDecl, clang::UsingShadowDecl, clang::UsingShadowDecl, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::UsingDecl*, clang::NamedDecl*, bool>(clang::UsingShadowDecl*&, clang::UsingShadowDecl*, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::UsingDecl*&&, clang::NamedDecl*&&, bool&&) Line | Count | Source | 266 | 165 | Args &&... args) { | 267 | 165 | CallOverloadedCreateFun<NewDeclT> OC; | 268 | 165 | return GetImportedOrCreateSpecialDecl(ToD, OC, FromD, | 269 | 165 | std::forward<Args>(args)...); | 270 | 165 | } |
bool clang::ASTNodeImporter::GetImportedOrCreateDecl<clang::ClassTemplatePartialSpecializationDecl, clang::ClassTemplateSpecializationDecl, clang::ClassTemplateSpecializationDecl, clang::ASTContext&, clang::TagTypeKind, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::TemplateParameterList*&, clang::ClassTemplateDecl*&, llvm::ArrayRef<clang::TemplateArgument>, clang::TemplateArgumentListInfo&, clang::QualType&, clang::ClassTemplatePartialSpecializationDecl*>(clang::ClassTemplateSpecializationDecl*&, clang::ClassTemplateSpecializationDecl*, clang::ASTContext&, clang::TagTypeKind&&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::TemplateParameterList*&, clang::ClassTemplateDecl*&, llvm::ArrayRef<clang::TemplateArgument>&&, clang::TemplateArgumentListInfo&, clang::QualType&, clang::ClassTemplatePartialSpecializationDecl*&&) Line | Count | Source | 266 | 970 | Args &&... args) { | 267 | 970 | CallOverloadedCreateFun<NewDeclT> OC; | 268 | 970 | return GetImportedOrCreateSpecialDecl(ToD, OC, FromD, | 269 | 970 | std::forward<Args>(args)...); | 270 | 970 | } |
|
271 | | // Use this version if a special create function must be |
272 | | // used, e.g. CXXRecordDecl::CreateLambda . |
273 | | template <typename ToDeclT, typename CreateFunT, typename FromDeclT, |
274 | | typename... Args> |
275 | | LLVM_NODISCARD bool |
276 | | GetImportedOrCreateSpecialDecl(ToDeclT *&ToD, CreateFunT CreateFun, |
277 | 4.64M | FromDeclT *FromD, Args &&... args) { |
278 | 4.64M | if (Importer.getImportDeclErrorIfAny(FromD)) { |
279 | 8 | ToD = nullptr; |
280 | 8 | return true; // Already imported but with error. |
281 | 8 | } |
282 | 4.64M | ToD = cast_or_null<ToDeclT>(Importer.GetAlreadyImportedOrNull(FromD)); |
283 | 4.64M | if (ToD) |
284 | 242k | return true; // Already imported. |
285 | 4.39M | ToD = CreateFun(std::forward<Args>(args)...); |
286 | | // Keep track of imported Decls. |
287 | 4.39M | Importer.RegisterImportedDecl(FromD, ToD); |
288 | 4.39M | InitializeImportedDecl(FromD, ToD); |
289 | 4.39M | return false; // A new Decl is created. |
290 | 4.64M | } Unexecuted instantiation: bool clang::ASTNodeImporter::GetImportedOrCreateSpecialDecl<clang::EmptyDecl, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::EmptyDecl>, clang::EmptyDecl, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&>(clang::EmptyDecl*&, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::EmptyDecl>, clang::EmptyDecl*, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&) bool clang::ASTNodeImporter::GetImportedOrCreateSpecialDecl<clang::BindingDecl, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::BindingDecl>, clang::BindingDecl, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::IdentifierInfo*>(clang::BindingDecl*&, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::BindingDecl>, clang::BindingDecl*, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::IdentifierInfo*&&) Line | Count | Source | 277 | 32 | FromDeclT *FromD, Args &&... args) { | 278 | 32 | if (Importer.getImportDeclErrorIfAny(FromD)) { | 279 | 0 | ToD = nullptr; | 280 | 0 | return true; // Already imported but with error. | 281 | 0 | } | 282 | 32 | ToD = cast_or_null<ToDeclT>(Importer.GetAlreadyImportedOrNull(FromD)); | 283 | 32 | if (ToD) | 284 | 0 | return true; // Already imported. | 285 | 32 | ToD = CreateFun(std::forward<Args>(args)...); | 286 | | // Keep track of imported Decls. | 287 | 32 | Importer.RegisterImportedDecl(FromD, ToD); | 288 | 32 | InitializeImportedDecl(FromD, ToD); | 289 | 32 | return false; // A new Decl is created. | 290 | 32 | } |
bool clang::ASTNodeImporter::GetImportedOrCreateSpecialDecl<clang::AccessSpecDecl, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::AccessSpecDecl>, clang::AccessSpecDecl, clang::ASTContext&, clang::AccessSpecifier, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&>(clang::AccessSpecDecl*&, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::AccessSpecDecl>, clang::AccessSpecDecl*, clang::ASTContext&, clang::AccessSpecifier&&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&) Line | Count | Source | 277 | 84.4k | FromDeclT *FromD, Args &&... args) { | 278 | 84.4k | if (Importer.getImportDeclErrorIfAny(FromD)) { | 279 | 0 | ToD = nullptr; | 280 | 0 | return true; // Already imported but with error. | 281 | 0 | } | 282 | 84.4k | ToD = cast_or_null<ToDeclT>(Importer.GetAlreadyImportedOrNull(FromD)); | 283 | 84.4k | if (ToD) | 284 | 0 | return true; // Already imported. | 285 | 84.4k | ToD = CreateFun(std::forward<Args>(args)...); | 286 | | // Keep track of imported Decls. | 287 | 84.4k | Importer.RegisterImportedDecl(FromD, ToD); | 288 | 84.4k | InitializeImportedDecl(FromD, ToD); | 289 | 84.4k | return false; // A new Decl is created. | 290 | 84.4k | } |
bool clang::ASTNodeImporter::GetImportedOrCreateSpecialDecl<clang::StaticAssertDecl, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::StaticAssertDecl>, clang::StaticAssertDecl, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::Expr*&, clang::StringLiteral*&, clang::SourceLocation&, bool>(clang::StaticAssertDecl*&, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::StaticAssertDecl>, clang::StaticAssertDecl*, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::Expr*&, clang::StringLiteral*&, clang::SourceLocation&, bool&&) Line | Count | Source | 277 | 18.8k | FromDeclT *FromD, Args &&... args) { | 278 | 18.8k | if (Importer.getImportDeclErrorIfAny(FromD)) { | 279 | 0 | ToD = nullptr; | 280 | 0 | return true; // Already imported but with error. | 281 | 0 | } | 282 | 18.8k | ToD = cast_or_null<ToDeclT>(Importer.GetAlreadyImportedOrNull(FromD)); | 283 | 18.8k | if (ToD) | 284 | 0 | return true; // Already imported. | 285 | 18.8k | ToD = CreateFun(std::forward<Args>(args)...); | 286 | | // Keep track of imported Decls. | 287 | 18.8k | Importer.RegisterImportedDecl(FromD, ToD); | 288 | 18.8k | InitializeImportedDecl(FromD, ToD); | 289 | 18.8k | return false; // A new Decl is created. | 290 | 18.8k | } |
bool clang::ASTNodeImporter::GetImportedOrCreateSpecialDecl<clang::NamespaceDecl, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::NamespaceDecl>, clang::NamespaceDecl, clang::ASTContext&, clang::DeclContext*&, bool, clang::SourceLocation&, clang::SourceLocation&, clang::IdentifierInfo*, std::nullptr_t>(clang::NamespaceDecl*&, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::NamespaceDecl>, clang::NamespaceDecl*, clang::ASTContext&, clang::DeclContext*&, bool&&, clang::SourceLocation&, clang::SourceLocation&, clang::IdentifierInfo*&&, std::nullptr_t&&) Line | Count | Source | 277 | 4.18k | FromDeclT *FromD, Args &&... args) { | 278 | 4.18k | if (Importer.getImportDeclErrorIfAny(FromD)) { | 279 | 0 | ToD = nullptr; | 280 | 0 | return true; // Already imported but with error. | 281 | 0 | } | 282 | 4.18k | ToD = cast_or_null<ToDeclT>(Importer.GetAlreadyImportedOrNull(FromD)); | 283 | 4.18k | if (ToD) | 284 | 0 | return true; // Already imported. | 285 | 4.18k | ToD = CreateFun(std::forward<Args>(args)...); | 286 | | // Keep track of imported Decls. | 287 | 4.18k | Importer.RegisterImportedDecl(FromD, ToD); | 288 | 4.18k | InitializeImportedDecl(FromD, ToD); | 289 | 4.18k | return false; // A new Decl is created. | 290 | 4.18k | } |
bool clang::ASTNodeImporter::GetImportedOrCreateSpecialDecl<clang::NamespaceAliasDecl, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::NamespaceAliasDecl>, clang::NamespaceAliasDecl, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::IdentifierInfo*&, clang::NestedNameSpecifierLoc&, clang::SourceLocation&, clang::NamespaceDecl*&>(clang::NamespaceAliasDecl*&, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::NamespaceAliasDecl>, clang::NamespaceAliasDecl*, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::IdentifierInfo*&, clang::NestedNameSpecifierLoc&, clang::SourceLocation&, clang::NamespaceDecl*&) Line | Count | Source | 277 | 3 | FromDeclT *FromD, Args &&... args) { | 278 | 3 | if (Importer.getImportDeclErrorIfAny(FromD)) { | 279 | 0 | ToD = nullptr; | 280 | 0 | return true; // Already imported but with error. | 281 | 0 | } | 282 | 3 | ToD = cast_or_null<ToDeclT>(Importer.GetAlreadyImportedOrNull(FromD)); | 283 | 3 | if (ToD) | 284 | 0 | return true; // Already imported. | 285 | 3 | ToD = CreateFun(std::forward<Args>(args)...); | 286 | | // Keep track of imported Decls. | 287 | 3 | Importer.RegisterImportedDecl(FromD, ToD); | 288 | 3 | InitializeImportedDecl(FromD, ToD); | 289 | 3 | return false; // A new Decl is created. | 290 | 3 | } |
bool clang::ASTNodeImporter::GetImportedOrCreateSpecialDecl<clang::TypedefNameDecl, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::TypeAliasDecl>, clang::TypedefNameDecl, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::IdentifierInfo*, clang::TypeSourceInfo*&>(clang::TypedefNameDecl*&, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::TypeAliasDecl>, clang::TypedefNameDecl*, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::IdentifierInfo*&&, clang::TypeSourceInfo*&) Line | Count | Source | 277 | 35.4k | FromDeclT *FromD, Args &&... args) { | 278 | 35.4k | if (Importer.getImportDeclErrorIfAny(FromD)) { | 279 | 0 | ToD = nullptr; | 280 | 0 | return true; // Already imported but with error. | 281 | 0 | } | 282 | 35.4k | ToD = cast_or_null<ToDeclT>(Importer.GetAlreadyImportedOrNull(FromD)); | 283 | 35.4k | if (ToD) | 284 | 2.44k | return true; // Already imported. | 285 | 33.0k | ToD = CreateFun(std::forward<Args>(args)...); | 286 | | // Keep track of imported Decls. | 287 | 33.0k | Importer.RegisterImportedDecl(FromD, ToD); | 288 | 33.0k | InitializeImportedDecl(FromD, ToD); | 289 | 33.0k | return false; // A new Decl is created. | 290 | 35.4k | } |
bool clang::ASTNodeImporter::GetImportedOrCreateSpecialDecl<clang::TypedefNameDecl, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::TypedefDecl>, clang::TypedefNameDecl, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::IdentifierInfo*, clang::TypeSourceInfo*&>(clang::TypedefNameDecl*&, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::TypedefDecl>, clang::TypedefNameDecl*, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::IdentifierInfo*&&, clang::TypeSourceInfo*&) Line | Count | Source | 277 | 253k | FromDeclT *FromD, Args &&... args) { | 278 | 253k | if (Importer.getImportDeclErrorIfAny(FromD)) { | 279 | 0 | ToD = nullptr; | 280 | 0 | return true; // Already imported but with error. | 281 | 0 | } | 282 | 253k | ToD = cast_or_null<ToDeclT>(Importer.GetAlreadyImportedOrNull(FromD)); | 283 | 253k | if (ToD) | 284 | 1.31k | return true; // Already imported. | 285 | 252k | ToD = CreateFun(std::forward<Args>(args)...); | 286 | | // Keep track of imported Decls. | 287 | 252k | Importer.RegisterImportedDecl(FromD, ToD); | 288 | 252k | InitializeImportedDecl(FromD, ToD); | 289 | 252k | return false; // A new Decl is created. | 290 | 253k | } |
bool clang::ASTNodeImporter::GetImportedOrCreateSpecialDecl<clang::TypeAliasTemplateDecl, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::TypeAliasTemplateDecl>, clang::TypeAliasTemplateDecl, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::DeclarationName&, clang::TemplateParameterList*&, clang::TypeAliasDecl*&>(clang::TypeAliasTemplateDecl*&, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::TypeAliasTemplateDecl>, clang::TypeAliasTemplateDecl*, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::DeclarationName&, clang::TemplateParameterList*&, clang::TypeAliasDecl*&) Line | Count | Source | 277 | 8.58k | FromDeclT *FromD, Args &&... args) { | 278 | 8.58k | if (Importer.getImportDeclErrorIfAny(FromD)) { | 279 | 0 | ToD = nullptr; | 280 | 0 | return true; // Already imported but with error. | 281 | 0 | } | 282 | 8.58k | ToD = cast_or_null<ToDeclT>(Importer.GetAlreadyImportedOrNull(FromD)); | 283 | 8.58k | if (ToD) | 284 | 195 | return true; // Already imported. | 285 | 8.38k | ToD = CreateFun(std::forward<Args>(args)...); | 286 | | // Keep track of imported Decls. | 287 | 8.38k | Importer.RegisterImportedDecl(FromD, ToD); | 288 | 8.38k | InitializeImportedDecl(FromD, ToD); | 289 | 8.38k | return false; // A new Decl is created. | 290 | 8.58k | } |
Unexecuted instantiation: bool clang::ASTNodeImporter::GetImportedOrCreateSpecialDecl<clang::LabelDecl, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::LabelDecl>, clang::LabelDecl, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::IdentifierInfo*, clang::SourceLocation&>(clang::LabelDecl*&, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::LabelDecl>, clang::LabelDecl*, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::IdentifierInfo*&&, clang::SourceLocation&) bool clang::ASTNodeImporter::GetImportedOrCreateSpecialDecl<clang::LabelDecl, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::LabelDecl>, clang::LabelDecl, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::IdentifierInfo*>(clang::LabelDecl*&, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::LabelDecl>, clang::LabelDecl*, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::IdentifierInfo*&&) Line | Count | Source | 277 | 258 | FromDeclT *FromD, Args &&... args) { | 278 | 258 | if (Importer.getImportDeclErrorIfAny(FromD)) { | 279 | 0 | ToD = nullptr; | 280 | 0 | return true; // Already imported but with error. | 281 | 0 | } | 282 | 258 | ToD = cast_or_null<ToDeclT>(Importer.GetAlreadyImportedOrNull(FromD)); | 283 | 258 | if (ToD) | 284 | 0 | return true; // Already imported. | 285 | 258 | ToD = CreateFun(std::forward<Args>(args)...); | 286 | | // Keep track of imported Decls. | 287 | 258 | Importer.RegisterImportedDecl(FromD, ToD); | 288 | 258 | InitializeImportedDecl(FromD, ToD); | 289 | 258 | return false; // A new Decl is created. | 290 | 258 | } |
bool clang::ASTNodeImporter::GetImportedOrCreateSpecialDecl<clang::EnumDecl, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::EnumDecl>, clang::EnumDecl, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::IdentifierInfo*, clang::EnumDecl*&, bool, bool, bool>(clang::EnumDecl*&, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::EnumDecl>, clang::EnumDecl*, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::IdentifierInfo*&&, clang::EnumDecl*&, bool&&, bool&&, bool&&) Line | Count | Source | 277 | 3.09k | FromDeclT *FromD, Args &&... args) { | 278 | 3.09k | if (Importer.getImportDeclErrorIfAny(FromD)) { | 279 | 0 | ToD = nullptr; | 280 | 0 | return true; // Already imported but with error. | 281 | 0 | } | 282 | 3.09k | ToD = cast_or_null<ToDeclT>(Importer.GetAlreadyImportedOrNull(FromD)); | 283 | 3.09k | if (ToD) | 284 | 0 | return true; // Already imported. | 285 | 3.09k | ToD = CreateFun(std::forward<Args>(args)...); | 286 | | // Keep track of imported Decls. | 287 | 3.09k | Importer.RegisterImportedDecl(FromD, ToD); | 288 | 3.09k | InitializeImportedDecl(FromD, ToD); | 289 | 3.09k | return false; // A new Decl is created. | 290 | 3.09k | } |
bool clang::ASTNodeImporter::GetImportedOrCreateSpecialDecl<clang::CXXRecordDecl, clang::CXXRecordDecl* (*)(clang::ASTContext const&, clang::DeclContext*, clang::TypeSourceInfo*, clang::SourceLocation, unsigned int, bool, clang::LambdaCaptureDefault), clang::RecordDecl, clang::ASTContext&, clang::DeclContext*&, clang::TypeSourceInfo*&, clang::SourceLocation&, unsigned int, bool, clang::LambdaCaptureDefault>(clang::CXXRecordDecl*&, clang::CXXRecordDecl* (*)(clang::ASTContext const&, clang::DeclContext*, clang::TypeSourceInfo*, clang::SourceLocation, unsigned int, bool, clang::LambdaCaptureDefault), clang::RecordDecl*, clang::ASTContext&, clang::DeclContext*&, clang::TypeSourceInfo*&, clang::SourceLocation&, unsigned int&&, bool&&, clang::LambdaCaptureDefault&&) Line | Count | Source | 277 | 89 | FromDeclT *FromD, Args &&... args) { | 278 | 89 | if (Importer.getImportDeclErrorIfAny(FromD)) { | 279 | 0 | ToD = nullptr; | 280 | 0 | return true; // Already imported but with error. | 281 | 0 | } | 282 | 89 | ToD = cast_or_null<ToDeclT>(Importer.GetAlreadyImportedOrNull(FromD)); | 283 | 89 | if (ToD) | 284 | 0 | return true; // Already imported. | 285 | 89 | ToD = CreateFun(std::forward<Args>(args)...); | 286 | | // Keep track of imported Decls. | 287 | 89 | Importer.RegisterImportedDecl(FromD, ToD); | 288 | 89 | InitializeImportedDecl(FromD, ToD); | 289 | 89 | return false; // A new Decl is created. | 290 | 89 | } |
bool clang::ASTNodeImporter::GetImportedOrCreateSpecialDecl<clang::CXXRecordDecl, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::CXXRecordDecl>, clang::RecordDecl, clang::ASTContext&, clang::TagTypeKind, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::IdentifierInfo*, clang::CXXRecordDecl*, bool const&>(clang::CXXRecordDecl*&, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::CXXRecordDecl>, clang::RecordDecl*, clang::ASTContext&, clang::TagTypeKind&&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::IdentifierInfo*&&, clang::CXXRecordDecl*&&, bool const&) Line | Count | Source | 277 | 97.4k | FromDeclT *FromD, Args &&... args) { | 278 | 97.4k | if (Importer.getImportDeclErrorIfAny(FromD)) { | 279 | 0 | ToD = nullptr; | 280 | 0 | return true; // Already imported but with error. | 281 | 0 | } | 282 | 97.4k | ToD = cast_or_null<ToDeclT>(Importer.GetAlreadyImportedOrNull(FromD)); | 283 | 97.4k | if (ToD) | 284 | 0 | return true; // Already imported. | 285 | 97.4k | ToD = CreateFun(std::forward<Args>(args)...); | 286 | | // Keep track of imported Decls. | 287 | 97.4k | Importer.RegisterImportedDecl(FromD, ToD); | 288 | 97.4k | InitializeImportedDecl(FromD, ToD); | 289 | 97.4k | return false; // A new Decl is created. | 290 | 97.4k | } |
bool clang::ASTNodeImporter::GetImportedOrCreateSpecialDecl<clang::CXXRecordDecl, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::CXXRecordDecl>, clang::RecordDecl, clang::ASTContext&, clang::TagTypeKind, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::IdentifierInfo*, clang::CXXRecordDecl*>(clang::CXXRecordDecl*&, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::CXXRecordDecl>, clang::RecordDecl*, clang::ASTContext&, clang::TagTypeKind&&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::IdentifierInfo*&&, clang::CXXRecordDecl*&&) Line | Count | Source | 277 | 101k | FromDeclT *FromD, Args &&... args) { | 278 | 101k | if (Importer.getImportDeclErrorIfAny(FromD)) { | 279 | 8 | ToD = nullptr; | 280 | 8 | return true; // Already imported but with error. | 281 | 8 | } | 282 | 101k | ToD = cast_or_null<ToDeclT>(Importer.GetAlreadyImportedOrNull(FromD)); | 283 | 101k | if (ToD) | 284 | 704 | return true; // Already imported. | 285 | 100k | ToD = CreateFun(std::forward<Args>(args)...); | 286 | | // Keep track of imported Decls. | 287 | 100k | Importer.RegisterImportedDecl(FromD, ToD); | 288 | 100k | InitializeImportedDecl(FromD, ToD); | 289 | 100k | return false; // A new Decl is created. | 290 | 101k | } |
bool clang::ASTNodeImporter::GetImportedOrCreateSpecialDecl<clang::RecordDecl, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::RecordDecl>, clang::RecordDecl, clang::ASTContext&, clang::TagTypeKind, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::IdentifierInfo*, clang::RecordDecl*&>(clang::RecordDecl*&, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::RecordDecl>, clang::RecordDecl*, clang::ASTContext&, clang::TagTypeKind&&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::IdentifierInfo*&&, clang::RecordDecl*&) Line | Count | Source | 277 | 146 | FromDeclT *FromD, Args &&... args) { | 278 | 146 | if (Importer.getImportDeclErrorIfAny(FromD)) { | 279 | 0 | ToD = nullptr; | 280 | 0 | return true; // Already imported but with error. | 281 | 0 | } | 282 | 146 | ToD = cast_or_null<ToDeclT>(Importer.GetAlreadyImportedOrNull(FromD)); | 283 | 146 | if (ToD) | 284 | 13 | return true; // Already imported. | 285 | 133 | ToD = CreateFun(std::forward<Args>(args)...); | 286 | | // Keep track of imported Decls. | 287 | 133 | Importer.RegisterImportedDecl(FromD, ToD); | 288 | 133 | InitializeImportedDecl(FromD, ToD); | 289 | 133 | return false; // A new Decl is created. | 290 | 146 | } |
bool clang::ASTNodeImporter::GetImportedOrCreateSpecialDecl<clang::EnumConstantDecl, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::EnumConstantDecl>, clang::EnumConstantDecl, clang::ASTContext&, clang::EnumDecl*, clang::SourceLocation&, clang::IdentifierInfo*, clang::QualType&, clang::Expr*&, llvm::APSInt const&>(clang::EnumConstantDecl*&, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::EnumConstantDecl>, clang::EnumConstantDecl*, clang::ASTContext&, clang::EnumDecl*&&, clang::SourceLocation&, clang::IdentifierInfo*&&, clang::QualType&, clang::Expr*&, llvm::APSInt const&) Line | Count | Source | 277 | 9.19k | FromDeclT *FromD, Args &&... args) { | 278 | 9.19k | if (Importer.getImportDeclErrorIfAny(FromD)) { | 279 | 0 | ToD = nullptr; | 280 | 0 | return true; // Already imported but with error. | 281 | 0 | } | 282 | 9.19k | ToD = cast_or_null<ToDeclT>(Importer.GetAlreadyImportedOrNull(FromD)); | 283 | 9.19k | if (ToD) | 284 | 0 | return true; // Already imported. | 285 | 9.19k | ToD = CreateFun(std::forward<Args>(args)...); | 286 | | // Keep track of imported Decls. | 287 | 9.19k | Importer.RegisterImportedDecl(FromD, ToD); | 288 | 9.19k | InitializeImportedDecl(FromD, ToD); | 289 | 9.19k | return false; // A new Decl is created. | 290 | 9.19k | } |
bool clang::ASTNodeImporter::GetImportedOrCreateSpecialDecl<clang::FunctionDecl, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::CXXConstructorDecl>, clang::FunctionDecl, clang::ASTContext&, clang::CXXRecordDecl*, clang::SourceLocation&, clang::DeclarationNameInfo&, clang::QualType&, clang::TypeSourceInfo*&, clang::ExplicitSpecifier&, bool, bool, bool, clang::ConstexprSpecKind, clang::InheritedConstructor&, clang::Expr*&>(clang::FunctionDecl*&, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::CXXConstructorDecl>, clang::FunctionDecl*, clang::ASTContext&, clang::CXXRecordDecl*&&, clang::SourceLocation&, clang::DeclarationNameInfo&, clang::QualType&, clang::TypeSourceInfo*&, clang::ExplicitSpecifier&, bool&&, bool&&, bool&&, clang::ConstexprSpecKind&&, clang::InheritedConstructor&, clang::Expr*&) Line | Count | Source | 277 | 191k | FromDeclT *FromD, Args &&... args) { | 278 | 191k | if (Importer.getImportDeclErrorIfAny(FromD)) { | 279 | 0 | ToD = nullptr; | 280 | 0 | return true; // Already imported but with error. | 281 | 0 | } | 282 | 191k | ToD = cast_or_null<ToDeclT>(Importer.GetAlreadyImportedOrNull(FromD)); | 283 | 191k | if (ToD) | 284 | 18 | return true; // Already imported. | 285 | 191k | ToD = CreateFun(std::forward<Args>(args)...); | 286 | | // Keep track of imported Decls. | 287 | 191k | Importer.RegisterImportedDecl(FromD, ToD); | 288 | 191k | InitializeImportedDecl(FromD, ToD); | 289 | 191k | return false; // A new Decl is created. | 290 | 191k | } |
bool clang::ASTNodeImporter::GetImportedOrCreateSpecialDecl<clang::FunctionDecl, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::CXXDestructorDecl>, clang::FunctionDecl, clang::ASTContext&, clang::CXXRecordDecl*, clang::SourceLocation&, clang::DeclarationNameInfo&, clang::QualType&, clang::TypeSourceInfo*&, bool, bool, bool, clang::ConstexprSpecKind, clang::Expr*&>(clang::FunctionDecl*&, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::CXXDestructorDecl>, clang::FunctionDecl*, clang::ASTContext&, clang::CXXRecordDecl*&&, clang::SourceLocation&, clang::DeclarationNameInfo&, clang::QualType&, clang::TypeSourceInfo*&, bool&&, bool&&, bool&&, clang::ConstexprSpecKind&&, clang::Expr*&) Line | Count | Source | 277 | 21.1k | FromDeclT *FromD, Args &&... args) { | 278 | 21.1k | if (Importer.getImportDeclErrorIfAny(FromD)) { | 279 | 0 | ToD = nullptr; | 280 | 0 | return true; // Already imported but with error. | 281 | 0 | } | 282 | 21.1k | ToD = cast_or_null<ToDeclT>(Importer.GetAlreadyImportedOrNull(FromD)); | 283 | 21.1k | if (ToD) | 284 | 0 | return true; // Already imported. | 285 | 21.1k | ToD = CreateFun(std::forward<Args>(args)...); | 286 | | // Keep track of imported Decls. | 287 | 21.1k | Importer.RegisterImportedDecl(FromD, ToD); | 288 | 21.1k | InitializeImportedDecl(FromD, ToD); | 289 | 21.1k | return false; // A new Decl is created. | 290 | 21.1k | } |
bool clang::ASTNodeImporter::GetImportedOrCreateSpecialDecl<clang::FunctionDecl, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::CXXConversionDecl>, clang::FunctionDecl, clang::ASTContext&, clang::CXXRecordDecl*, clang::SourceLocation&, clang::DeclarationNameInfo&, clang::QualType&, clang::TypeSourceInfo*&, bool, bool, clang::ExplicitSpecifier&, clang::ConstexprSpecKind, clang::SourceLocation, clang::Expr*&>(clang::FunctionDecl*&, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::CXXConversionDecl>, clang::FunctionDecl*, clang::ASTContext&, clang::CXXRecordDecl*&&, clang::SourceLocation&, clang::DeclarationNameInfo&, clang::QualType&, clang::TypeSourceInfo*&, bool&&, bool&&, clang::ExplicitSpecifier&, clang::ConstexprSpecKind&&, clang::SourceLocation&&, clang::Expr*&) Line | Count | Source | 277 | 3.54k | FromDeclT *FromD, Args &&... args) { | 278 | 3.54k | if (Importer.getImportDeclErrorIfAny(FromD)) { | 279 | 0 | ToD = nullptr; | 280 | 0 | return true; // Already imported but with error. | 281 | 0 | } | 282 | 3.54k | ToD = cast_or_null<ToDeclT>(Importer.GetAlreadyImportedOrNull(FromD)); | 283 | 3.54k | if (ToD) | 284 | 0 | return true; // Already imported. | 285 | 3.54k | ToD = CreateFun(std::forward<Args>(args)...); | 286 | | // Keep track of imported Decls. | 287 | 3.54k | Importer.RegisterImportedDecl(FromD, ToD); | 288 | 3.54k | InitializeImportedDecl(FromD, ToD); | 289 | 3.54k | return false; // A new Decl is created. | 290 | 3.54k | } |
bool clang::ASTNodeImporter::GetImportedOrCreateSpecialDecl<clang::FunctionDecl, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::CXXMethodDecl>, clang::FunctionDecl, clang::ASTContext&, clang::CXXRecordDecl*, clang::SourceLocation&, clang::DeclarationNameInfo&, clang::QualType&, clang::TypeSourceInfo*&, clang::StorageClass, bool, bool, clang::ConstexprSpecKind, clang::SourceLocation, clang::Expr*&>(clang::FunctionDecl*&, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::CXXMethodDecl>, clang::FunctionDecl*, clang::ASTContext&, clang::CXXRecordDecl*&&, clang::SourceLocation&, clang::DeclarationNameInfo&, clang::QualType&, clang::TypeSourceInfo*&, clang::StorageClass&&, bool&&, bool&&, clang::ConstexprSpecKind&&, clang::SourceLocation&&, clang::Expr*&) Line | Count | Source | 277 | 709k | FromDeclT *FromD, Args &&... args) { | 278 | 709k | if (Importer.getImportDeclErrorIfAny(FromD)) { | 279 | 0 | ToD = nullptr; | 280 | 0 | return true; // Already imported but with error. | 281 | 0 | } | 282 | 709k | ToD = cast_or_null<ToDeclT>(Importer.GetAlreadyImportedOrNull(FromD)); | 283 | 709k | if (ToD) | 284 | 393 | return true; // Already imported. | 285 | 709k | ToD = CreateFun(std::forward<Args>(args)...); | 286 | | // Keep track of imported Decls. | 287 | 709k | Importer.RegisterImportedDecl(FromD, ToD); | 288 | 709k | InitializeImportedDecl(FromD, ToD); | 289 | 709k | return false; // A new Decl is created. | 290 | 709k | } |
bool clang::ASTNodeImporter::GetImportedOrCreateSpecialDecl<clang::FunctionDecl, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::CXXDeductionGuideDecl>, clang::FunctionDecl, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::ExplicitSpecifier&, clang::DeclarationNameInfo&, clang::QualType&, clang::TypeSourceInfo*&, clang::SourceLocation&, clang::CXXConstructorDecl*&>(clang::FunctionDecl*&, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::CXXDeductionGuideDecl>, clang::FunctionDecl*, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::ExplicitSpecifier&, clang::DeclarationNameInfo&, clang::QualType&, clang::TypeSourceInfo*&, clang::SourceLocation&, clang::CXXConstructorDecl*&) Line | Count | Source | 277 | 48 | FromDeclT *FromD, Args &&... args) { | 278 | 48 | if (Importer.getImportDeclErrorIfAny(FromD)) { | 279 | 0 | ToD = nullptr; | 280 | 0 | return true; // Already imported but with error. | 281 | 0 | } | 282 | 48 | ToD = cast_or_null<ToDeclT>(Importer.GetAlreadyImportedOrNull(FromD)); | 283 | 48 | if (ToD) | 284 | 4 | return true; // Already imported. | 285 | 44 | ToD = CreateFun(std::forward<Args>(args)...); | 286 | | // Keep track of imported Decls. | 287 | 44 | Importer.RegisterImportedDecl(FromD, ToD); | 288 | 44 | InitializeImportedDecl(FromD, ToD); | 289 | 44 | return false; // A new Decl is created. | 290 | 48 | } |
bool clang::ASTNodeImporter::GetImportedOrCreateSpecialDecl<clang::FunctionDecl, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::FunctionDecl>, clang::FunctionDecl, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::DeclarationNameInfo&, clang::QualType&, clang::TypeSourceInfo*&, clang::StorageClass, bool, bool, bool, clang::ConstexprSpecKind, clang::Expr*&>(clang::FunctionDecl*&, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::FunctionDecl>, clang::FunctionDecl*, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::DeclarationNameInfo&, clang::QualType&, clang::TypeSourceInfo*&, clang::StorageClass&&, bool&&, bool&&, bool&&, clang::ConstexprSpecKind&&, clang::Expr*&) Line | Count | Source | 277 | 112k | FromDeclT *FromD, Args &&... args) { | 278 | 112k | if (Importer.getImportDeclErrorIfAny(FromD)) { | 279 | 0 | ToD = nullptr; | 280 | 0 | return true; // Already imported but with error. | 281 | 0 | } | 282 | 112k | ToD = cast_or_null<ToDeclT>(Importer.GetAlreadyImportedOrNull(FromD)); | 283 | 112k | if (ToD) | 284 | 14 | return true; // Already imported. | 285 | 112k | ToD = CreateFun(std::forward<Args>(args)...); | 286 | | // Keep track of imported Decls. | 287 | 112k | Importer.RegisterImportedDecl(FromD, ToD); | 288 | 112k | InitializeImportedDecl(FromD, ToD); | 289 | 112k | return false; // A new Decl is created. | 290 | 112k | } |
bool clang::ASTNodeImporter::GetImportedOrCreateSpecialDecl<clang::FieldDecl, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::FieldDecl>, clang::FieldDecl, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::IdentifierInfo*, clang::QualType&, clang::TypeSourceInfo*&, clang::Expr*&, bool, clang::InClassInitStyle>(clang::FieldDecl*&, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::FieldDecl>, clang::FieldDecl*, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::IdentifierInfo*&&, clang::QualType&, clang::TypeSourceInfo*&, clang::Expr*&, bool&&, clang::InClassInitStyle&&) Line | Count | Source | 277 | 80.8k | FromDeclT *FromD, Args &&... args) { | 278 | 80.8k | if (Importer.getImportDeclErrorIfAny(FromD)) { | 279 | 0 | ToD = nullptr; | 280 | 0 | return true; // Already imported but with error. | 281 | 0 | } | 282 | 80.8k | ToD = cast_or_null<ToDeclT>(Importer.GetAlreadyImportedOrNull(FromD)); | 283 | 80.8k | if (ToD) | 284 | 312 | return true; // Already imported. | 285 | 80.5k | ToD = CreateFun(std::forward<Args>(args)...); | 286 | | // Keep track of imported Decls. | 287 | 80.5k | Importer.RegisterImportedDecl(FromD, ToD); | 288 | 80.5k | InitializeImportedDecl(FromD, ToD); | 289 | 80.5k | return false; // A new Decl is created. | 290 | 80.8k | } |
bool clang::ASTNodeImporter::GetImportedOrCreateSpecialDecl<clang::IndirectFieldDecl, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::IndirectFieldDecl>, clang::IndirectFieldDecl, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::IdentifierInfo*, clang::QualType&, llvm::MutableArrayRef<clang::NamedDecl*>&>(clang::IndirectFieldDecl*&, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::IndirectFieldDecl>, clang::IndirectFieldDecl*, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::IdentifierInfo*&&, clang::QualType&, llvm::MutableArrayRef<clang::NamedDecl*>&) Line | Count | Source | 277 | 1.45k | FromDeclT *FromD, Args &&... args) { | 278 | 1.45k | if (Importer.getImportDeclErrorIfAny(FromD)) { | 279 | 0 | ToD = nullptr; | 280 | 0 | return true; // Already imported but with error. | 281 | 0 | } | 282 | 1.45k | ToD = cast_or_null<ToDeclT>(Importer.GetAlreadyImportedOrNull(FromD)); | 283 | 1.45k | if (ToD) | 284 | 0 | return true; // Already imported. | 285 | 1.45k | ToD = CreateFun(std::forward<Args>(args)...); | 286 | | // Keep track of imported Decls. | 287 | 1.45k | Importer.RegisterImportedDecl(FromD, ToD); | 288 | 1.45k | InitializeImportedDecl(FromD, ToD); | 289 | 1.45k | return false; // A new Decl is created. | 290 | 1.45k | } |
bool clang::ASTNodeImporter::GetImportedOrCreateSpecialDecl<clang::FriendDecl, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::FriendDecl>, clang::FriendDecl, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, llvm::PointerUnion<clang::NamedDecl*, clang::TypeSourceInfo*>&, clang::SourceLocation&, llvm::SmallVector<clang::TemplateParameterList*, 1u>&>(clang::FriendDecl*&, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::FriendDecl>, clang::FriendDecl*, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, llvm::PointerUnion<clang::NamedDecl*, clang::TypeSourceInfo*>&, clang::SourceLocation&, llvm::SmallVector<clang::TemplateParameterList*, 1u>&) Line | Count | Source | 277 | 36.5k | FromDeclT *FromD, Args &&... args) { | 278 | 36.5k | if (Importer.getImportDeclErrorIfAny(FromD)) { | 279 | 0 | ToD = nullptr; | 280 | 0 | return true; // Already imported but with error. | 281 | 0 | } | 282 | 36.5k | ToD = cast_or_null<ToDeclT>(Importer.GetAlreadyImportedOrNull(FromD)); | 283 | 36.5k | if (ToD) | 284 | 0 | return true; // Already imported. | 285 | 36.5k | ToD = CreateFun(std::forward<Args>(args)...); | 286 | | // Keep track of imported Decls. | 287 | 36.5k | Importer.RegisterImportedDecl(FromD, ToD); | 288 | 36.5k | InitializeImportedDecl(FromD, ToD); | 289 | 36.5k | return false; // A new Decl is created. | 290 | 36.5k | } |
bool clang::ASTNodeImporter::GetImportedOrCreateSpecialDecl<clang::ObjCIvarDecl, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::ObjCIvarDecl>, clang::ObjCIvarDecl, clang::ASTContext&, clang::ObjCContainerDecl*, clang::SourceLocation&, clang::SourceLocation&, clang::IdentifierInfo*, clang::QualType&, clang::TypeSourceInfo*&, clang::ObjCIvarDecl::AccessControl, clang::Expr*&, bool>(clang::ObjCIvarDecl*&, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::ObjCIvarDecl>, clang::ObjCIvarDecl*, clang::ASTContext&, clang::ObjCContainerDecl*&&, clang::SourceLocation&, clang::SourceLocation&, clang::IdentifierInfo*&&, clang::QualType&, clang::TypeSourceInfo*&, clang::ObjCIvarDecl::AccessControl&&, clang::Expr*&, bool&&) Line | Count | Source | 277 | 1.63k | FromDeclT *FromD, Args &&... args) { | 278 | 1.63k | if (Importer.getImportDeclErrorIfAny(FromD)) { | 279 | 0 | ToD = nullptr; | 280 | 0 | return true; // Already imported but with error. | 281 | 0 | } | 282 | 1.63k | ToD = cast_or_null<ToDeclT>(Importer.GetAlreadyImportedOrNull(FromD)); | 283 | 1.63k | if (ToD) | 284 | 0 | return true; // Already imported. | 285 | 1.63k | ToD = CreateFun(std::forward<Args>(args)...); | 286 | | // Keep track of imported Decls. | 287 | 1.63k | Importer.RegisterImportedDecl(FromD, ToD); | 288 | 1.63k | InitializeImportedDecl(FromD, ToD); | 289 | 1.63k | return false; // A new Decl is created. | 290 | 1.63k | } |
bool clang::ASTNodeImporter::GetImportedOrCreateSpecialDecl<clang::DecompositionDecl, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::DecompositionDecl>, clang::DecompositionDecl, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::QualType&, clang::TypeSourceInfo*&, clang::StorageClass, llvm::SmallVector<clang::BindingDecl*, 6u>&>(clang::DecompositionDecl*&, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::DecompositionDecl>, clang::DecompositionDecl*, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::QualType&, clang::TypeSourceInfo*&, clang::StorageClass&&, llvm::SmallVector<clang::BindingDecl*, 6u>&) Line | Count | Source | 277 | 48 | FromDeclT *FromD, Args &&... args) { | 278 | 48 | if (Importer.getImportDeclErrorIfAny(FromD)) { | 279 | 0 | ToD = nullptr; | 280 | 0 | return true; // Already imported but with error. | 281 | 0 | } | 282 | 48 | ToD = cast_or_null<ToDeclT>(Importer.GetAlreadyImportedOrNull(FromD)); | 283 | 48 | if (ToD) | 284 | 32 | return true; // Already imported. | 285 | 16 | ToD = CreateFun(std::forward<Args>(args)...); | 286 | | // Keep track of imported Decls. | 287 | 16 | Importer.RegisterImportedDecl(FromD, ToD); | 288 | 16 | InitializeImportedDecl(FromD, ToD); | 289 | 16 | return false; // A new Decl is created. | 290 | 48 | } |
bool clang::ASTNodeImporter::GetImportedOrCreateSpecialDecl<clang::VarDecl, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::VarDecl>, clang::VarDecl, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::IdentifierInfo*, clang::QualType&, clang::TypeSourceInfo*&, clang::StorageClass>(clang::VarDecl*&, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::VarDecl>, clang::VarDecl*, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::IdentifierInfo*&&, clang::QualType&, clang::TypeSourceInfo*&, clang::StorageClass&&) Line | Count | Source | 277 | 253k | FromDeclT *FromD, Args &&... args) { | 278 | 253k | if (Importer.getImportDeclErrorIfAny(FromD)) { | 279 | 0 | ToD = nullptr; | 280 | 0 | return true; // Already imported but with error. | 281 | 0 | } | 282 | 253k | ToD = cast_or_null<ToDeclT>(Importer.GetAlreadyImportedOrNull(FromD)); | 283 | 253k | if (ToD) | 284 | 0 | return true; // Already imported. | 285 | 253k | ToD = CreateFun(std::forward<Args>(args)...); | 286 | | // Keep track of imported Decls. | 287 | 253k | Importer.RegisterImportedDecl(FromD, ToD); | 288 | 253k | InitializeImportedDecl(FromD, ToD); | 289 | 253k | return false; // A new Decl is created. | 290 | 253k | } |
Unexecuted instantiation: bool clang::ASTNodeImporter::GetImportedOrCreateSpecialDecl<clang::ImplicitParamDecl, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::ImplicitParamDecl>, clang::ImplicitParamDecl, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::IdentifierInfo*, clang::QualType&, clang::ImplicitParamDecl::ImplicitParamKind>(clang::ImplicitParamDecl*&, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::ImplicitParamDecl>, clang::ImplicitParamDecl*, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::IdentifierInfo*&&, clang::QualType&, clang::ImplicitParamDecl::ImplicitParamKind&&) bool clang::ASTNodeImporter::GetImportedOrCreateSpecialDecl<clang::ParmVarDecl, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::ParmVarDecl>, clang::ParmVarDecl, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::IdentifierInfo*, clang::QualType&, clang::TypeSourceInfo*&, clang::StorageClass, std::nullptr_t>(clang::ParmVarDecl*&, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::ParmVarDecl>, clang::ParmVarDecl*, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::IdentifierInfo*&&, clang::QualType&, clang::TypeSourceInfo*&, clang::StorageClass&&, std::nullptr_t&&) Line | Count | Source | 277 | 1.22M | FromDeclT *FromD, Args &&... args) { | 278 | 1.22M | if (Importer.getImportDeclErrorIfAny(FromD)) { | 279 | 0 | ToD = nullptr; | 280 | 0 | return true; // Already imported but with error. | 281 | 0 | } | 282 | 1.22M | ToD = cast_or_null<ToDeclT>(Importer.GetAlreadyImportedOrNull(FromD)); | 283 | 1.22M | if (ToD) | 284 | 0 | return true; // Already imported. | 285 | 1.22M | ToD = CreateFun(std::forward<Args>(args)...); | 286 | | // Keep track of imported Decls. | 287 | 1.22M | Importer.RegisterImportedDecl(FromD, ToD); | 288 | 1.22M | InitializeImportedDecl(FromD, ToD); | 289 | 1.22M | return false; // A new Decl is created. | 290 | 1.22M | } |
bool clang::ASTNodeImporter::GetImportedOrCreateSpecialDecl<clang::ObjCMethodDecl, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::ObjCMethodDecl>, clang::ObjCMethodDecl, clang::ASTContext&, clang::SourceLocation&, clang::SourceLocation&, clang::Selector, clang::QualType&, clang::TypeSourceInfo*&, clang::DeclContext*&, bool, bool, bool, bool, bool, bool, clang::ObjCMethodDecl::ImplementationControl, bool>(clang::ObjCMethodDecl*&, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::ObjCMethodDecl>, clang::ObjCMethodDecl*, clang::ASTContext&, clang::SourceLocation&, clang::SourceLocation&, clang::Selector&&, clang::QualType&, clang::TypeSourceInfo*&, clang::DeclContext*&, bool&&, bool&&, bool&&, bool&&, bool&&, bool&&, clang::ObjCMethodDecl::ImplementationControl&&, bool&&) Line | Count | Source | 277 | 8.63k | FromDeclT *FromD, Args &&... args) { | 278 | 8.63k | if (Importer.getImportDeclErrorIfAny(FromD)) { | 279 | 0 | ToD = nullptr; | 280 | 0 | return true; // Already imported but with error. | 281 | 0 | } | 282 | 8.63k | ToD = cast_or_null<ToDeclT>(Importer.GetAlreadyImportedOrNull(FromD)); | 283 | 8.63k | if (ToD) | 284 | 0 | return true; // Already imported. | 285 | 8.63k | ToD = CreateFun(std::forward<Args>(args)...); | 286 | | // Keep track of imported Decls. | 287 | 8.63k | Importer.RegisterImportedDecl(FromD, ToD); | 288 | 8.63k | InitializeImportedDecl(FromD, ToD); | 289 | 8.63k | return false; // A new Decl is created. | 290 | 8.63k | } |
bool clang::ASTNodeImporter::GetImportedOrCreateSpecialDecl<clang::ObjCTypeParamDecl, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::ObjCTypeParamDecl>, clang::ObjCTypeParamDecl, clang::ASTContext&, clang::DeclContext*&, clang::ObjCTypeParamVariance, clang::SourceLocation&, unsigned int, clang::SourceLocation&, clang::IdentifierInfo*, clang::SourceLocation&, clang::TypeSourceInfo*&>(clang::ObjCTypeParamDecl*&, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::ObjCTypeParamDecl>, clang::ObjCTypeParamDecl*, clang::ASTContext&, clang::DeclContext*&, clang::ObjCTypeParamVariance&&, clang::SourceLocation&, unsigned int&&, clang::SourceLocation&, clang::IdentifierInfo*&&, clang::SourceLocation&, clang::TypeSourceInfo*&) Line | Count | Source | 277 | 390 | FromDeclT *FromD, Args &&... args) { | 278 | 390 | if (Importer.getImportDeclErrorIfAny(FromD)) { | 279 | 0 | ToD = nullptr; | 280 | 0 | return true; // Already imported but with error. | 281 | 0 | } | 282 | 390 | ToD = cast_or_null<ToDeclT>(Importer.GetAlreadyImportedOrNull(FromD)); | 283 | 390 | if (ToD) | 284 | 0 | return true; // Already imported. | 285 | 390 | ToD = CreateFun(std::forward<Args>(args)...); | 286 | | // Keep track of imported Decls. | 287 | 390 | Importer.RegisterImportedDecl(FromD, ToD); | 288 | 390 | InitializeImportedDecl(FromD, ToD); | 289 | 390 | return false; // A new Decl is created. | 290 | 390 | } |
bool clang::ASTNodeImporter::GetImportedOrCreateSpecialDecl<clang::ObjCCategoryDecl, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::ObjCCategoryDecl>, clang::ObjCCategoryDecl, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::SourceLocation&, clang::IdentifierInfo*, clang::ObjCInterfaceDecl*&, std::nullptr_t, clang::SourceLocation&, clang::SourceLocation&>(clang::ObjCCategoryDecl*&, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::ObjCCategoryDecl>, clang::ObjCCategoryDecl*, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::SourceLocation&, clang::IdentifierInfo*&&, clang::ObjCInterfaceDecl*&, std::nullptr_t&&, clang::SourceLocation&, clang::SourceLocation&) Line | Count | Source | 277 | 2.44k | FromDeclT *FromD, Args &&... args) { | 278 | 2.44k | if (Importer.getImportDeclErrorIfAny(FromD)) { | 279 | 0 | ToD = nullptr; | 280 | 0 | return true; // Already imported but with error. | 281 | 0 | } | 282 | 2.44k | ToD = cast_or_null<ToDeclT>(Importer.GetAlreadyImportedOrNull(FromD)); | 283 | 2.44k | if (ToD) | 284 | 0 | return true; // Already imported. | 285 | 2.44k | ToD = CreateFun(std::forward<Args>(args)...); | 286 | | // Keep track of imported Decls. | 287 | 2.44k | Importer.RegisterImportedDecl(FromD, ToD); | 288 | 2.44k | InitializeImportedDecl(FromD, ToD); | 289 | 2.44k | return false; // A new Decl is created. | 290 | 2.44k | } |
bool clang::ASTNodeImporter::GetImportedOrCreateSpecialDecl<clang::ObjCProtocolDecl, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::ObjCProtocolDecl>, clang::ObjCProtocolDecl, clang::ASTContext&, clang::DeclContext*&, clang::IdentifierInfo*, clang::SourceLocation&, clang::SourceLocation&, std::nullptr_t>(clang::ObjCProtocolDecl*&, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::ObjCProtocolDecl>, clang::ObjCProtocolDecl*, clang::ASTContext&, clang::DeclContext*&, clang::IdentifierInfo*&&, clang::SourceLocation&, clang::SourceLocation&, std::nullptr_t&&) Line | Count | Source | 277 | 375 | FromDeclT *FromD, Args &&... args) { | 278 | 375 | if (Importer.getImportDeclErrorIfAny(FromD)) { | 279 | 0 | ToD = nullptr; | 280 | 0 | return true; // Already imported but with error. | 281 | 0 | } | 282 | 375 | ToD = cast_or_null<ToDeclT>(Importer.GetAlreadyImportedOrNull(FromD)); | 283 | 375 | if (ToD) | 284 | 0 | return true; // Already imported. | 285 | 375 | ToD = CreateFun(std::forward<Args>(args)...); | 286 | | // Keep track of imported Decls. | 287 | 375 | Importer.RegisterImportedDecl(FromD, ToD); | 288 | 375 | InitializeImportedDecl(FromD, ToD); | 289 | 375 | return false; // A new Decl is created. | 290 | 375 | } |
bool clang::ASTNodeImporter::GetImportedOrCreateSpecialDecl<clang::LinkageSpecDecl, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::LinkageSpecDecl>, clang::LinkageSpecDecl, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::LinkageSpecDecl::LanguageIDs, bool&>(clang::LinkageSpecDecl*&, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::LinkageSpecDecl>, clang::LinkageSpecDecl*, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::LinkageSpecDecl::LanguageIDs&&, bool&) Line | Count | Source | 277 | 6.51k | FromDeclT *FromD, Args &&... args) { | 278 | 6.51k | if (Importer.getImportDeclErrorIfAny(FromD)) { | 279 | 0 | ToD = nullptr; | 280 | 0 | return true; // Already imported but with error. | 281 | 0 | } | 282 | 6.51k | ToD = cast_or_null<ToDeclT>(Importer.GetAlreadyImportedOrNull(FromD)); | 283 | 6.51k | if (ToD) | 284 | 0 | return true; // Already imported. | 285 | 6.51k | ToD = CreateFun(std::forward<Args>(args)...); | 286 | | // Keep track of imported Decls. | 287 | 6.51k | Importer.RegisterImportedDecl(FromD, ToD); | 288 | 6.51k | InitializeImportedDecl(FromD, ToD); | 289 | 6.51k | return false; // A new Decl is created. | 290 | 6.51k | } |
bool clang::ASTNodeImporter::GetImportedOrCreateSpecialDecl<clang::UsingDecl, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::UsingDecl>, clang::UsingDecl, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::NestedNameSpecifierLoc&, clang::DeclarationNameInfo&, bool>(clang::UsingDecl*&, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::UsingDecl>, clang::UsingDecl*, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::NestedNameSpecifierLoc&, clang::DeclarationNameInfo&, bool&&) Line | Count | Source | 277 | 5.79k | FromDeclT *FromD, Args &&... args) { | 278 | 5.79k | if (Importer.getImportDeclErrorIfAny(FromD)) { | 279 | 0 | ToD = nullptr; | 280 | 0 | return true; // Already imported but with error. | 281 | 0 | } | 282 | 5.79k | ToD = cast_or_null<ToDeclT>(Importer.GetAlreadyImportedOrNull(FromD)); | 283 | 5.79k | if (ToD) | 284 | 0 | return true; // Already imported. | 285 | 5.79k | ToD = CreateFun(std::forward<Args>(args)...); | 286 | | // Keep track of imported Decls. | 287 | 5.79k | Importer.RegisterImportedDecl(FromD, ToD); | 288 | 5.79k | InitializeImportedDecl(FromD, ToD); | 289 | 5.79k | return false; // A new Decl is created. | 290 | 5.79k | } |
bool clang::ASTNodeImporter::GetImportedOrCreateSpecialDecl<clang::UsingEnumDecl, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::UsingEnumDecl>, clang::UsingEnumDecl, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::SourceLocation&, clang::EnumDecl*&>(clang::UsingEnumDecl*&, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::UsingEnumDecl>, clang::UsingEnumDecl*, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::SourceLocation&, clang::EnumDecl*&) Line | Count | Source | 277 | 8 | FromDeclT *FromD, Args &&... args) { | 278 | 8 | if (Importer.getImportDeclErrorIfAny(FromD)) { | 279 | 0 | ToD = nullptr; | 280 | 0 | return true; // Already imported but with error. | 281 | 0 | } | 282 | 8 | ToD = cast_or_null<ToDeclT>(Importer.GetAlreadyImportedOrNull(FromD)); | 283 | 8 | if (ToD) | 284 | 0 | return true; // Already imported. | 285 | 8 | ToD = CreateFun(std::forward<Args>(args)...); | 286 | | // Keep track of imported Decls. | 287 | 8 | Importer.RegisterImportedDecl(FromD, ToD); | 288 | 8 | InitializeImportedDecl(FromD, ToD); | 289 | 8 | return false; // A new Decl is created. | 290 | 8 | } |
bool clang::ASTNodeImporter::GetImportedOrCreateSpecialDecl<clang::UsingShadowDecl, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::ConstructorUsingShadowDecl>, clang::UsingShadowDecl, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::UsingDecl*, clang::NamedDecl*, bool>(clang::UsingShadowDecl*&, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::ConstructorUsingShadowDecl>, clang::UsingShadowDecl*, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::UsingDecl*&&, clang::NamedDecl*&&, bool&&) Line | Count | Source | 277 | 165 | FromDeclT *FromD, Args &&... args) { | 278 | 165 | if (Importer.getImportDeclErrorIfAny(FromD)) { | 279 | 0 | ToD = nullptr; | 280 | 0 | return true; // Already imported but with error. | 281 | 0 | } | 282 | 165 | ToD = cast_or_null<ToDeclT>(Importer.GetAlreadyImportedOrNull(FromD)); | 283 | 165 | if (ToD) | 284 | 0 | return true; // Already imported. | 285 | 165 | ToD = CreateFun(std::forward<Args>(args)...); | 286 | | // Keep track of imported Decls. | 287 | 165 | Importer.RegisterImportedDecl(FromD, ToD); | 288 | 165 | InitializeImportedDecl(FromD, ToD); | 289 | 165 | return false; // A new Decl is created. | 290 | 165 | } |
bool clang::ASTNodeImporter::GetImportedOrCreateSpecialDecl<clang::UsingShadowDecl, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::UsingShadowDecl>, clang::UsingShadowDecl, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::DeclarationName&, clang::BaseUsingDecl*&, clang::NamedDecl*&>(clang::UsingShadowDecl*&, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::UsingShadowDecl>, clang::UsingShadowDecl*, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::DeclarationName&, clang::BaseUsingDecl*&, clang::NamedDecl*&) Line | Count | Source | 277 | 45.6k | FromDeclT *FromD, Args &&... args) { | 278 | 45.6k | if (Importer.getImportDeclErrorIfAny(FromD)) { | 279 | 0 | ToD = nullptr; | 280 | 0 | return true; // Already imported but with error. | 281 | 0 | } | 282 | 45.6k | ToD = cast_or_null<ToDeclT>(Importer.GetAlreadyImportedOrNull(FromD)); | 283 | 45.6k | if (ToD) | 284 | 4.63k | return true; // Already imported. | 285 | 40.9k | ToD = CreateFun(std::forward<Args>(args)...); | 286 | | // Keep track of imported Decls. | 287 | 40.9k | Importer.RegisterImportedDecl(FromD, ToD); | 288 | 40.9k | InitializeImportedDecl(FromD, ToD); | 289 | 40.9k | return false; // A new Decl is created. | 290 | 45.6k | } |
bool clang::ASTNodeImporter::GetImportedOrCreateSpecialDecl<clang::UsingDirectiveDecl, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::UsingDirectiveDecl>, clang::UsingDirectiveDecl, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::NestedNameSpecifierLoc&, clang::SourceLocation&, clang::NamespaceDecl*&, clang::DeclContext*&>(clang::UsingDirectiveDecl*&, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::UsingDirectiveDecl>, clang::UsingDirectiveDecl*, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::NestedNameSpecifierLoc&, clang::SourceLocation&, clang::NamespaceDecl*&, clang::DeclContext*&) Line | Count | Source | 277 | 269 | FromDeclT *FromD, Args &&... args) { | 278 | 269 | if (Importer.getImportDeclErrorIfAny(FromD)) { | 279 | 0 | ToD = nullptr; | 280 | 0 | return true; // Already imported but with error. | 281 | 0 | } | 282 | 269 | ToD = cast_or_null<ToDeclT>(Importer.GetAlreadyImportedOrNull(FromD)); | 283 | 269 | if (ToD) | 284 | 0 | return true; // Already imported. | 285 | 269 | ToD = CreateFun(std::forward<Args>(args)...); | 286 | | // Keep track of imported Decls. | 287 | 269 | Importer.RegisterImportedDecl(FromD, ToD); | 288 | 269 | InitializeImportedDecl(FromD, ToD); | 289 | 269 | return false; // A new Decl is created. | 290 | 269 | } |
bool clang::ASTNodeImporter::GetImportedOrCreateSpecialDecl<clang::UnresolvedUsingValueDecl, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::UnresolvedUsingValueDecl>, clang::UnresolvedUsingValueDecl, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::NestedNameSpecifierLoc&, clang::DeclarationNameInfo&, clang::SourceLocation&>(clang::UnresolvedUsingValueDecl*&, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::UnresolvedUsingValueDecl>, clang::UnresolvedUsingValueDecl*, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::NestedNameSpecifierLoc&, clang::DeclarationNameInfo&, clang::SourceLocation&) Line | Count | Source | 277 | 2 | FromDeclT *FromD, Args &&... args) { | 278 | 2 | if (Importer.getImportDeclErrorIfAny(FromD)) { | 279 | 0 | ToD = nullptr; | 280 | 0 | return true; // Already imported but with error. | 281 | 0 | } | 282 | 2 | ToD = cast_or_null<ToDeclT>(Importer.GetAlreadyImportedOrNull(FromD)); | 283 | 2 | if (ToD) | 284 | 0 | return true; // Already imported. | 285 | 2 | ToD = CreateFun(std::forward<Args>(args)...); | 286 | | // Keep track of imported Decls. | 287 | 2 | Importer.RegisterImportedDecl(FromD, ToD); | 288 | 2 | InitializeImportedDecl(FromD, ToD); | 289 | 2 | return false; // A new Decl is created. | 290 | 2 | } |
bool clang::ASTNodeImporter::GetImportedOrCreateSpecialDecl<clang::UnresolvedUsingTypenameDecl, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::UnresolvedUsingTypenameDecl>, clang::UnresolvedUsingTypenameDecl, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::NestedNameSpecifierLoc&, clang::SourceLocation&, clang::DeclarationName&, clang::SourceLocation&>(clang::UnresolvedUsingTypenameDecl*&, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::UnresolvedUsingTypenameDecl>, clang::UnresolvedUsingTypenameDecl*, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::NestedNameSpecifierLoc&, clang::SourceLocation&, clang::DeclarationName&, clang::SourceLocation&) Line | Count | Source | 277 | 280 | FromDeclT *FromD, Args &&... args) { | 278 | 280 | if (Importer.getImportDeclErrorIfAny(FromD)) { | 279 | 0 | ToD = nullptr; | 280 | 0 | return true; // Already imported but with error. | 281 | 0 | } | 282 | 280 | ToD = cast_or_null<ToDeclT>(Importer.GetAlreadyImportedOrNull(FromD)); | 283 | 280 | if (ToD) | 284 | 12 | return true; // Already imported. | 285 | 268 | ToD = CreateFun(std::forward<Args>(args)...); | 286 | | // Keep track of imported Decls. | 287 | 268 | Importer.RegisterImportedDecl(FromD, ToD); | 288 | 268 | InitializeImportedDecl(FromD, ToD); | 289 | 268 | return false; // A new Decl is created. | 290 | 280 | } |
bool clang::ASTNodeImporter::GetImportedOrCreateSpecialDecl<clang::ObjCInterfaceDecl, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::ObjCInterfaceDecl>, clang::ObjCInterfaceDecl, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::IdentifierInfo*, std::nullptr_t, std::nullptr_t, clang::SourceLocation&, bool>(clang::ObjCInterfaceDecl*&, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::ObjCInterfaceDecl>, clang::ObjCInterfaceDecl*, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::IdentifierInfo*&&, std::nullptr_t&&, std::nullptr_t&&, clang::SourceLocation&, bool&&) Line | Count | Source | 277 | 2.32k | FromDeclT *FromD, Args &&... args) { | 278 | 2.32k | if (Importer.getImportDeclErrorIfAny(FromD)) { | 279 | 0 | ToD = nullptr; | 280 | 0 | return true; // Already imported but with error. | 281 | 0 | } | 282 | 2.32k | ToD = cast_or_null<ToDeclT>(Importer.GetAlreadyImportedOrNull(FromD)); | 283 | 2.32k | if (ToD) | 284 | 0 | return true; // Already imported. | 285 | 2.32k | ToD = CreateFun(std::forward<Args>(args)...); | 286 | | // Keep track of imported Decls. | 287 | 2.32k | Importer.RegisterImportedDecl(FromD, ToD); | 288 | 2.32k | InitializeImportedDecl(FromD, ToD); | 289 | 2.32k | return false; // A new Decl is created. | 290 | 2.32k | } |
bool clang::ASTNodeImporter::GetImportedOrCreateSpecialDecl<clang::ObjCCategoryImplDecl, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::ObjCCategoryImplDecl>, clang::ObjCCategoryImplDecl, clang::ASTContext&, clang::DeclContext*&, clang::IdentifierInfo*, clang::ObjCInterfaceDecl*, clang::SourceLocation&, clang::SourceLocation&, clang::SourceLocation&>(clang::ObjCCategoryImplDecl*&, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::ObjCCategoryImplDecl>, clang::ObjCCategoryImplDecl*, clang::ASTContext&, clang::DeclContext*&, clang::IdentifierInfo*&&, clang::ObjCInterfaceDecl*&&, clang::SourceLocation&, clang::SourceLocation&, clang::SourceLocation&) Line | Count | Source | 277 | 4 | FromDeclT *FromD, Args &&... args) { | 278 | 4 | if (Importer.getImportDeclErrorIfAny(FromD)) { | 279 | 0 | ToD = nullptr; | 280 | 0 | return true; // Already imported but with error. | 281 | 0 | } | 282 | 4 | ToD = cast_or_null<ToDeclT>(Importer.GetAlreadyImportedOrNull(FromD)); | 283 | 4 | if (ToD) | 284 | 0 | return true; // Already imported. | 285 | 4 | ToD = CreateFun(std::forward<Args>(args)...); | 286 | | // Keep track of imported Decls. | 287 | 4 | Importer.RegisterImportedDecl(FromD, ToD); | 288 | 4 | InitializeImportedDecl(FromD, ToD); | 289 | 4 | return false; // A new Decl is created. | 290 | 4 | } |
bool clang::ASTNodeImporter::GetImportedOrCreateSpecialDecl<clang::ObjCImplementationDecl, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::ObjCImplementationDecl>, clang::ObjCImplementationDecl, clang::ASTContext&, clang::DeclContext*&, clang::ObjCInterfaceDecl*&, clang::ObjCInterfaceDecl*&, clang::SourceLocation&, clang::SourceLocation&, clang::SourceLocation&, clang::SourceLocation&, clang::SourceLocation&>(clang::ObjCImplementationDecl*&, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::ObjCImplementationDecl>, clang::ObjCImplementationDecl*, clang::ASTContext&, clang::DeclContext*&, clang::ObjCInterfaceDecl*&, clang::ObjCInterfaceDecl*&, clang::SourceLocation&, clang::SourceLocation&, clang::SourceLocation&, clang::SourceLocation&, clang::SourceLocation&) Line | Count | Source | 277 | 8 | FromDeclT *FromD, Args &&... args) { | 278 | 8 | if (Importer.getImportDeclErrorIfAny(FromD)) { | 279 | 0 | ToD = nullptr; | 280 | 0 | return true; // Already imported but with error. | 281 | 0 | } | 282 | 8 | ToD = cast_or_null<ToDeclT>(Importer.GetAlreadyImportedOrNull(FromD)); | 283 | 8 | if (ToD) | 284 | 0 | return true; // Already imported. | 285 | 8 | ToD = CreateFun(std::forward<Args>(args)...); | 286 | | // Keep track of imported Decls. | 287 | 8 | Importer.RegisterImportedDecl(FromD, ToD); | 288 | 8 | InitializeImportedDecl(FromD, ToD); | 289 | 8 | return false; // A new Decl is created. | 290 | 8 | } |
bool clang::ASTNodeImporter::GetImportedOrCreateSpecialDecl<clang::ObjCPropertyDecl, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::ObjCPropertyDecl>, clang::ObjCPropertyDecl, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::IdentifierInfo*, clang::SourceLocation&, clang::SourceLocation&, clang::QualType&, clang::TypeSourceInfo*&, clang::ObjCPropertyDecl::PropertyControl>(clang::ObjCPropertyDecl*&, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::ObjCPropertyDecl>, clang::ObjCPropertyDecl*, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::IdentifierInfo*&&, clang::SourceLocation&, clang::SourceLocation&, clang::QualType&, clang::TypeSourceInfo*&, clang::ObjCPropertyDecl::PropertyControl&&) Line | Count | Source | 277 | 2.31k | FromDeclT *FromD, Args &&... args) { | 278 | 2.31k | if (Importer.getImportDeclErrorIfAny(FromD)) { | 279 | 0 | ToD = nullptr; | 280 | 0 | return true; // Already imported but with error. | 281 | 0 | } | 282 | 2.31k | ToD = cast_or_null<ToDeclT>(Importer.GetAlreadyImportedOrNull(FromD)); | 283 | 2.31k | if (ToD) | 284 | 0 | return true; // Already imported. | 285 | 2.31k | ToD = CreateFun(std::forward<Args>(args)...); | 286 | | // Keep track of imported Decls. | 287 | 2.31k | Importer.RegisterImportedDecl(FromD, ToD); | 288 | 2.31k | InitializeImportedDecl(FromD, ToD); | 289 | 2.31k | return false; // A new Decl is created. | 290 | 2.31k | } |
bool clang::ASTNodeImporter::GetImportedOrCreateSpecialDecl<clang::ObjCPropertyImplDecl, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::ObjCPropertyImplDecl>, clang::ObjCPropertyImplDecl, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::ObjCPropertyDecl*&, clang::ObjCPropertyImplDecl::Kind, clang::ObjCIvarDecl*&, clang::SourceLocation&>(clang::ObjCPropertyImplDecl*&, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::ObjCPropertyImplDecl>, clang::ObjCPropertyImplDecl*, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::ObjCPropertyDecl*&, clang::ObjCPropertyImplDecl::Kind&&, clang::ObjCIvarDecl*&, clang::SourceLocation&) Line | Count | Source | 277 | 4 | FromDeclT *FromD, Args &&... args) { | 278 | 4 | if (Importer.getImportDeclErrorIfAny(FromD)) { | 279 | 0 | ToD = nullptr; | 280 | 0 | return true; // Already imported but with error. | 281 | 0 | } | 282 | 4 | ToD = cast_or_null<ToDeclT>(Importer.GetAlreadyImportedOrNull(FromD)); | 283 | 4 | if (ToD) | 284 | 0 | return true; // Already imported. | 285 | 4 | ToD = CreateFun(std::forward<Args>(args)...); | 286 | | // Keep track of imported Decls. | 287 | 4 | Importer.RegisterImportedDecl(FromD, ToD); | 288 | 4 | InitializeImportedDecl(FromD, ToD); | 289 | 4 | return false; // A new Decl is created. | 290 | 4 | } |
bool clang::ASTNodeImporter::GetImportedOrCreateSpecialDecl<clang::TemplateTypeParmDecl, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::TemplateTypeParmDecl>, clang::TemplateTypeParmDecl, clang::ASTContext&, clang::TranslationUnitDecl*, clang::SourceLocation&, clang::SourceLocation&, unsigned int, unsigned int, clang::IdentifierInfo*, bool, bool, bool>(clang::TemplateTypeParmDecl*&, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::TemplateTypeParmDecl>, clang::TemplateTypeParmDecl*, clang::ASTContext&, clang::TranslationUnitDecl*&&, clang::SourceLocation&, clang::SourceLocation&, unsigned int&&, unsigned int&&, clang::IdentifierInfo*&&, bool&&, bool&&, bool&&) Line | Count | Source | 277 | 626k | FromDeclT *FromD, Args &&... args) { | 278 | 626k | if (Importer.getImportDeclErrorIfAny(FromD)) { | 279 | 0 | ToD = nullptr; | 280 | 0 | return true; // Already imported but with error. | 281 | 0 | } | 282 | 626k | ToD = cast_or_null<ToDeclT>(Importer.GetAlreadyImportedOrNull(FromD)); | 283 | 626k | if (ToD) | 284 | 0 | return true; // Already imported. | 285 | 626k | ToD = CreateFun(std::forward<Args>(args)...); | 286 | | // Keep track of imported Decls. | 287 | 626k | Importer.RegisterImportedDecl(FromD, ToD); | 288 | 626k | InitializeImportedDecl(FromD, ToD); | 289 | 626k | return false; // A new Decl is created. | 290 | 626k | } |
bool clang::ASTNodeImporter::GetImportedOrCreateSpecialDecl<clang::NonTypeTemplateParmDecl, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::NonTypeTemplateParmDecl>, clang::NonTypeTemplateParmDecl, clang::ASTContext&, clang::TranslationUnitDecl*, clang::SourceLocation&, clang::SourceLocation&, unsigned int, unsigned int, clang::IdentifierInfo*, clang::QualType&, bool, clang::TypeSourceInfo*&>(clang::NonTypeTemplateParmDecl*&, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::NonTypeTemplateParmDecl>, clang::NonTypeTemplateParmDecl*, clang::ASTContext&, clang::TranslationUnitDecl*&&, clang::SourceLocation&, clang::SourceLocation&, unsigned int&&, unsigned int&&, clang::IdentifierInfo*&&, clang::QualType&, bool&&, clang::TypeSourceInfo*&) Line | Count | Source | 277 | 93.3k | FromDeclT *FromD, Args &&... args) { | 278 | 93.3k | if (Importer.getImportDeclErrorIfAny(FromD)) { | 279 | 0 | ToD = nullptr; | 280 | 0 | return true; // Already imported but with error. | 281 | 0 | } | 282 | 93.3k | ToD = cast_or_null<ToDeclT>(Importer.GetAlreadyImportedOrNull(FromD)); | 283 | 93.3k | if (ToD) | 284 | 0 | return true; // Already imported. | 285 | 93.3k | ToD = CreateFun(std::forward<Args>(args)...); | 286 | | // Keep track of imported Decls. | 287 | 93.3k | Importer.RegisterImportedDecl(FromD, ToD); | 288 | 93.3k | InitializeImportedDecl(FromD, ToD); | 289 | 93.3k | return false; // A new Decl is created. | 290 | 93.3k | } |
bool clang::ASTNodeImporter::GetImportedOrCreateSpecialDecl<clang::TemplateTemplateParmDecl, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::TemplateTemplateParmDecl>, clang::TemplateTemplateParmDecl, clang::ASTContext&, clang::TranslationUnitDecl*, clang::SourceLocation&, unsigned int, unsigned int, bool, clang::IdentifierInfo*, clang::TemplateParameterList*&>(clang::TemplateTemplateParmDecl*&, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::TemplateTemplateParmDecl>, clang::TemplateTemplateParmDecl*, clang::ASTContext&, clang::TranslationUnitDecl*&&, clang::SourceLocation&, unsigned int&&, unsigned int&&, bool&&, clang::IdentifierInfo*&&, clang::TemplateParameterList*&) Line | Count | Source | 277 | 1.77k | FromDeclT *FromD, Args &&... args) { | 278 | 1.77k | if (Importer.getImportDeclErrorIfAny(FromD)) { | 279 | 0 | ToD = nullptr; | 280 | 0 | return true; // Already imported but with error. | 281 | 0 | } | 282 | 1.77k | ToD = cast_or_null<ToDeclT>(Importer.GetAlreadyImportedOrNull(FromD)); | 283 | 1.77k | if (ToD) | 284 | 0 | return true; // Already imported. | 285 | 1.77k | ToD = CreateFun(std::forward<Args>(args)...); | 286 | | // Keep track of imported Decls. | 287 | 1.77k | Importer.RegisterImportedDecl(FromD, ToD); | 288 | 1.77k | InitializeImportedDecl(FromD, ToD); | 289 | 1.77k | return false; // A new Decl is created. | 290 | 1.77k | } |
bool clang::ASTNodeImporter::GetImportedOrCreateSpecialDecl<clang::ClassTemplateDecl, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::ClassTemplateDecl>, clang::ClassTemplateDecl, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::DeclarationName&, clang::TemplateParameterList*&, clang::CXXRecordDecl*&>(clang::ClassTemplateDecl*&, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::ClassTemplateDecl>, clang::ClassTemplateDecl*, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::DeclarationName&, clang::TemplateParameterList*&, clang::CXXRecordDecl*&) Line | Count | Source | 277 | 148k | FromDeclT *FromD, Args &&... args) { | 278 | 148k | if (Importer.getImportDeclErrorIfAny(FromD)) { | 279 | 0 | ToD = nullptr; | 280 | 0 | return true; // Already imported but with error. | 281 | 0 | } | 282 | 148k | ToD = cast_or_null<ToDeclT>(Importer.GetAlreadyImportedOrNull(FromD)); | 283 | 148k | if (ToD) | 284 | 74.3k | return true; // Already imported. | 285 | 74.4k | ToD = CreateFun(std::forward<Args>(args)...); | 286 | | // Keep track of imported Decls. | 287 | 74.4k | Importer.RegisterImportedDecl(FromD, ToD); | 288 | 74.4k | InitializeImportedDecl(FromD, ToD); | 289 | 74.4k | return false; // A new Decl is created. | 290 | 148k | } |
bool clang::ASTNodeImporter::GetImportedOrCreateSpecialDecl<clang::ClassTemplateSpecializationDecl, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::ClassTemplatePartialSpecializationDecl>, clang::ClassTemplateSpecializationDecl, clang::ASTContext&, clang::TagTypeKind, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::TemplateParameterList*&, clang::ClassTemplateDecl*&, llvm::ArrayRef<clang::TemplateArgument>, clang::TemplateArgumentListInfo&, clang::QualType&, clang::ClassTemplatePartialSpecializationDecl*>(clang::ClassTemplateSpecializationDecl*&, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::ClassTemplatePartialSpecializationDecl>, clang::ClassTemplateSpecializationDecl*, clang::ASTContext&, clang::TagTypeKind&&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::TemplateParameterList*&, clang::ClassTemplateDecl*&, llvm::ArrayRef<clang::TemplateArgument>&&, clang::TemplateArgumentListInfo&, clang::QualType&, clang::ClassTemplatePartialSpecializationDecl*&&) Line | Count | Source | 277 | 970 | FromDeclT *FromD, Args &&... args) { | 278 | 970 | if (Importer.getImportDeclErrorIfAny(FromD)) { | 279 | 0 | ToD = nullptr; | 280 | 0 | return true; // Already imported but with error. | 281 | 0 | } | 282 | 970 | ToD = cast_or_null<ToDeclT>(Importer.GetAlreadyImportedOrNull(FromD)); | 283 | 970 | if (ToD) | 284 | 0 | return true; // Already imported. | 285 | 970 | ToD = CreateFun(std::forward<Args>(args)...); | 286 | | // Keep track of imported Decls. | 287 | 970 | Importer.RegisterImportedDecl(FromD, ToD); | 288 | 970 | InitializeImportedDecl(FromD, ToD); | 289 | 970 | return false; // A new Decl is created. | 290 | 970 | } |
bool clang::ASTNodeImporter::GetImportedOrCreateSpecialDecl<clang::ClassTemplateSpecializationDecl, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::ClassTemplateSpecializationDecl>, clang::ClassTemplateSpecializationDecl, clang::ASTContext&, clang::TagTypeKind, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::ClassTemplateDecl*&, llvm::SmallVector<clang::TemplateArgument, 2u>&, clang::ClassTemplateSpecializationDecl*&>(clang::ClassTemplateSpecializationDecl*&, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::ClassTemplateSpecializationDecl>, clang::ClassTemplateSpecializationDecl*, clang::ASTContext&, clang::TagTypeKind&&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::ClassTemplateDecl*&, llvm::SmallVector<clang::TemplateArgument, 2u>&, clang::ClassTemplateSpecializationDecl*&) Line | Count | Source | 277 | 91.0k | FromDeclT *FromD, Args &&... args) { | 278 | 91.0k | if (Importer.getImportDeclErrorIfAny(FromD)) { | 279 | 0 | ToD = nullptr; | 280 | 0 | return true; // Already imported but with error. | 281 | 0 | } | 282 | 91.0k | ToD = cast_or_null<ToDeclT>(Importer.GetAlreadyImportedOrNull(FromD)); | 283 | 91.0k | if (ToD) | 284 | 6 | return true; // Already imported. | 285 | 91.0k | ToD = CreateFun(std::forward<Args>(args)...); | 286 | | // Keep track of imported Decls. | 287 | 91.0k | Importer.RegisterImportedDecl(FromD, ToD); | 288 | 91.0k | InitializeImportedDecl(FromD, ToD); | 289 | 91.0k | return false; // A new Decl is created. | 290 | 91.0k | } |
bool clang::ASTNodeImporter::GetImportedOrCreateSpecialDecl<clang::VarTemplateDecl, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::VarTemplateDecl>, clang::VarTemplateDecl, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::DeclarationName&, clang::TemplateParameterList*&, clang::VarDecl*&>(clang::VarTemplateDecl*&, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::VarTemplateDecl>, clang::VarTemplateDecl*, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::DeclarationName&, clang::TemplateParameterList*&, clang::VarDecl*&) Line | Count | Source | 277 | 414 | FromDeclT *FromD, Args &&... args) { | 278 | 414 | if (Importer.getImportDeclErrorIfAny(FromD)) { | 279 | 0 | ToD = nullptr; | 280 | 0 | return true; // Already imported but with error. | 281 | 0 | } | 282 | 414 | ToD = cast_or_null<ToDeclT>(Importer.GetAlreadyImportedOrNull(FromD)); | 283 | 414 | if (ToD) | 284 | 195 | return true; // Already imported. | 285 | 219 | ToD = CreateFun(std::forward<Args>(args)...); | 286 | | // Keep track of imported Decls. | 287 | 219 | Importer.RegisterImportedDecl(FromD, ToD); | 288 | 219 | InitializeImportedDecl(FromD, ToD); | 289 | 219 | return false; // A new Decl is created. | 290 | 414 | } |
bool clang::ASTNodeImporter::GetImportedOrCreateSpecialDecl<clang::VarTemplatePartialSpecializationDecl, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::VarTemplatePartialSpecializationDecl>, clang::VarTemplateSpecializationDecl, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::TemplateParameterList*&, clang::VarTemplateDecl*&, clang::QualType&, clang::TypeSourceInfo*&, clang::StorageClass, llvm::SmallVector<clang::TemplateArgument, 2u>&, clang::TemplateArgumentListInfo&>(clang::VarTemplatePartialSpecializationDecl*&, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::VarTemplatePartialSpecializationDecl>, clang::VarTemplateSpecializationDecl*, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::TemplateParameterList*&, clang::VarTemplateDecl*&, clang::QualType&, clang::TypeSourceInfo*&, clang::StorageClass&&, llvm::SmallVector<clang::TemplateArgument, 2u>&, clang::TemplateArgumentListInfo&) Line | Count | Source | 277 | 10 | FromDeclT *FromD, Args &&... args) { | 278 | 10 | if (Importer.getImportDeclErrorIfAny(FromD)) { | 279 | 0 | ToD = nullptr; | 280 | 0 | return true; // Already imported but with error. | 281 | 0 | } | 282 | 10 | ToD = cast_or_null<ToDeclT>(Importer.GetAlreadyImportedOrNull(FromD)); | 283 | 10 | if (ToD) | 284 | 0 | return true; // Already imported. | 285 | 10 | ToD = CreateFun(std::forward<Args>(args)...); | 286 | | // Keep track of imported Decls. | 287 | 10 | Importer.RegisterImportedDecl(FromD, ToD); | 288 | 10 | InitializeImportedDecl(FromD, ToD); | 289 | 10 | return false; // A new Decl is created. | 290 | 10 | } |
bool clang::ASTNodeImporter::GetImportedOrCreateSpecialDecl<clang::VarTemplateSpecializationDecl, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::VarTemplateSpecializationDecl>, clang::VarTemplateSpecializationDecl, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::VarTemplateDecl*&, clang::QualType&, clang::TypeSourceInfo*&, clang::StorageClass, llvm::SmallVector<clang::TemplateArgument, 2u>&>(clang::VarTemplateSpecializationDecl*&, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::VarTemplateSpecializationDecl>, clang::VarTemplateSpecializationDecl*, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::SourceLocation&, clang::VarTemplateDecl*&, clang::QualType&, clang::TypeSourceInfo*&, clang::StorageClass&&, llvm::SmallVector<clang::TemplateArgument, 2u>&) Line | Count | Source | 277 | 11 | FromDeclT *FromD, Args &&... args) { | 278 | 11 | if (Importer.getImportDeclErrorIfAny(FromD)) { | 279 | 0 | ToD = nullptr; | 280 | 0 | return true; // Already imported but with error. | 281 | 0 | } | 282 | 11 | ToD = cast_or_null<ToDeclT>(Importer.GetAlreadyImportedOrNull(FromD)); | 283 | 11 | if (ToD) | 284 | 0 | return true; // Already imported. | 285 | 11 | ToD = CreateFun(std::forward<Args>(args)...); | 286 | | // Keep track of imported Decls. | 287 | 11 | Importer.RegisterImportedDecl(FromD, ToD); | 288 | 11 | InitializeImportedDecl(FromD, ToD); | 289 | 11 | return false; // A new Decl is created. | 290 | 11 | } |
bool clang::ASTNodeImporter::GetImportedOrCreateSpecialDecl<clang::FunctionTemplateDecl, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::FunctionTemplateDecl>, clang::FunctionTemplateDecl, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::DeclarationName&, clang::TemplateParameterList*&, clang::FunctionDecl*&>(clang::FunctionTemplateDecl*&, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::FunctionTemplateDecl>, clang::FunctionTemplateDecl*, clang::ASTContext&, clang::DeclContext*&, clang::SourceLocation&, clang::DeclarationName&, clang::TemplateParameterList*&, clang::FunctionDecl*&) Line | Count | Source | 277 | 345k | FromDeclT *FromD, Args &&... args) { | 278 | 345k | if (Importer.getImportDeclErrorIfAny(FromD)) { | 279 | 0 | ToD = nullptr; | 280 | 0 | return true; // Already imported but with error. | 281 | 0 | } | 282 | 345k | ToD = cast_or_null<ToDeclT>(Importer.GetAlreadyImportedOrNull(FromD)); | 283 | 345k | if (ToD) | 284 | 157k | return true; // Already imported. | 285 | 188k | ToD = CreateFun(std::forward<Args>(args)...); | 286 | | // Keep track of imported Decls. | 287 | 188k | Importer.RegisterImportedDecl(FromD, ToD); | 288 | 188k | InitializeImportedDecl(FromD, ToD); | 289 | 188k | return false; // A new Decl is created. | 290 | 345k | } |
bool clang::ASTNodeImporter::GetImportedOrCreateSpecialDecl<clang::LifetimeExtendedTemporaryDecl, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::LifetimeExtendedTemporaryDecl>, clang::LifetimeExtendedTemporaryDecl, clang::Expr*&, clang::ValueDecl*&, unsigned int>(clang::LifetimeExtendedTemporaryDecl*&, clang::ASTNodeImporter::CallOverloadedCreateFun<clang::LifetimeExtendedTemporaryDecl>, clang::LifetimeExtendedTemporaryDecl*, clang::Expr*&, clang::ValueDecl*&, unsigned int&&) Line | Count | Source | 277 | 2 | FromDeclT *FromD, Args &&... args) { | 278 | 2 | if (Importer.getImportDeclErrorIfAny(FromD)) { | 279 | 0 | ToD = nullptr; | 280 | 0 | return true; // Already imported but with error. | 281 | 0 | } | 282 | 2 | ToD = cast_or_null<ToDeclT>(Importer.GetAlreadyImportedOrNull(FromD)); | 283 | 2 | if (ToD) | 284 | 0 | return true; // Already imported. | 285 | 2 | ToD = CreateFun(std::forward<Args>(args)...); | 286 | | // Keep track of imported Decls. | 287 | 2 | Importer.RegisterImportedDecl(FromD, ToD); | 288 | 2 | InitializeImportedDecl(FromD, ToD); | 289 | 2 | return false; // A new Decl is created. | 290 | 2 | } |
|
291 | | |
292 | 4.39M | void InitializeImportedDecl(Decl *FromD, Decl *ToD) { |
293 | 4.39M | ToD->IdentifierNamespace = FromD->IdentifierNamespace; |
294 | 4.39M | if (FromD->isUsed()) |
295 | 115k | ToD->setIsUsed(); |
296 | 4.39M | if (FromD->isImplicit()) |
297 | 197k | ToD->setImplicit(); |
298 | 4.39M | } |
299 | | |
300 | | // Check if we have found an existing definition. Returns with that |
301 | | // definition if yes, otherwise returns null. |
302 | 88.7k | Decl *FindAndMapDefinition(FunctionDecl *D, FunctionDecl *FoundFunction) { |
303 | 88.7k | const FunctionDecl *Definition = nullptr; |
304 | 88.7k | if (D->doesThisDeclarationHaveABody() && |
305 | 88.7k | FoundFunction->hasBody(Definition)58.3k ) |
306 | 3.97k | return Importer.MapImported(D, const_cast<FunctionDecl *>(Definition)); |
307 | 84.7k | return nullptr; |
308 | 88.7k | } |
309 | | |
310 | 1.56M | void addDeclToContexts(Decl *FromD, Decl *ToD) { |
311 | 1.56M | if (Importer.isMinimalImport()) { |
312 | | // In minimal import case the decl must be added even if it is not |
313 | | // contained in original context, for LLDB compatibility. |
314 | | // FIXME: Check if a better solution is possible. |
315 | 1.56M | if (!FromD->getDescribedTemplate() && |
316 | 1.56M | FromD->getFriendObjectKind() == Decl::FOK_None1.26M ) |
317 | 1.24M | ToD->getLexicalDeclContext()->addDeclInternal(ToD); |
318 | 1.56M | return; |
319 | 1.56M | } |
320 | | |
321 | 7.39k | DeclContext *FromDC = FromD->getDeclContext(); |
322 | 7.39k | DeclContext *FromLexicalDC = FromD->getLexicalDeclContext(); |
323 | 7.39k | DeclContext *ToDC = ToD->getDeclContext(); |
324 | 7.39k | DeclContext *ToLexicalDC = ToD->getLexicalDeclContext(); |
325 | | |
326 | 7.39k | bool Visible = false; |
327 | 7.39k | if (FromDC->containsDeclAndLoad(FromD)) { |
328 | 5.78k | ToDC->addDeclInternal(ToD); |
329 | 5.78k | Visible = true; |
330 | 5.78k | } |
331 | 7.39k | if (ToDC != ToLexicalDC && FromLexicalDC->containsDeclAndLoad(FromD)213 ) { |
332 | 96 | ToLexicalDC->addDeclInternal(ToD); |
333 | 96 | Visible = true; |
334 | 96 | } |
335 | | |
336 | | // If the Decl was added to any context, it was made already visible. |
337 | | // Otherwise it is still possible that it should be visible. |
338 | 7.39k | if (!Visible) { |
339 | 1.50k | if (auto *FromNamed = dyn_cast<NamedDecl>(FromD)) { |
340 | 1.50k | auto *ToNamed = cast<NamedDecl>(ToD); |
341 | 1.50k | DeclContextLookupResult FromLookup = |
342 | 1.50k | FromDC->lookup(FromNamed->getDeclName()); |
343 | 1.50k | if (llvm::is_contained(FromLookup, FromNamed)) |
344 | 29 | ToDC->makeDeclVisibleInContext(ToNamed); |
345 | 1.50k | } |
346 | 1.50k | } |
347 | 7.39k | } |
348 | | |
349 | | void updateLookupTableForTemplateParameters(TemplateParameterList &Params, |
350 | 83.8k | DeclContext *OldDC) { |
351 | 83.8k | ASTImporterLookupTable *LT = Importer.SharedState->getLookupTable(); |
352 | 83.8k | if (!LT) |
353 | 83.3k | return; |
354 | | |
355 | 535 | for (NamedDecl *TP : Params) |
356 | 561 | LT->update(TP, OldDC); |
357 | 535 | } |
358 | | |
359 | 83.8k | void updateLookupTableForTemplateParameters(TemplateParameterList &Params) { |
360 | 83.8k | updateLookupTableForTemplateParameters( |
361 | 83.8k | Params, Importer.getToContext().getTranslationUnitDecl()); |
362 | 83.8k | } |
363 | | |
364 | | public: |
365 | 18.7M | explicit ASTNodeImporter(ASTImporter &Importer) : Importer(Importer) {} |
366 | | |
367 | | using TypeVisitor<ASTNodeImporter, ExpectedType>::Visit; |
368 | | using DeclVisitor<ASTNodeImporter, ExpectedDecl>::Visit; |
369 | | using StmtVisitor<ASTNodeImporter, ExpectedStmt>::Visit; |
370 | | |
371 | | // Importing types |
372 | | ExpectedType VisitType(const Type *T); |
373 | | ExpectedType VisitAtomicType(const AtomicType *T); |
374 | | ExpectedType VisitBuiltinType(const BuiltinType *T); |
375 | | ExpectedType VisitDecayedType(const DecayedType *T); |
376 | | ExpectedType VisitComplexType(const ComplexType *T); |
377 | | ExpectedType VisitPointerType(const PointerType *T); |
378 | | ExpectedType VisitBlockPointerType(const BlockPointerType *T); |
379 | | ExpectedType VisitLValueReferenceType(const LValueReferenceType *T); |
380 | | ExpectedType VisitRValueReferenceType(const RValueReferenceType *T); |
381 | | ExpectedType VisitMemberPointerType(const MemberPointerType *T); |
382 | | ExpectedType VisitConstantArrayType(const ConstantArrayType *T); |
383 | | ExpectedType VisitIncompleteArrayType(const IncompleteArrayType *T); |
384 | | ExpectedType VisitVariableArrayType(const VariableArrayType *T); |
385 | | ExpectedType VisitDependentSizedArrayType(const DependentSizedArrayType *T); |
386 | | // FIXME: DependentSizedExtVectorType |
387 | | ExpectedType VisitVectorType(const VectorType *T); |
388 | | ExpectedType VisitExtVectorType(const ExtVectorType *T); |
389 | | ExpectedType VisitFunctionNoProtoType(const FunctionNoProtoType *T); |
390 | | ExpectedType VisitFunctionProtoType(const FunctionProtoType *T); |
391 | | ExpectedType VisitUnresolvedUsingType(const UnresolvedUsingType *T); |
392 | | ExpectedType VisitParenType(const ParenType *T); |
393 | | ExpectedType VisitTypedefType(const TypedefType *T); |
394 | | ExpectedType VisitTypeOfExprType(const TypeOfExprType *T); |
395 | | // FIXME: DependentTypeOfExprType |
396 | | ExpectedType VisitTypeOfType(const TypeOfType *T); |
397 | | ExpectedType VisitUsingType(const UsingType *T); |
398 | | ExpectedType VisitDecltypeType(const DecltypeType *T); |
399 | | ExpectedType VisitUnaryTransformType(const UnaryTransformType *T); |
400 | | ExpectedType VisitAutoType(const AutoType *T); |
401 | | ExpectedType VisitDeducedTemplateSpecializationType( |
402 | | const DeducedTemplateSpecializationType *T); |
403 | | ExpectedType VisitInjectedClassNameType(const InjectedClassNameType *T); |
404 | | // FIXME: DependentDecltypeType |
405 | | ExpectedType VisitRecordType(const RecordType *T); |
406 | | ExpectedType VisitEnumType(const EnumType *T); |
407 | | ExpectedType VisitAttributedType(const AttributedType *T); |
408 | | ExpectedType VisitTemplateTypeParmType(const TemplateTypeParmType *T); |
409 | | ExpectedType VisitSubstTemplateTypeParmType( |
410 | | const SubstTemplateTypeParmType *T); |
411 | | ExpectedType |
412 | | VisitSubstTemplateTypeParmPackType(const SubstTemplateTypeParmPackType *T); |
413 | | ExpectedType VisitTemplateSpecializationType( |
414 | | const TemplateSpecializationType *T); |
415 | | ExpectedType VisitElaboratedType(const ElaboratedType *T); |
416 | | ExpectedType VisitDependentNameType(const DependentNameType *T); |
417 | | ExpectedType VisitPackExpansionType(const PackExpansionType *T); |
418 | | ExpectedType VisitDependentTemplateSpecializationType( |
419 | | const DependentTemplateSpecializationType *T); |
420 | | ExpectedType VisitObjCInterfaceType(const ObjCInterfaceType *T); |
421 | | ExpectedType VisitObjCObjectType(const ObjCObjectType *T); |
422 | | ExpectedType VisitObjCObjectPointerType(const ObjCObjectPointerType *T); |
423 | | |
424 | | // Importing declarations |
425 | | Error ImportDeclParts(NamedDecl *D, DeclarationName &Name, NamedDecl *&ToD, |
426 | | SourceLocation &Loc); |
427 | | Error ImportDeclParts( |
428 | | NamedDecl *D, DeclContext *&DC, DeclContext *&LexicalDC, |
429 | | DeclarationName &Name, NamedDecl *&ToD, SourceLocation &Loc); |
430 | | Error ImportDefinitionIfNeeded(Decl *FromD, Decl *ToD = nullptr); |
431 | | Error ImportDeclarationNameLoc( |
432 | | const DeclarationNameInfo &From, DeclarationNameInfo &To); |
433 | | Error ImportDeclContext(DeclContext *FromDC, bool ForceImport = false); |
434 | | Error ImportDeclContext( |
435 | | Decl *From, DeclContext *&ToDC, DeclContext *&ToLexicalDC); |
436 | | Error ImportImplicitMethods(const CXXRecordDecl *From, CXXRecordDecl *To); |
437 | | |
438 | | Expected<CXXCastPath> ImportCastPath(CastExpr *E); |
439 | | Expected<APValue> ImportAPValue(const APValue &FromValue); |
440 | | |
441 | | using Designator = DesignatedInitExpr::Designator; |
442 | | |
443 | | /// What we should import from the definition. |
444 | | enum ImportDefinitionKind { |
445 | | /// Import the default subset of the definition, which might be |
446 | | /// nothing (if minimal import is set) or might be everything (if minimal |
447 | | /// import is not set). |
448 | | IDK_Default, |
449 | | /// Import everything. |
450 | | IDK_Everything, |
451 | | /// Import only the bare bones needed to establish a valid |
452 | | /// DeclContext. |
453 | | IDK_Basic |
454 | | }; |
455 | | |
456 | 132k | bool shouldForceImportDeclContext(ImportDefinitionKind IDK) { |
457 | 132k | return IDK == IDK_Everything || |
458 | 132k | (132k IDK == IDK_Default132k && !Importer.isMinimalImport()131k ); |
459 | 132k | } |
460 | | |
461 | | Error ImportInitializer(VarDecl *From, VarDecl *To); |
462 | | Error ImportDefinition( |
463 | | RecordDecl *From, RecordDecl *To, |
464 | | ImportDefinitionKind Kind = IDK_Default); |
465 | | Error ImportDefinition( |
466 | | EnumDecl *From, EnumDecl *To, |
467 | | ImportDefinitionKind Kind = IDK_Default); |
468 | | Error ImportDefinition( |
469 | | ObjCInterfaceDecl *From, ObjCInterfaceDecl *To, |
470 | | ImportDefinitionKind Kind = IDK_Default); |
471 | | Error ImportDefinition( |
472 | | ObjCProtocolDecl *From, ObjCProtocolDecl *To, |
473 | | ImportDefinitionKind Kind = IDK_Default); |
474 | | Error ImportTemplateArguments( |
475 | | const TemplateArgument *FromArgs, unsigned NumFromArgs, |
476 | | SmallVectorImpl<TemplateArgument> &ToArgs); |
477 | | Expected<TemplateArgument> |
478 | | ImportTemplateArgument(const TemplateArgument &From); |
479 | | |
480 | | template <typename InContainerTy> |
481 | | Error ImportTemplateArgumentListInfo( |
482 | | const InContainerTy &Container, TemplateArgumentListInfo &ToTAInfo); |
483 | | |
484 | | template<typename InContainerTy> |
485 | | Error ImportTemplateArgumentListInfo( |
486 | | SourceLocation FromLAngleLoc, SourceLocation FromRAngleLoc, |
487 | | const InContainerTy &Container, TemplateArgumentListInfo &Result); |
488 | | |
489 | | using TemplateArgsTy = SmallVector<TemplateArgument, 8>; |
490 | | using FunctionTemplateAndArgsTy = |
491 | | std::tuple<FunctionTemplateDecl *, TemplateArgsTy>; |
492 | | Expected<FunctionTemplateAndArgsTy> |
493 | | ImportFunctionTemplateWithTemplateArgsFromSpecialization( |
494 | | FunctionDecl *FromFD); |
495 | | Error ImportTemplateParameterLists(const DeclaratorDecl *FromD, |
496 | | DeclaratorDecl *ToD); |
497 | | |
498 | | Error ImportTemplateInformation(FunctionDecl *FromFD, FunctionDecl *ToFD); |
499 | | |
500 | | Error ImportFunctionDeclBody(FunctionDecl *FromFD, FunctionDecl *ToFD); |
501 | | |
502 | | Error ImportDefaultArgOfParmVarDecl(const ParmVarDecl *FromParam, |
503 | | ParmVarDecl *ToParam); |
504 | | |
505 | | Expected<InheritedConstructor> |
506 | | ImportInheritedConstructor(const InheritedConstructor &From); |
507 | | |
508 | | template <typename T> |
509 | | bool hasSameVisibilityContextAndLinkage(T *Found, T *From); |
510 | | |
511 | | bool IsStructuralMatch(Decl *From, Decl *To, bool Complain = true); |
512 | | ExpectedDecl VisitDecl(Decl *D); |
513 | | ExpectedDecl VisitImportDecl(ImportDecl *D); |
514 | | ExpectedDecl VisitEmptyDecl(EmptyDecl *D); |
515 | | ExpectedDecl VisitAccessSpecDecl(AccessSpecDecl *D); |
516 | | ExpectedDecl VisitStaticAssertDecl(StaticAssertDecl *D); |
517 | | ExpectedDecl VisitTranslationUnitDecl(TranslationUnitDecl *D); |
518 | | ExpectedDecl VisitBindingDecl(BindingDecl *D); |
519 | | ExpectedDecl VisitNamespaceDecl(NamespaceDecl *D); |
520 | | ExpectedDecl VisitNamespaceAliasDecl(NamespaceAliasDecl *D); |
521 | | ExpectedDecl VisitTypedefNameDecl(TypedefNameDecl *D, bool IsAlias); |
522 | | ExpectedDecl VisitTypedefDecl(TypedefDecl *D); |
523 | | ExpectedDecl VisitTypeAliasDecl(TypeAliasDecl *D); |
524 | | ExpectedDecl VisitTypeAliasTemplateDecl(TypeAliasTemplateDecl *D); |
525 | | ExpectedDecl VisitLabelDecl(LabelDecl *D); |
526 | | ExpectedDecl VisitEnumDecl(EnumDecl *D); |
527 | | ExpectedDecl VisitRecordDecl(RecordDecl *D); |
528 | | ExpectedDecl VisitEnumConstantDecl(EnumConstantDecl *D); |
529 | | ExpectedDecl VisitFunctionDecl(FunctionDecl *D); |
530 | | ExpectedDecl VisitCXXMethodDecl(CXXMethodDecl *D); |
531 | | ExpectedDecl VisitCXXConstructorDecl(CXXConstructorDecl *D); |
532 | | ExpectedDecl VisitCXXDestructorDecl(CXXDestructorDecl *D); |
533 | | ExpectedDecl VisitCXXConversionDecl(CXXConversionDecl *D); |
534 | | ExpectedDecl VisitCXXDeductionGuideDecl(CXXDeductionGuideDecl *D); |
535 | | ExpectedDecl VisitFieldDecl(FieldDecl *D); |
536 | | ExpectedDecl VisitIndirectFieldDecl(IndirectFieldDecl *D); |
537 | | ExpectedDecl VisitFriendDecl(FriendDecl *D); |
538 | | ExpectedDecl VisitObjCIvarDecl(ObjCIvarDecl *D); |
539 | | ExpectedDecl VisitVarDecl(VarDecl *D); |
540 | | ExpectedDecl VisitImplicitParamDecl(ImplicitParamDecl *D); |
541 | | ExpectedDecl VisitParmVarDecl(ParmVarDecl *D); |
542 | | ExpectedDecl VisitObjCMethodDecl(ObjCMethodDecl *D); |
543 | | ExpectedDecl VisitObjCTypeParamDecl(ObjCTypeParamDecl *D); |
544 | | ExpectedDecl VisitObjCCategoryDecl(ObjCCategoryDecl *D); |
545 | | ExpectedDecl VisitObjCProtocolDecl(ObjCProtocolDecl *D); |
546 | | ExpectedDecl VisitLinkageSpecDecl(LinkageSpecDecl *D); |
547 | | ExpectedDecl VisitUsingDecl(UsingDecl *D); |
548 | | ExpectedDecl VisitUsingShadowDecl(UsingShadowDecl *D); |
549 | | ExpectedDecl VisitUsingDirectiveDecl(UsingDirectiveDecl *D); |
550 | | ExpectedDecl ImportUsingShadowDecls(BaseUsingDecl *D, BaseUsingDecl *ToSI); |
551 | | ExpectedDecl VisitUsingEnumDecl(UsingEnumDecl *D); |
552 | | ExpectedDecl VisitUnresolvedUsingValueDecl(UnresolvedUsingValueDecl *D); |
553 | | ExpectedDecl VisitUnresolvedUsingTypenameDecl(UnresolvedUsingTypenameDecl *D); |
554 | | ExpectedDecl VisitBuiltinTemplateDecl(BuiltinTemplateDecl *D); |
555 | | ExpectedDecl |
556 | | VisitLifetimeExtendedTemporaryDecl(LifetimeExtendedTemporaryDecl *D); |
557 | | |
558 | | Expected<ObjCTypeParamList *> |
559 | | ImportObjCTypeParamList(ObjCTypeParamList *list); |
560 | | |
561 | | ExpectedDecl VisitObjCInterfaceDecl(ObjCInterfaceDecl *D); |
562 | | ExpectedDecl VisitObjCCategoryImplDecl(ObjCCategoryImplDecl *D); |
563 | | ExpectedDecl VisitObjCImplementationDecl(ObjCImplementationDecl *D); |
564 | | ExpectedDecl VisitObjCPropertyDecl(ObjCPropertyDecl *D); |
565 | | ExpectedDecl VisitObjCPropertyImplDecl(ObjCPropertyImplDecl *D); |
566 | | ExpectedDecl VisitTemplateTypeParmDecl(TemplateTypeParmDecl *D); |
567 | | ExpectedDecl VisitNonTypeTemplateParmDecl(NonTypeTemplateParmDecl *D); |
568 | | ExpectedDecl VisitTemplateTemplateParmDecl(TemplateTemplateParmDecl *D); |
569 | | ExpectedDecl VisitClassTemplateDecl(ClassTemplateDecl *D); |
570 | | ExpectedDecl VisitClassTemplateSpecializationDecl( |
571 | | ClassTemplateSpecializationDecl *D); |
572 | | ExpectedDecl VisitVarTemplateDecl(VarTemplateDecl *D); |
573 | | ExpectedDecl VisitVarTemplateSpecializationDecl(VarTemplateSpecializationDecl *D); |
574 | | ExpectedDecl VisitFunctionTemplateDecl(FunctionTemplateDecl *D); |
575 | | |
576 | | // Importing statements |
577 | | ExpectedStmt VisitStmt(Stmt *S); |
578 | | ExpectedStmt VisitGCCAsmStmt(GCCAsmStmt *S); |
579 | | ExpectedStmt VisitDeclStmt(DeclStmt *S); |
580 | | ExpectedStmt VisitNullStmt(NullStmt *S); |
581 | | ExpectedStmt VisitCompoundStmt(CompoundStmt *S); |
582 | | ExpectedStmt VisitCaseStmt(CaseStmt *S); |
583 | | ExpectedStmt VisitDefaultStmt(DefaultStmt *S); |
584 | | ExpectedStmt VisitLabelStmt(LabelStmt *S); |
585 | | ExpectedStmt VisitAttributedStmt(AttributedStmt *S); |
586 | | ExpectedStmt VisitIfStmt(IfStmt *S); |
587 | | ExpectedStmt VisitSwitchStmt(SwitchStmt *S); |
588 | | ExpectedStmt VisitWhileStmt(WhileStmt *S); |
589 | | ExpectedStmt VisitDoStmt(DoStmt *S); |
590 | | ExpectedStmt VisitForStmt(ForStmt *S); |
591 | | ExpectedStmt VisitGotoStmt(GotoStmt *S); |
592 | | ExpectedStmt VisitIndirectGotoStmt(IndirectGotoStmt *S); |
593 | | ExpectedStmt VisitContinueStmt(ContinueStmt *S); |
594 | | ExpectedStmt VisitBreakStmt(BreakStmt *S); |
595 | | ExpectedStmt VisitReturnStmt(ReturnStmt *S); |
596 | | // FIXME: MSAsmStmt |
597 | | // FIXME: SEHExceptStmt |
598 | | // FIXME: SEHFinallyStmt |
599 | | // FIXME: SEHTryStmt |
600 | | // FIXME: SEHLeaveStmt |
601 | | // FIXME: CapturedStmt |
602 | | ExpectedStmt VisitCXXCatchStmt(CXXCatchStmt *S); |
603 | | ExpectedStmt VisitCXXTryStmt(CXXTryStmt *S); |
604 | | ExpectedStmt VisitCXXForRangeStmt(CXXForRangeStmt *S); |
605 | | // FIXME: MSDependentExistsStmt |
606 | | ExpectedStmt VisitObjCForCollectionStmt(ObjCForCollectionStmt *S); |
607 | | ExpectedStmt VisitObjCAtCatchStmt(ObjCAtCatchStmt *S); |
608 | | ExpectedStmt VisitObjCAtFinallyStmt(ObjCAtFinallyStmt *S); |
609 | | ExpectedStmt VisitObjCAtTryStmt(ObjCAtTryStmt *S); |
610 | | ExpectedStmt VisitObjCAtSynchronizedStmt(ObjCAtSynchronizedStmt *S); |
611 | | ExpectedStmt VisitObjCAtThrowStmt(ObjCAtThrowStmt *S); |
612 | | ExpectedStmt VisitObjCAutoreleasePoolStmt(ObjCAutoreleasePoolStmt *S); |
613 | | |
614 | | // Importing expressions |
615 | | ExpectedStmt VisitExpr(Expr *E); |
616 | | ExpectedStmt VisitSourceLocExpr(SourceLocExpr *E); |
617 | | ExpectedStmt VisitVAArgExpr(VAArgExpr *E); |
618 | | ExpectedStmt VisitChooseExpr(ChooseExpr *E); |
619 | | ExpectedStmt VisitShuffleVectorExpr(ShuffleVectorExpr *E); |
620 | | ExpectedStmt VisitGNUNullExpr(GNUNullExpr *E); |
621 | | ExpectedStmt VisitGenericSelectionExpr(GenericSelectionExpr *E); |
622 | | ExpectedStmt VisitPredefinedExpr(PredefinedExpr *E); |
623 | | ExpectedStmt VisitDeclRefExpr(DeclRefExpr *E); |
624 | | ExpectedStmt VisitImplicitValueInitExpr(ImplicitValueInitExpr *E); |
625 | | ExpectedStmt VisitDesignatedInitExpr(DesignatedInitExpr *E); |
626 | | ExpectedStmt VisitCXXNullPtrLiteralExpr(CXXNullPtrLiteralExpr *E); |
627 | | ExpectedStmt VisitIntegerLiteral(IntegerLiteral *E); |
628 | | ExpectedStmt VisitFloatingLiteral(FloatingLiteral *E); |
629 | | ExpectedStmt VisitImaginaryLiteral(ImaginaryLiteral *E); |
630 | | ExpectedStmt VisitFixedPointLiteral(FixedPointLiteral *E); |
631 | | ExpectedStmt VisitCharacterLiteral(CharacterLiteral *E); |
632 | | ExpectedStmt VisitStringLiteral(StringLiteral *E); |
633 | | ExpectedStmt VisitCompoundLiteralExpr(CompoundLiteralExpr *E); |
634 | | ExpectedStmt VisitAtomicExpr(AtomicExpr *E); |
635 | | ExpectedStmt VisitAddrLabelExpr(AddrLabelExpr *E); |
636 | | ExpectedStmt VisitConstantExpr(ConstantExpr *E); |
637 | | ExpectedStmt VisitParenExpr(ParenExpr *E); |
638 | | ExpectedStmt VisitParenListExpr(ParenListExpr *E); |
639 | | ExpectedStmt VisitStmtExpr(StmtExpr *E); |
640 | | ExpectedStmt VisitUnaryOperator(UnaryOperator *E); |
641 | | ExpectedStmt VisitUnaryExprOrTypeTraitExpr(UnaryExprOrTypeTraitExpr *E); |
642 | | ExpectedStmt VisitBinaryOperator(BinaryOperator *E); |
643 | | ExpectedStmt VisitConditionalOperator(ConditionalOperator *E); |
644 | | ExpectedStmt VisitBinaryConditionalOperator(BinaryConditionalOperator *E); |
645 | | ExpectedStmt VisitOpaqueValueExpr(OpaqueValueExpr *E); |
646 | | ExpectedStmt VisitArrayTypeTraitExpr(ArrayTypeTraitExpr *E); |
647 | | ExpectedStmt VisitExpressionTraitExpr(ExpressionTraitExpr *E); |
648 | | ExpectedStmt VisitArraySubscriptExpr(ArraySubscriptExpr *E); |
649 | | ExpectedStmt VisitCompoundAssignOperator(CompoundAssignOperator *E); |
650 | | ExpectedStmt VisitImplicitCastExpr(ImplicitCastExpr *E); |
651 | | ExpectedStmt VisitExplicitCastExpr(ExplicitCastExpr *E); |
652 | | ExpectedStmt VisitOffsetOfExpr(OffsetOfExpr *OE); |
653 | | ExpectedStmt VisitCXXThrowExpr(CXXThrowExpr *E); |
654 | | ExpectedStmt VisitCXXNoexceptExpr(CXXNoexceptExpr *E); |
655 | | ExpectedStmt VisitCXXDefaultArgExpr(CXXDefaultArgExpr *E); |
656 | | ExpectedStmt VisitCXXScalarValueInitExpr(CXXScalarValueInitExpr *E); |
657 | | ExpectedStmt VisitCXXBindTemporaryExpr(CXXBindTemporaryExpr *E); |
658 | | ExpectedStmt VisitCXXTemporaryObjectExpr(CXXTemporaryObjectExpr *E); |
659 | | ExpectedStmt VisitMaterializeTemporaryExpr(MaterializeTemporaryExpr *E); |
660 | | ExpectedStmt VisitPackExpansionExpr(PackExpansionExpr *E); |
661 | | ExpectedStmt VisitSizeOfPackExpr(SizeOfPackExpr *E); |
662 | | ExpectedStmt VisitCXXNewExpr(CXXNewExpr *E); |
663 | | ExpectedStmt VisitCXXDeleteExpr(CXXDeleteExpr *E); |
664 | | ExpectedStmt VisitCXXConstructExpr(CXXConstructExpr *E); |
665 | | ExpectedStmt VisitCXXMemberCallExpr(CXXMemberCallExpr *E); |
666 | | ExpectedStmt VisitCXXDependentScopeMemberExpr(CXXDependentScopeMemberExpr *E); |
667 | | ExpectedStmt VisitDependentScopeDeclRefExpr(DependentScopeDeclRefExpr *E); |
668 | | ExpectedStmt VisitCXXUnresolvedConstructExpr(CXXUnresolvedConstructExpr *E); |
669 | | ExpectedStmt VisitUnresolvedLookupExpr(UnresolvedLookupExpr *E); |
670 | | ExpectedStmt VisitUnresolvedMemberExpr(UnresolvedMemberExpr *E); |
671 | | ExpectedStmt VisitExprWithCleanups(ExprWithCleanups *E); |
672 | | ExpectedStmt VisitCXXThisExpr(CXXThisExpr *E); |
673 | | ExpectedStmt VisitCXXBoolLiteralExpr(CXXBoolLiteralExpr *E); |
674 | | ExpectedStmt VisitCXXPseudoDestructorExpr(CXXPseudoDestructorExpr *E); |
675 | | ExpectedStmt VisitMemberExpr(MemberExpr *E); |
676 | | ExpectedStmt VisitCallExpr(CallExpr *E); |
677 | | ExpectedStmt VisitLambdaExpr(LambdaExpr *LE); |
678 | | ExpectedStmt VisitInitListExpr(InitListExpr *E); |
679 | | ExpectedStmt VisitCXXStdInitializerListExpr(CXXStdInitializerListExpr *E); |
680 | | ExpectedStmt VisitCXXInheritedCtorInitExpr(CXXInheritedCtorInitExpr *E); |
681 | | ExpectedStmt VisitArrayInitLoopExpr(ArrayInitLoopExpr *E); |
682 | | ExpectedStmt VisitArrayInitIndexExpr(ArrayInitIndexExpr *E); |
683 | | ExpectedStmt VisitCXXDefaultInitExpr(CXXDefaultInitExpr *E); |
684 | | ExpectedStmt VisitCXXNamedCastExpr(CXXNamedCastExpr *E); |
685 | | ExpectedStmt VisitSubstNonTypeTemplateParmExpr(SubstNonTypeTemplateParmExpr *E); |
686 | | ExpectedStmt VisitTypeTraitExpr(TypeTraitExpr *E); |
687 | | ExpectedStmt VisitCXXTypeidExpr(CXXTypeidExpr *E); |
688 | | ExpectedStmt VisitCXXFoldExpr(CXXFoldExpr *E); |
689 | | |
690 | | // Helper for chaining together multiple imports. If an error is detected, |
691 | | // subsequent imports will return default constructed nodes, so that failure |
692 | | // can be detected with a single conditional branch after a sequence of |
693 | | // imports. |
694 | 50.0M | template <typename T> T importChecked(Error &Err, const T &From) { |
695 | | // Don't attempt to import nodes if we hit an error earlier. |
696 | 50.0M | if (Err) |
697 | 656 | return T{}; |
698 | 50.0M | Expected<T> MaybeVal = import(From); |
699 | 50.0M | if (!MaybeVal) { |
700 | 348 | Err = MaybeVal.takeError(); |
701 | 348 | return T{}; |
702 | 348 | } |
703 | 50.0M | return *MaybeVal; |
704 | 50.0M | } clang::QualType clang::ASTNodeImporter::importChecked<clang::QualType>(llvm::Error&, clang::QualType const&) Line | Count | Source | 694 | 8.24M | template <typename T> T importChecked(Error &Err, const T &From) { | 695 | | // Don't attempt to import nodes if we hit an error earlier. | 696 | 8.24M | if (Err) | 697 | 4 | return T{}; | 698 | 8.24M | Expected<T> MaybeVal = import(From); | 699 | 8.24M | if (!MaybeVal) { | 700 | 344 | Err = MaybeVal.takeError(); | 701 | 344 | return T{}; | 702 | 344 | } | 703 | 8.24M | return *MaybeVal; | 704 | 8.24M | } |
clang::Expr const* clang::ASTNodeImporter::importChecked<clang::Expr const*>(llvm::Error&, clang::Expr const* const&) Line | Count | Source | 694 | 9.61k | template <typename T> T importChecked(Error &Err, const T &From) { | 695 | | // Don't attempt to import nodes if we hit an error earlier. | 696 | 9.61k | if (Err) | 697 | 0 | return T{}; | 698 | 9.61k | Expected<T> MaybeVal = import(From); | 699 | 9.61k | if (!MaybeVal) { | 700 | 0 | Err = MaybeVal.takeError(); | 701 | 0 | return T{}; | 702 | 0 | } | 703 | 9.61k | return *MaybeVal; | 704 | 9.61k | } |
clang::Expr* clang::ASTNodeImporter::importChecked<clang::Expr*>(llvm::Error&, clang::Expr* const&) Line | Count | Source | 694 | 5.68M | template <typename T> T importChecked(Error &Err, const T &From) { | 695 | | // Don't attempt to import nodes if we hit an error earlier. | 696 | 5.68M | if (Err) | 697 | 13 | return T{}; | 698 | 5.68M | Expected<T> MaybeVal = import(From); | 699 | 5.68M | if (!MaybeVal) { | 700 | 0 | Err = MaybeVal.takeError(); | 701 | 0 | return T{}; | 702 | 0 | } | 703 | 5.68M | return *MaybeVal; | 704 | 5.68M | } |
clang::SourceRange clang::ASTNodeImporter::importChecked<clang::SourceRange>(llvm::Error&, clang::SourceRange const&) Line | Count | Source | 694 | 1.25M | template <typename T> T importChecked(Error &Err, const T &From) { | 695 | | // Don't attempt to import nodes if we hit an error earlier. | 696 | 1.25M | if (Err) | 697 | 0 | return T{}; | 698 | 1.25M | Expected<T> MaybeVal = import(From); | 699 | 1.25M | if (!MaybeVal) { | 700 | 0 | Err = MaybeVal.takeError(); | 701 | 0 | return T{}; | 702 | 0 | } | 703 | 1.25M | return *MaybeVal; | 704 | 1.25M | } |
clang::FunctionDecl* clang::ASTNodeImporter::importChecked<clang::FunctionDecl*>(llvm::Error&, clang::FunctionDecl* const&) Line | Count | Source | 694 | 1.53M | template <typename T> T importChecked(Error &Err, const T &From) { | 695 | | // Don't attempt to import nodes if we hit an error earlier. | 696 | 1.53M | if (Err) | 697 | 0 | return T{}; | 698 | 1.53M | Expected<T> MaybeVal = import(From); | 699 | 1.53M | if (!MaybeVal) { | 700 | 0 | Err = MaybeVal.takeError(); | 701 | 0 | return T{}; | 702 | 0 | } | 703 | 1.53M | return *MaybeVal; | 704 | 1.53M | } |
clang::UnresolvedUsingTypenameDecl* clang::ASTNodeImporter::importChecked<clang::UnresolvedUsingTypenameDecl*>(llvm::Error&, clang::UnresolvedUsingTypenameDecl* const&) Line | Count | Source | 694 | 268 | template <typename T> T importChecked(Error &Err, const T &From) { | 695 | | // Don't attempt to import nodes if we hit an error earlier. | 696 | 268 | if (Err) | 697 | 0 | return T{}; | 698 | 268 | Expected<T> MaybeVal = import(From); | 699 | 268 | if (!MaybeVal) { | 700 | 0 | Err = MaybeVal.takeError(); | 701 | 0 | return T{}; | 702 | 0 | } | 703 | 268 | return *MaybeVal; | 704 | 268 | } |
clang::Decl* clang::ASTNodeImporter::importChecked<clang::Decl*>(llvm::Error&, clang::Decl* const&) Line | Count | Source | 694 | 268 | template <typename T> T importChecked(Error &Err, const T &From) { | 695 | | // Don't attempt to import nodes if we hit an error earlier. | 696 | 268 | if (Err) | 697 | 0 | return T{}; | 698 | 268 | Expected<T> MaybeVal = import(From); | 699 | 268 | if (!MaybeVal) { | 700 | 0 | Err = MaybeVal.takeError(); | 701 | 0 | return T{}; | 702 | 0 | } | 703 | 268 | return *MaybeVal; | 704 | 268 | } |
clang::ValueDecl* clang::ASTNodeImporter::importChecked<clang::ValueDecl*>(llvm::Error&, clang::ValueDecl* const&) Line | Count | Source | 694 | 2.20M | template <typename T> T importChecked(Error &Err, const T &From) { | 695 | | // Don't attempt to import nodes if we hit an error earlier. | 696 | 2.20M | if (Err) | 697 | 4 | return T{}; | 698 | 2.20M | Expected<T> MaybeVal = import(From); | 699 | 2.20M | if (!MaybeVal) { | 700 | 0 | Err = MaybeVal.takeError(); | 701 | 0 | return T{}; | 702 | 0 | } | 703 | 2.20M | return *MaybeVal; | 704 | 2.20M | } |
clang::SourceLocation clang::ASTNodeImporter::importChecked<clang::SourceLocation>(llvm::Error&, clang::SourceLocation const&) Line | Count | Source | 694 | 17.9M | template <typename T> T importChecked(Error &Err, const T &From) { | 695 | | // Don't attempt to import nodes if we hit an error earlier. | 696 | 17.9M | if (Err) | 697 | 278 | return T{}; | 698 | 17.9M | Expected<T> MaybeVal = import(From); | 699 | 17.9M | if (!MaybeVal) { | 700 | 0 | Err = MaybeVal.takeError(); | 701 | 0 | return T{}; | 702 | 0 | } | 703 | 17.9M | return *MaybeVal; | 704 | 17.9M | } |
clang::StringLiteral* clang::ASTNodeImporter::importChecked<clang::StringLiteral*>(llvm::Error&, clang::StringLiteral* const&) Line | Count | Source | 694 | 18.8k | template <typename T> T importChecked(Error &Err, const T &From) { | 695 | | // Don't attempt to import nodes if we hit an error earlier. | 696 | 18.8k | if (Err) | 697 | 0 | return T{}; | 698 | 18.8k | Expected<T> MaybeVal = import(From); | 699 | 18.8k | if (!MaybeVal) { | 700 | 0 | Err = MaybeVal.takeError(); | 701 | 0 | return T{}; | 702 | 0 | } | 703 | 18.8k | return *MaybeVal; | 704 | 18.8k | } |
clang::NestedNameSpecifierLoc clang::ASTNodeImporter::importChecked<clang::NestedNameSpecifierLoc>(llvm::Error&, clang::NestedNameSpecifierLoc const&) Line | Count | Source | 694 | 4.45M | template <typename T> T importChecked(Error &Err, const T &From) { | 695 | | // Don't attempt to import nodes if we hit an error earlier. | 696 | 4.45M | if (Err) | 697 | 13 | return T{}; | 698 | 4.45M | Expected<T> MaybeVal = import(From); | 699 | 4.45M | if (!MaybeVal) { | 700 | 4 | Err = MaybeVal.takeError(); | 701 | 4 | return T{}; | 702 | 4 | } | 703 | 4.45M | return *MaybeVal; | 704 | 4.45M | } |
clang::NamespaceDecl* clang::ASTNodeImporter::importChecked<clang::NamespaceDecl*>(llvm::Error&, clang::NamespaceDecl* const&) Line | Count | Source | 694 | 272 | template <typename T> T importChecked(Error &Err, const T &From) { | 695 | | // Don't attempt to import nodes if we hit an error earlier. | 696 | 272 | if (Err) | 697 | 0 | return T{}; | 698 | 272 | Expected<T> MaybeVal = import(From); | 699 | 272 | if (!MaybeVal) { | 700 | 0 | Err = MaybeVal.takeError(); | 701 | 0 | return T{}; | 702 | 0 | } | 703 | 272 | return *MaybeVal; | 704 | 272 | } |
clang::TypeSourceInfo* clang::ASTNodeImporter::importChecked<clang::TypeSourceInfo*>(llvm::Error&, clang::TypeSourceInfo* const&) Line | Count | Source | 694 | 3.18M | template <typename T> T importChecked(Error &Err, const T &From) { | 695 | | // Don't attempt to import nodes if we hit an error earlier. | 696 | 3.18M | if (Err) | 697 | 344 | return T{}; | 698 | 3.18M | Expected<T> MaybeVal = import(From); | 699 | 3.18M | if (!MaybeVal) { | 700 | 0 | Err = MaybeVal.takeError(); | 701 | 0 | return T{}; | 702 | 0 | } | 703 | 3.18M | return *MaybeVal; | 704 | 3.18M | } |
clang::TemplateParameterList* clang::ASTNodeImporter::importChecked<clang::TemplateParameterList*>(llvm::Error&, clang::TemplateParameterList* const&) Line | Count | Source | 694 | 8.58k | template <typename T> T importChecked(Error &Err, const T &From) { | 695 | | // Don't attempt to import nodes if we hit an error earlier. | 696 | 8.58k | if (Err) | 697 | 0 | return T{}; | 698 | 8.58k | Expected<T> MaybeVal = import(From); | 699 | 8.58k | if (!MaybeVal) { | 700 | 0 | Err = MaybeVal.takeError(); | 701 | 0 | return T{}; | 702 | 0 | } | 703 | 8.58k | return *MaybeVal; | 704 | 8.58k | } |
clang::TypeAliasDecl* clang::ASTNodeImporter::importChecked<clang::TypeAliasDecl*>(llvm::Error&, clang::TypeAliasDecl* const&) Line | Count | Source | 694 | 8.58k | template <typename T> T importChecked(Error &Err, const T &From) { | 695 | | // Don't attempt to import nodes if we hit an error earlier. | 696 | 8.58k | if (Err) | 697 | 0 | return T{}; | 698 | 8.58k | Expected<T> MaybeVal = import(From); | 699 | 8.58k | if (!MaybeVal) { | 700 | 0 | Err = MaybeVal.takeError(); | 701 | 0 | return T{}; | 702 | 0 | } | 703 | 8.58k | return *MaybeVal; | 704 | 8.58k | } |
clang::CXXConstructorDecl* clang::ASTNodeImporter::importChecked<clang::CXXConstructorDecl*>(llvm::Error&, clang::CXXConstructorDecl* const&) Line | Count | Source | 694 | 27.2k | template <typename T> T importChecked(Error &Err, const T &From) { | 695 | | // Don't attempt to import nodes if we hit an error earlier. | 696 | 27.2k | if (Err) | 697 | 0 | return T{}; | 698 | 27.2k | Expected<T> MaybeVal = import(From); | 699 | 27.2k | if (!MaybeVal) { | 700 | 0 | Err = MaybeVal.takeError(); | 701 | 0 | return T{}; | 702 | 0 | } | 703 | 27.2k | return *MaybeVal; | 704 | 27.2k | } |
clang::DeclarationName clang::ASTNodeImporter::importChecked<clang::DeclarationName>(llvm::Error&, clang::DeclarationName const&) Line | Count | Source | 694 | 3.14M | template <typename T> T importChecked(Error &Err, const T &From) { | 695 | | // Don't attempt to import nodes if we hit an error earlier. | 696 | 3.14M | if (Err) | 697 | 0 | return T{}; | 698 | 3.14M | Expected<T> MaybeVal = import(From); | 699 | 3.14M | if (!MaybeVal) { | 700 | 0 | Err = MaybeVal.takeError(); | 701 | 0 | return T{}; | 702 | 0 | } | 703 | 3.14M | return *MaybeVal; | 704 | 3.14M | } |
clang::ConstructorUsingShadowDecl* clang::ASTNodeImporter::importChecked<clang::ConstructorUsingShadowDecl*>(llvm::Error&, clang::ConstructorUsingShadowDecl* const&) Line | Count | Source | 694 | 171 | template <typename T> T importChecked(Error &Err, const T &From) { | 695 | | // Don't attempt to import nodes if we hit an error earlier. | 696 | 171 | if (Err) | 697 | 0 | return T{}; | 698 | 171 | Expected<T> MaybeVal = import(From); | 699 | 171 | if (!MaybeVal) { | 700 | 0 | Err = MaybeVal.takeError(); | 701 | 0 | return T{}; | 702 | 0 | } | 703 | 171 | return *MaybeVal; | 704 | 171 | } |
clang::EnumDecl* clang::ASTNodeImporter::importChecked<clang::EnumDecl*>(llvm::Error&, clang::EnumDecl* const&) Line | Count | Source | 694 | 8 | template <typename T> T importChecked(Error &Err, const T &From) { | 695 | | // Don't attempt to import nodes if we hit an error earlier. | 696 | 8 | if (Err) | 697 | 0 | return T{}; | 698 | 8 | Expected<T> MaybeVal = import(From); | 699 | 8 | if (!MaybeVal) { | 700 | 0 | Err = MaybeVal.takeError(); | 701 | 0 | return T{}; | 702 | 0 | } | 703 | 8 | return *MaybeVal; | 704 | 8 | } |
clang::Selector clang::ASTNodeImporter::importChecked<clang::Selector>(llvm::Error&, clang::Selector const&) Line | Count | Source | 694 | 4.62k | template <typename T> T importChecked(Error &Err, const T &From) { | 695 | | // Don't attempt to import nodes if we hit an error earlier. | 696 | 4.62k | if (Err) | 697 | 0 | return T{}; | 698 | 4.62k | Expected<T> MaybeVal = import(From); | 699 | 4.62k | if (!MaybeVal) { | 700 | 0 | Err = MaybeVal.takeError(); | 701 | 0 | return T{}; | 702 | 0 | } | 703 | 4.62k | return *MaybeVal; | 704 | 4.62k | } |
clang::ObjCMethodDecl* clang::ASTNodeImporter::importChecked<clang::ObjCMethodDecl*>(llvm::Error&, clang::ObjCMethodDecl* const&) Line | Count | Source | 694 | 4.62k | template <typename T> T importChecked(Error &Err, const T &From) { | 695 | | // Don't attempt to import nodes if we hit an error earlier. | 696 | 4.62k | if (Err) | 697 | 0 | return T{}; | 698 | 4.62k | Expected<T> MaybeVal = import(From); | 699 | 4.62k | if (!MaybeVal) { | 700 | 0 | Err = MaybeVal.takeError(); | 701 | 0 | return T{}; | 702 | 0 | } | 703 | 4.62k | return *MaybeVal; | 704 | 4.62k | } |
clang::ObjCIvarDecl* clang::ASTNodeImporter::importChecked<clang::ObjCIvarDecl*>(llvm::Error&, clang::ObjCIvarDecl* const&) Line | Count | Source | 694 | 2.31k | template <typename T> T importChecked(Error &Err, const T &From) { | 695 | | // Don't attempt to import nodes if we hit an error earlier. | 696 | 2.31k | if (Err) | 697 | 0 | return T{}; | 698 | 2.31k | Expected<T> MaybeVal = import(From); | 699 | 2.31k | if (!MaybeVal) { | 700 | 0 | Err = MaybeVal.takeError(); | 701 | 0 | return T{}; | 702 | 0 | } | 703 | 2.31k | return *MaybeVal; | 704 | 2.31k | } |
clang::NamedDecl* clang::ASTNodeImporter::importChecked<clang::NamedDecl*>(llvm::Error&, clang::NamedDecl* const&) Line | Count | Source | 694 | 979k | template <typename T> T importChecked(Error &Err, const T &From) { | 695 | | // Don't attempt to import nodes if we hit an error earlier. | 696 | 979k | if (Err) | 697 | 0 | return T{}; | 698 | 979k | Expected<T> MaybeVal = import(From); | 699 | 979k | if (!MaybeVal) { | 700 | 0 | Err = MaybeVal.takeError(); | 701 | 0 | return T{}; | 702 | 0 | } | 703 | 979k | return *MaybeVal; | 704 | 979k | } |
Unexecuted instantiation: clang::ConceptDecl* clang::ASTNodeImporter::importChecked<clang::ConceptDecl*>(llvm::Error&, clang::ConceptDecl* const&) clang::DeclGroupRef clang::ASTNodeImporter::importChecked<clang::DeclGroupRef>(llvm::Error&, clang::DeclGroupRef const&) Line | Count | Source | 694 | 226k | template <typename T> T importChecked(Error &Err, const T &From) { | 695 | | // Don't attempt to import nodes if we hit an error earlier. | 696 | 226k | if (Err) | 697 | 0 | return T{}; | 698 | 226k | Expected<T> MaybeVal = import(From); | 699 | 226k | if (!MaybeVal) { | 700 | 0 | Err = MaybeVal.takeError(); | 701 | 0 | return T{}; | 702 | 0 | } | 703 | 226k | return *MaybeVal; | 704 | 226k | } |
clang::Stmt* clang::ASTNodeImporter::importChecked<clang::Stmt*>(llvm::Error&, clang::Stmt* const&) Line | Count | Source | 694 | 522k | template <typename T> T importChecked(Error &Err, const T &From) { | 695 | | // Don't attempt to import nodes if we hit an error earlier. | 696 | 522k | if (Err) | 697 | 0 | return T{}; | 698 | 522k | Expected<T> MaybeVal = import(From); | 699 | 522k | if (!MaybeVal) { | 700 | 0 | Err = MaybeVal.takeError(); | 701 | 0 | return T{}; | 702 | 0 | } | 703 | 522k | return *MaybeVal; | 704 | 522k | } |
clang::LabelDecl* clang::ASTNodeImporter::importChecked<clang::LabelDecl*>(llvm::Error&, clang::LabelDecl* const&) Line | Count | Source | 694 | 1.15k | template <typename T> T importChecked(Error &Err, const T &From) { | 695 | | // Don't attempt to import nodes if we hit an error earlier. | 696 | 1.15k | if (Err) | 697 | 0 | return T{}; | 698 | 1.15k | Expected<T> MaybeVal = import(From); | 699 | 1.15k | if (!MaybeVal) { | 700 | 0 | Err = MaybeVal.takeError(); | 701 | 0 | return T{}; | 702 | 0 | } | 703 | 1.15k | return *MaybeVal; | 704 | 1.15k | } |
clang::VarDecl* clang::ASTNodeImporter::importChecked<clang::VarDecl*>(llvm::Error&, clang::VarDecl* const&) Line | Count | Source | 694 | 185k | template <typename T> T importChecked(Error &Err, const T &From) { | 695 | | // Don't attempt to import nodes if we hit an error earlier. | 696 | 185k | if (Err) | 697 | 0 | return T{}; | 698 | 185k | Expected<T> MaybeVal = import(From); | 699 | 185k | if (!MaybeVal) { | 700 | 0 | Err = MaybeVal.takeError(); | 701 | 0 | return T{}; | 702 | 0 | } | 703 | 185k | return *MaybeVal; | 704 | 185k | } |
clang::VarDecl const* clang::ASTNodeImporter::importChecked<clang::VarDecl const*>(llvm::Error&, clang::VarDecl const* const&) Line | Count | Source | 694 | 267k | template <typename T> T importChecked(Error &Err, const T &From) { | 695 | | // Don't attempt to import nodes if we hit an error earlier. | 696 | 267k | if (Err) | 697 | 0 | return T{}; | 698 | 267k | Expected<T> MaybeVal = import(From); | 699 | 267k | if (!MaybeVal) { | 700 | 0 | Err = MaybeVal.takeError(); | 701 | 0 | return T{}; | 702 | 0 | } | 703 | 267k | return *MaybeVal; | 704 | 267k | } |
clang::DeclStmt* clang::ASTNodeImporter::importChecked<clang::DeclStmt*>(llvm::Error&, clang::DeclStmt* const&) Line | Count | Source | 694 | 1.32k | template <typename T> T importChecked(Error &Err, const T &From) { | 695 | | // Don't attempt to import nodes if we hit an error earlier. | 696 | 1.32k | if (Err) | 697 | 0 | return T{}; | 698 | 1.32k | Expected<T> MaybeVal = import(From); | 699 | 1.32k | if (!MaybeVal) { | 700 | 0 | Err = MaybeVal.takeError(); | 701 | 0 | return T{}; | 702 | 0 | } | 703 | 1.32k | return *MaybeVal; | 704 | 1.32k | } |
clang::ObjCAtFinallyStmt* clang::ASTNodeImporter::importChecked<clang::ObjCAtFinallyStmt*>(llvm::Error&, clang::ObjCAtFinallyStmt* const&) Line | Count | Source | 694 | 6 | template <typename T> T importChecked(Error &Err, const T &From) { | 695 | | // Don't attempt to import nodes if we hit an error earlier. | 696 | 6 | if (Err) | 697 | 0 | return T{}; | 698 | 6 | Expected<T> MaybeVal = import(From); | 699 | 6 | if (!MaybeVal) { | 700 | 0 | Err = MaybeVal.takeError(); | 701 | 0 | return T{}; | 702 | 0 | } | 703 | 6 | return *MaybeVal; | 704 | 6 | } |
clang::CompoundStmt* clang::ASTNodeImporter::importChecked<clang::CompoundStmt*>(llvm::Error&, clang::CompoundStmt* const&) Line | Count | Source | 694 | 4 | template <typename T> T importChecked(Error &Err, const T &From) { | 695 | | // Don't attempt to import nodes if we hit an error earlier. | 696 | 4 | if (Err) | 697 | 0 | return T{}; | 698 | 4 | Expected<T> MaybeVal = import(From); | 699 | 4 | if (!MaybeVal) { | 700 | 0 | Err = MaybeVal.takeError(); | 701 | 0 | return T{}; | 702 | 0 | } | 703 | 4 | return *MaybeVal; | 704 | 4 | } |
clang::APValue clang::ASTNodeImporter::importChecked<clang::APValue>(llvm::Error&, clang::APValue const&) Line | Count | Source | 694 | 57.7k | template <typename T> T importChecked(Error &Err, const T &From) { | 695 | | // Don't attempt to import nodes if we hit an error earlier. | 696 | 57.7k | if (Err) | 697 | 0 | return T{}; | 698 | 57.7k | Expected<T> MaybeVal = import(From); | 699 | 57.7k | if (!MaybeVal) { | 700 | 0 | Err = MaybeVal.takeError(); | 701 | 0 | return T{}; | 702 | 0 | } | 703 | 57.7k | return *MaybeVal; | 704 | 57.7k | } |
clang::OpaqueValueExpr* clang::ASTNodeImporter::importChecked<clang::OpaqueValueExpr*>(llvm::Error&, clang::OpaqueValueExpr* const&) Line | Count | Source | 694 | 144 | template <typename T> T importChecked(Error &Err, const T &From) { | 695 | | // Don't attempt to import nodes if we hit an error earlier. | 696 | 144 | if (Err) | 697 | 0 | return T{}; | 698 | 144 | Expected<T> MaybeVal = import(From); | 699 | 144 | if (!MaybeVal) { | 700 | 0 | Err = MaybeVal.takeError(); | 701 | 0 | return T{}; | 702 | 0 | } | 703 | 144 | return *MaybeVal; | 704 | 144 | } |
clang::LifetimeExtendedTemporaryDecl* clang::ASTNodeImporter::importChecked<clang::LifetimeExtendedTemporaryDecl*>(llvm::Error&, clang::LifetimeExtendedTemporaryDecl* const&) Line | Count | Source | 694 | 10.6k | template <typename T> T importChecked(Error &Err, const T &From) { | 695 | | // Don't attempt to import nodes if we hit an error earlier. | 696 | 10.6k | if (Err) | 697 | 0 | return T{}; | 698 | 10.6k | Expected<T> MaybeVal = import(From); | 699 | 10.6k | if (!MaybeVal) { | 700 | 0 | Err = MaybeVal.takeError(); | 701 | 0 | return T{}; | 702 | 0 | } | 703 | 10.6k | return *MaybeVal; | 704 | 10.6k | } |
llvm::Optional<clang::Expr*> clang::ASTNodeImporter::importChecked<llvm::Optional<clang::Expr*> >(llvm::Error&, llvm::Optional<clang::Expr*> const&) Line | Count | Source | 694 | 4.69k | template <typename T> T importChecked(Error &Err, const T &From) { | 695 | | // Don't attempt to import nodes if we hit an error earlier. | 696 | 4.69k | if (Err) | 697 | 0 | return T{}; | 698 | 4.69k | Expected<T> MaybeVal = import(From); | 699 | 4.69k | if (!MaybeVal) { | 700 | 0 | Err = MaybeVal.takeError(); | 701 | 0 | return T{}; | 702 | 0 | } | 703 | 4.69k | return *MaybeVal; | 704 | 4.69k | } |
clang::NonTypeTemplateParmDecl* clang::ASTNodeImporter::importChecked<clang::NonTypeTemplateParmDecl*>(llvm::Error&, clang::NonTypeTemplateParmDecl* const&) Line | Count | Source | 694 | 31.8k | template <typename T> T importChecked(Error &Err, const T &From) { | 695 | | // Don't attempt to import nodes if we hit an error earlier. | 696 | 31.8k | if (Err) | 697 | 0 | return T{}; | 698 | 31.8k | Expected<T> MaybeVal = import(From); | 699 | 31.8k | if (!MaybeVal) { | 700 | 0 | Err = MaybeVal.takeError(); | 701 | 0 | return T{}; | 702 | 0 | } | 703 | 31.8k | return *MaybeVal; | 704 | 31.8k | } |
clang::UnresolvedLookupExpr* clang::ASTNodeImporter::importChecked<clang::UnresolvedLookupExpr*>(llvm::Error&, clang::UnresolvedLookupExpr* const&) Line | Count | Source | 694 | 16 | template <typename T> T importChecked(Error &Err, const T &From) { | 695 | | // Don't attempt to import nodes if we hit an error earlier. | 696 | 16 | if (Err) | 697 | 0 | return T{}; | 698 | 16 | Expected<T> MaybeVal = import(From); | 699 | 16 | if (!MaybeVal) { | 700 | 0 | Err = MaybeVal.takeError(); | 701 | 0 | return T{}; | 702 | 0 | } | 703 | 16 | return *MaybeVal; | 704 | 16 | } |
Unexecuted instantiation: clang::FieldDecl const* clang::ASTNodeImporter::importChecked<clang::FieldDecl const*>(llvm::Error&, clang::FieldDecl const* const&) Unexecuted instantiation: clang::AddrLabelExpr const* clang::ASTNodeImporter::importChecked<clang::AddrLabelExpr const*>(llvm::Error&, clang::AddrLabelExpr const* const&) Unexecuted instantiation: clang::ValueDecl const* clang::ASTNodeImporter::importChecked<clang::ValueDecl const*>(llvm::Error&, clang::ValueDecl const* const&) Unexecuted instantiation: clang::CXXRecordDecl const* clang::ASTNodeImporter::importChecked<clang::CXXRecordDecl const*>(llvm::Error&, clang::CXXRecordDecl const* const&) Unexecuted instantiation: clang::Type const* clang::ASTNodeImporter::importChecked<clang::Type const*>(llvm::Error&, clang::Type const* const&) Unexecuted instantiation: clang::Decl const* clang::ASTNodeImporter::importChecked<clang::Decl const*>(llvm::Error&, clang::Decl const* const&) |
705 | | |
706 | | template<typename IIter, typename OIter> |
707 | 2.49M | Error ImportArrayChecked(IIter Ibegin, IIter Iend, OIter Obegin) { |
708 | 2.49M | using ItemT = std::remove_reference_t<decltype(*Obegin)>; |
709 | 6.19M | for (; Ibegin != Iend; ++Ibegin, ++Obegin3.70M ) { |
710 | 3.70M | Expected<ItemT> ToOrErr = import(*Ibegin); |
711 | 3.70M | if (!ToOrErr) |
712 | 28 | return ToOrErr.takeError(); |
713 | 3.70M | *Obegin = *ToOrErr; |
714 | 3.70M | } |
715 | 2.49M | return Error::success(); |
716 | 2.49M | } llvm::Error clang::ASTNodeImporter::ImportArrayChecked<clang::NamedDecl* const*, clang::NamedDecl**>(clang::NamedDecl* const*, clang::NamedDecl* const*, clang::NamedDecl**) Line | Count | Source | 707 | 506k | Error ImportArrayChecked(IIter Ibegin, IIter Iend, OIter Obegin) { | 708 | 506k | using ItemT = std::remove_reference_t<decltype(*Obegin)>; | 709 | 1.44M | for (; Ibegin != Iend; ++Ibegin, ++Obegin934k ) { | 710 | 934k | Expected<ItemT> ToOrErr = import(*Ibegin); | 711 | 934k | if (!ToOrErr) | 712 | 0 | return ToOrErr.takeError(); | 713 | 934k | *Obegin = *ToOrErr; | 714 | 934k | } | 715 | 506k | return Error::success(); | 716 | 506k | } |
llvm::Error clang::ASTNodeImporter::ImportArrayChecked<clang::CXXCtorInitializer**, clang::CXXCtorInitializer**>(clang::CXXCtorInitializer**, clang::CXXCtorInitializer**, clang::CXXCtorInitializer**) Line | Count | Source | 707 | 53.7k | Error ImportArrayChecked(IIter Ibegin, IIter Iend, OIter Obegin) { | 708 | 53.7k | using ItemT = std::remove_reference_t<decltype(*Obegin)>; | 709 | 134k | for (; Ibegin != Iend; ++Ibegin, ++Obegin80.8k ) { | 710 | 80.8k | Expected<ItemT> ToOrErr = import(*Ibegin); | 711 | 80.8k | if (!ToOrErr) | 712 | 0 | return ToOrErr.takeError(); | 713 | 80.8k | *Obegin = *ToOrErr; | 714 | 80.8k | } | 715 | 53.7k | return Error::success(); | 716 | 53.7k | } |
llvm::Error clang::ASTNodeImporter::ImportArrayChecked<clang::BindingDecl* const*, clang::BindingDecl**>(clang::BindingDecl* const*, clang::BindingDecl* const*, clang::BindingDecl**) Line | Count | Source | 707 | 48 | Error ImportArrayChecked(IIter Ibegin, IIter Iend, OIter Obegin) { | 708 | 48 | using ItemT = std::remove_reference_t<decltype(*Obegin)>; | 709 | 144 | for (; Ibegin != Iend; ++Ibegin, ++Obegin96 ) { | 710 | 96 | Expected<ItemT> ToOrErr = import(*Ibegin); | 711 | 96 | if (!ToOrErr) | 712 | 0 | return ToOrErr.takeError(); | 713 | 96 | *Obegin = *ToOrErr; | 714 | 96 | } | 715 | 48 | return Error::success(); | 716 | 48 | } |
llvm::Error clang::ASTNodeImporter::ImportArrayChecked<clang::Stmt::CastIterator<clang::Expr, clang::Expr*, clang::Stmt*>, clang::Expr**>(clang::Stmt::CastIterator<clang::Expr, clang::Expr*, clang::Stmt*>, clang::Stmt::CastIterator<clang::Expr, clang::Expr*, clang::Stmt*>, clang::Expr**) Line | Count | Source | 707 | 1.22M | Error ImportArrayChecked(IIter Ibegin, IIter Iend, OIter Obegin) { | 708 | 1.22M | using ItemT = std::remove_reference_t<decltype(*Obegin)>; | 709 | 2.65M | for (; Ibegin != Iend; ++Ibegin, ++Obegin1.42M ) { | 710 | 1.42M | Expected<ItemT> ToOrErr = import(*Ibegin); | 711 | 1.42M | if (!ToOrErr) | 712 | 0 | return ToOrErr.takeError(); | 713 | 1.42M | *Obegin = *ToOrErr; | 714 | 1.42M | } | 715 | 1.22M | return Error::success(); | 716 | 1.22M | } |
llvm::Error clang::ASTNodeImporter::ImportArrayChecked<clang::Stmt::CastIterator<clang::AddrLabelExpr, clang::AddrLabelExpr*, clang::Stmt*>, clang::Expr**>(clang::Stmt::CastIterator<clang::AddrLabelExpr, clang::AddrLabelExpr*, clang::Stmt*>, clang::Stmt::CastIterator<clang::AddrLabelExpr, clang::AddrLabelExpr*, clang::Stmt*>, clang::Expr**) Line | Count | Source | 707 | 3 | Error ImportArrayChecked(IIter Ibegin, IIter Iend, OIter Obegin) { | 708 | 3 | using ItemT = std::remove_reference_t<decltype(*Obegin)>; | 709 | 3 | for (; Ibegin != Iend; ++Ibegin, ++Obegin0 ) { | 710 | 0 | Expected<ItemT> ToOrErr = import(*Ibegin); | 711 | 0 | if (!ToOrErr) | 712 | 0 | return ToOrErr.takeError(); | 713 | 0 | *Obegin = *ToOrErr; | 714 | 0 | } | 715 | 3 | return Error::success(); | 716 | 3 | } |
llvm::Error clang::ASTNodeImporter::ImportArrayChecked<clang::Stmt**, clang::Stmt**>(clang::Stmt**, clang::Stmt**, clang::Stmt**) Line | Count | Source | 707 | 476k | Error ImportArrayChecked(IIter Ibegin, IIter Iend, OIter Obegin) { | 708 | 476k | using ItemT = std::remove_reference_t<decltype(*Obegin)>; | 709 | 1.48M | for (; Ibegin != Iend; ++Ibegin, ++Obegin1.00M ) { | 710 | 1.00M | Expected<ItemT> ToOrErr = import(*Ibegin); | 711 | 1.00M | if (!ToOrErr) | 712 | 28 | return ToOrErr.takeError(); | 713 | 1.00M | *Obegin = *ToOrErr; | 714 | 1.00M | } | 715 | 476k | return Error::success(); | 716 | 476k | } |
llvm::Error clang::ASTNodeImporter::ImportArrayChecked<clang::Attr const* const*, clang::Attr const**>(clang::Attr const* const*, clang::Attr const* const*, clang::Attr const**) Line | Count | Source | 707 | 65 | Error ImportArrayChecked(IIter Ibegin, IIter Iend, OIter Obegin) { | 708 | 65 | using ItemT = std::remove_reference_t<decltype(*Obegin)>; | 709 | 130 | for (; Ibegin != Iend; ++Ibegin, ++Obegin65 ) { | 710 | 65 | Expected<ItemT> ToOrErr = import(*Ibegin); | 711 | 65 | if (!ToOrErr) | 712 | 0 | return ToOrErr.takeError(); | 713 | 65 | *Obegin = *ToOrErr; | 714 | 65 | } | 715 | 65 | return Error::success(); | 716 | 65 | } |
llvm::Error clang::ASTNodeImporter::ImportArrayChecked<clang::Expr* const*, clang::Expr**>(clang::Expr* const*, clang::Expr* const*, clang::Expr**) Line | Count | Source | 707 | 87.4k | Error ImportArrayChecked(IIter Ibegin, IIter Iend, OIter Obegin) { | 708 | 87.4k | using ItemT = std::remove_reference_t<decltype(*Obegin)>; | 709 | 213k | for (; Ibegin != Iend; ++Ibegin, ++Obegin126k ) { | 710 | 126k | Expected<ItemT> ToOrErr = import(*Ibegin); | 711 | 126k | if (!ToOrErr) | 712 | 0 | return ToOrErr.takeError(); | 713 | 126k | *Obegin = *ToOrErr; | 714 | 126k | } | 715 | 87.4k | return Error::success(); | 716 | 87.4k | } |
llvm::Error clang::ASTNodeImporter::ImportArrayChecked<clang::TypeSourceInfo const* const*, clang::TypeSourceInfo**>(clang::TypeSourceInfo const* const*, clang::TypeSourceInfo const* const*, clang::TypeSourceInfo**) Line | Count | Source | 707 | 11 | Error ImportArrayChecked(IIter Ibegin, IIter Iend, OIter Obegin) { | 708 | 11 | using ItemT = std::remove_reference_t<decltype(*Obegin)>; | 709 | 33 | for (; Ibegin != Iend; ++Ibegin, ++Obegin22 ) { | 710 | 22 | Expected<ItemT> ToOrErr = import(*Ibegin); | 711 | 22 | if (!ToOrErr) | 712 | 0 | return ToOrErr.takeError(); | 713 | 22 | *Obegin = *ToOrErr; | 714 | 22 | } | 715 | 11 | return Error::success(); | 716 | 11 | } |
llvm::Error clang::ASTNodeImporter::ImportArrayChecked<clang::Expr const* const*, clang::Expr**>(clang::Expr const* const*, clang::Expr const* const*, clang::Expr**) Line | Count | Source | 707 | 11 | Error ImportArrayChecked(IIter Ibegin, IIter Iend, OIter Obegin) { | 708 | 11 | using ItemT = std::remove_reference_t<decltype(*Obegin)>; | 709 | 33 | for (; Ibegin != Iend; ++Ibegin, ++Obegin22 ) { | 710 | 22 | Expected<ItemT> ToOrErr = import(*Ibegin); | 711 | 22 | if (!ToOrErr) | 712 | 0 | return ToOrErr.takeError(); | 713 | 22 | *Obegin = *ToOrErr; | 714 | 22 | } | 715 | 11 | return Error::success(); | 716 | 11 | } |
llvm::Error clang::ASTNodeImporter::ImportArrayChecked<clang::DesignatedInitExpr::Designator*, clang::DesignatedInitExpr::Designator*>(clang::DesignatedInitExpr::Designator*, clang::DesignatedInitExpr::Designator*, clang::DesignatedInitExpr::Designator*) Line | Count | Source | 707 | 40 | Error ImportArrayChecked(IIter Ibegin, IIter Iend, OIter Obegin) { | 708 | 40 | using ItemT = std::remove_reference_t<decltype(*Obegin)>; | 709 | 109 | for (; Ibegin != Iend; ++Ibegin, ++Obegin69 ) { | 710 | 69 | Expected<ItemT> ToOrErr = import(*Ibegin); | 711 | 69 | if (!ToOrErr) | 712 | 0 | return ToOrErr.takeError(); | 713 | 69 | *Obegin = *ToOrErr; | 714 | 69 | } | 715 | 40 | return Error::success(); | 716 | 40 | } |
llvm::Error clang::ASTNodeImporter::ImportArrayChecked<clang::SourceLocation const*, clang::SourceLocation*>(clang::SourceLocation const*, clang::SourceLocation const*, clang::SourceLocation*) Line | Count | Source | 707 | 32.3k | Error ImportArrayChecked(IIter Ibegin, IIter Iend, OIter Obegin) { | 708 | 32.3k | using ItemT = std::remove_reference_t<decltype(*Obegin)>; | 709 | 61.4k | for (; Ibegin != Iend; ++Ibegin, ++Obegin29.1k ) { | 710 | 29.1k | Expected<ItemT> ToOrErr = import(*Ibegin); | 711 | 29.1k | if (!ToOrErr) | 712 | 0 | return ToOrErr.takeError(); | 713 | 29.1k | *Obegin = *ToOrErr; | 714 | 29.1k | } | 715 | 32.3k | return Error::success(); | 716 | 32.3k | } |
llvm::Error clang::ASTNodeImporter::ImportArrayChecked<clang::Expr**, clang::Expr**>(clang::Expr**, clang::Expr**, clang::Expr**) Line | Count | Source | 707 | 85.6k | Error ImportArrayChecked(IIter Ibegin, IIter Iend, OIter Obegin) { | 708 | 85.6k | using ItemT = std::remove_reference_t<decltype(*Obegin)>; | 709 | 164k | for (; Ibegin != Iend; ++Ibegin, ++Obegin78.6k ) { | 710 | 78.6k | Expected<ItemT> ToOrErr = import(*Ibegin); | 711 | 78.6k | if (!ToOrErr) | 712 | 0 | return ToOrErr.takeError(); | 713 | 78.6k | *Obegin = *ToOrErr; | 714 | 78.6k | } | 715 | 85.6k | return Error::success(); | 716 | 85.6k | } |
llvm::Error clang::ASTNodeImporter::ImportArrayChecked<llvm::PointerUnion<clang::BlockDecl*, clang::CompoundLiteralExpr*> const*, llvm::PointerUnion<clang::BlockDecl*, clang::CompoundLiteralExpr*>*>(llvm::PointerUnion<clang::BlockDecl*, clang::CompoundLiteralExpr*> const*, llvm::PointerUnion<clang::BlockDecl*, clang::CompoundLiteralExpr*> const*, llvm::PointerUnion<clang::BlockDecl*, clang::CompoundLiteralExpr*>*) Line | Count | Source | 707 | 8.99k | Error ImportArrayChecked(IIter Ibegin, IIter Iend, OIter Obegin) { | 708 | 8.99k | using ItemT = std::remove_reference_t<decltype(*Obegin)>; | 709 | 9.00k | for (; Ibegin != Iend; ++Ibegin, ++Obegin2 ) { | 710 | 2 | Expected<ItemT> ToOrErr = import(*Ibegin); | 711 | 2 | if (!ToOrErr) | 712 | 0 | return ToOrErr.takeError(); | 713 | 2 | *Obegin = *ToOrErr; | 714 | 2 | } | 715 | 8.99k | return Error::success(); | 716 | 8.99k | } |
llvm::Error clang::ASTNodeImporter::ImportArrayChecked<clang::TypeSourceInfo* const*, clang::TypeSourceInfo**>(clang::TypeSourceInfo* const*, clang::TypeSourceInfo* const*, clang::TypeSourceInfo**) Line | Count | Source | 707 | 13.1k | Error ImportArrayChecked(IIter Ibegin, IIter Iend, OIter Obegin) { | 708 | 13.1k | using ItemT = std::remove_reference_t<decltype(*Obegin)>; | 709 | 32.8k | for (; Ibegin != Iend; ++Ibegin, ++Obegin19.7k ) { | 710 | 19.7k | Expected<ItemT> ToOrErr = import(*Ibegin); | 711 | 19.7k | if (!ToOrErr) | 712 | 0 | return ToOrErr.takeError(); | 713 | 19.7k | *Obegin = *ToOrErr; | 714 | 19.7k | } | 715 | 13.1k | return Error::success(); | 716 | 13.1k | } |
|
717 | | |
718 | | // Import every item from a container structure into an output container. |
719 | | // If error occurs, stops at first error and returns the error. |
720 | | // The output container should have space for all needed elements (it is not |
721 | | // expanded, new items are put into from the beginning). |
722 | | template<typename InContainerTy, typename OutContainerTy> |
723 | | Error ImportContainerChecked( |
724 | 2.38M | const InContainerTy &InContainer, OutContainerTy &OutContainer) { |
725 | 2.38M | return ImportArrayChecked( |
726 | 2.38M | InContainer.begin(), InContainer.end(), OutContainer.begin()); |
727 | 2.38M | } llvm::Error clang::ASTNodeImporter::ImportContainerChecked<clang::TemplateParameterList, llvm::SmallVector<clang::NamedDecl*, 4u> >(clang::TemplateParameterList const&, llvm::SmallVector<clang::NamedDecl*, 4u>&) Line | Count | Source | 724 | 506k | const InContainerTy &InContainer, OutContainerTy &OutContainer) { | 725 | 506k | return ImportArrayChecked( | 726 | 506k | InContainer.begin(), InContainer.end(), OutContainer.begin()); | 727 | 506k | } |
llvm::Error clang::ASTNodeImporter::ImportContainerChecked<llvm::iterator_range<clang::CXXCtorInitializer**>, llvm::SmallVector<clang::CXXCtorInitializer*, 4u> >(llvm::iterator_range<clang::CXXCtorInitializer**> const&, llvm::SmallVector<clang::CXXCtorInitializer*, 4u>&) Line | Count | Source | 724 | 53.7k | const InContainerTy &InContainer, OutContainerTy &OutContainer) { | 725 | 53.7k | return ImportArrayChecked( | 726 | 53.7k | InContainer.begin(), InContainer.end(), OutContainer.begin()); | 727 | 53.7k | } |
llvm::Error clang::ASTNodeImporter::ImportContainerChecked<llvm::SmallVector<clang::SourceLocation, 12u>, llvm::SmallVector<clang::SourceLocation, 12u> >(llvm::SmallVector<clang::SourceLocation, 12u> const&, llvm::SmallVector<clang::SourceLocation, 12u>&) Line | Count | Source | 724 | 8.59k | const InContainerTy &InContainer, OutContainerTy &OutContainer) { | 725 | 8.59k | return ImportArrayChecked( | 726 | 8.59k | InContainer.begin(), InContainer.end(), OutContainer.begin()); | 727 | 8.59k | } |
llvm::Error clang::ASTNodeImporter::ImportContainerChecked<llvm::iterator_range<clang::Stmt::CastIterator<clang::Expr, clang::Expr*, clang::Stmt*> >, llvm::SmallVector<clang::Expr*, 4u> >(llvm::iterator_range<clang::Stmt::CastIterator<clang::Expr, clang::Expr*, clang::Stmt*> > const&, llvm::SmallVector<clang::Expr*, 4u>&) Line | Count | Source | 724 | 40.9k | const InContainerTy &InContainer, OutContainerTy &OutContainer) { | 725 | 40.9k | return ImportArrayChecked( | 726 | 40.9k | InContainer.begin(), InContainer.end(), OutContainer.begin()); | 727 | 40.9k | } |
llvm::Error clang::ASTNodeImporter::ImportContainerChecked<llvm::iterator_range<clang::Stmt**>, llvm::SmallVector<clang::Stmt*, 8u> >(llvm::iterator_range<clang::Stmt**> const&, llvm::SmallVector<clang::Stmt*, 8u>&) Line | Count | Source | 724 | 476k | const InContainerTy &InContainer, OutContainerTy &OutContainer) { | 725 | 476k | return ImportArrayChecked( | 726 | 476k | InContainer.begin(), InContainer.end(), OutContainer.begin()); | 727 | 476k | } |
llvm::Error clang::ASTNodeImporter::ImportContainerChecked<llvm::ArrayRef<clang::Attr const*>, llvm::SmallVector<clang::Attr const*, 1u> >(llvm::ArrayRef<clang::Attr const*> const&, llvm::SmallVector<clang::Attr const*, 1u>&) Line | Count | Source | 724 | 65 | const InContainerTy &InContainer, OutContainerTy &OutContainer) { | 725 | 65 | return ImportArrayChecked( | 726 | 65 | InContainer.begin(), InContainer.end(), OutContainer.begin()); | 727 | 65 | } |
llvm::Error clang::ASTNodeImporter::ImportContainerChecked<llvm::ArrayRef<clang::Expr*>, llvm::SmallVector<clang::Expr*, 8u> >(llvm::ArrayRef<clang::Expr*> const&, llvm::SmallVector<clang::Expr*, 8u>&) Line | Count | Source | 724 | 4 | const InContainerTy &InContainer, OutContainerTy &OutContainer) { | 725 | 4 | return ImportArrayChecked( | 726 | 4 | InContainer.begin(), InContainer.end(), OutContainer.begin()); | 727 | 4 | } |
llvm::Error clang::ASTNodeImporter::ImportContainerChecked<llvm::ArrayRef<clang::TypeSourceInfo const*>, llvm::SmallVector<clang::TypeSourceInfo*, 1u> >(llvm::ArrayRef<clang::TypeSourceInfo const*> const&, llvm::SmallVector<clang::TypeSourceInfo*, 1u>&) Line | Count | Source | 724 | 11 | const InContainerTy &InContainer, OutContainerTy &OutContainer) { | 725 | 11 | return ImportArrayChecked( | 726 | 11 | InContainer.begin(), InContainer.end(), OutContainer.begin()); | 727 | 11 | } |
llvm::Error clang::ASTNodeImporter::ImportContainerChecked<llvm::ArrayRef<clang::Expr const*>, llvm::SmallVector<clang::Expr*, 1u> >(llvm::ArrayRef<clang::Expr const*> const&, llvm::SmallVector<clang::Expr*, 1u>&) Line | Count | Source | 724 | 11 | const InContainerTy &InContainer, OutContainerTy &OutContainer) { | 725 | 11 | return ImportArrayChecked( | 726 | 11 | InContainer.begin(), InContainer.end(), OutContainer.begin()); | 727 | 11 | } |
llvm::Error clang::ASTNodeImporter::ImportContainerChecked<llvm::MutableArrayRef<clang::DesignatedInitExpr::Designator>, llvm::SmallVector<clang::DesignatedInitExpr::Designator, 4u> >(llvm::MutableArrayRef<clang::DesignatedInitExpr::Designator> const&, llvm::SmallVector<clang::DesignatedInitExpr::Designator, 4u>&) Line | Count | Source | 724 | 40 | const InContainerTy &InContainer, OutContainerTy &OutContainer) { | 725 | 40 | return ImportArrayChecked( | 726 | 40 | InContainer.begin(), InContainer.end(), OutContainer.begin()); | 727 | 40 | } |
llvm::Error clang::ASTNodeImporter::ImportContainerChecked<llvm::ArrayRef<clang::Expr*>, llvm::SmallVector<clang::Expr*, 4u> >(llvm::ArrayRef<clang::Expr*> const&, llvm::SmallVector<clang::Expr*, 4u>&) Line | Count | Source | 724 | 87.4k | const InContainerTy &InContainer, OutContainerTy &OutContainer) { | 725 | 87.4k | return ImportArrayChecked( | 726 | 87.4k | InContainer.begin(), InContainer.end(), OutContainer.begin()); | 727 | 87.4k | } |
llvm::Error clang::ASTNodeImporter::ImportContainerChecked<llvm::iterator_range<clang::Stmt::CastIterator<clang::Expr, clang::Expr*, clang::Stmt*> >, llvm::SmallVector<clang::Expr*, 8u> >(llvm::iterator_range<clang::Stmt::CastIterator<clang::Expr, clang::Expr*, clang::Stmt*> > const&, llvm::SmallVector<clang::Expr*, 8u>&) Line | Count | Source | 724 | 9.47k | const InContainerTy &InContainer, OutContainerTy &OutContainer) { | 725 | 9.47k | return ImportArrayChecked( | 726 | 9.47k | InContainer.begin(), InContainer.end(), OutContainer.begin()); | 727 | 9.47k | } |
llvm::Error clang::ASTNodeImporter::ImportContainerChecked<llvm::iterator_range<clang::Stmt::CastIterator<clang::Expr, clang::Expr*, clang::Stmt*> >, llvm::SmallVector<clang::Expr*, 6u> >(llvm::iterator_range<clang::Stmt::CastIterator<clang::Expr, clang::Expr*, clang::Stmt*> > const&, llvm::SmallVector<clang::Expr*, 6u>&) Line | Count | Source | 724 | 17.7k | const InContainerTy &InContainer, OutContainerTy &OutContainer) { | 725 | 17.7k | return ImportArrayChecked( | 726 | 17.7k | InContainer.begin(), InContainer.end(), OutContainer.begin()); | 727 | 17.7k | } |
llvm::Error clang::ASTNodeImporter::ImportContainerChecked<llvm::ArrayRef<llvm::PointerUnion<clang::BlockDecl*, clang::CompoundLiteralExpr*> >, llvm::SmallVector<llvm::PointerUnion<clang::BlockDecl*, clang::CompoundLiteralExpr*>, 8u> >(llvm::ArrayRef<llvm::PointerUnion<clang::BlockDecl*, clang::CompoundLiteralExpr*> > const&, llvm::SmallVector<llvm::PointerUnion<clang::BlockDecl*, clang::CompoundLiteralExpr*>, 8u>&) Line | Count | Source | 724 | 8.99k | const InContainerTy &InContainer, OutContainerTy &OutContainer) { | 725 | 8.99k | return ImportArrayChecked( | 726 | 8.99k | InContainer.begin(), InContainer.end(), OutContainer.begin()); | 727 | 8.99k | } |
llvm::Error clang::ASTNodeImporter::ImportContainerChecked<llvm::iterator_range<clang::Stmt::CastIterator<clang::Expr, clang::Expr*, clang::Stmt*> >, llvm::SmallVector<clang::Expr*, 2u> >(llvm::iterator_range<clang::Stmt::CastIterator<clang::Expr, clang::Expr*, clang::Stmt*> > const&, llvm::SmallVector<clang::Expr*, 2u>&) Line | Count | Source | 724 | 1.16M | const InContainerTy &InContainer, OutContainerTy &OutContainer) { | 725 | 1.16M | return ImportArrayChecked( | 726 | 1.16M | InContainer.begin(), InContainer.end(), OutContainer.begin()); | 727 | 1.16M | } |
llvm::Error clang::ASTNodeImporter::ImportContainerChecked<llvm::iterator_range<clang::Expr**>, llvm::SmallVector<clang::Expr*, 8u> >(llvm::iterator_range<clang::Expr**> const&, llvm::SmallVector<clang::Expr*, 8u>&) Line | Count | Source | 724 | 59 | const InContainerTy &InContainer, OutContainerTy &OutContainer) { | 725 | 59 | return ImportArrayChecked( | 726 | 59 | InContainer.begin(), InContainer.end(), OutContainer.begin()); | 727 | 59 | } |
llvm::Error clang::ASTNodeImporter::ImportContainerChecked<llvm::ArrayRef<clang::TypeSourceInfo*>, llvm::SmallVector<clang::TypeSourceInfo*, 4u> >(llvm::ArrayRef<clang::TypeSourceInfo*> const&, llvm::SmallVector<clang::TypeSourceInfo*, 4u>&) Line | Count | Source | 724 | 13.1k | const InContainerTy &InContainer, OutContainerTy &OutContainer) { | 725 | 13.1k | return ImportArrayChecked( | 726 | 13.1k | InContainer.begin(), InContainer.end(), OutContainer.begin()); | 727 | 13.1k | } |
llvm::Error clang::ASTNodeImporter::ImportContainerChecked<llvm::iterator_range<clang::Expr**>, llvm::SmallVector<clang::Expr*, 2u> >(llvm::iterator_range<clang::Expr**> const&, llvm::SmallVector<clang::Expr*, 2u>&) Line | Count | Source | 724 | 48 | const InContainerTy &InContainer, OutContainerTy &OutContainer) { | 725 | 48 | return ImportArrayChecked( | 726 | 48 | InContainer.begin(), InContainer.end(), OutContainer.begin()); | 727 | 48 | } |
|
728 | | |
729 | | template<typename InContainerTy, typename OIter> |
730 | 54 | Error ImportArrayChecked(const InContainerTy &InContainer, OIter Obegin) { |
731 | 54 | return ImportArrayChecked(InContainer.begin(), InContainer.end(), Obegin); |
732 | 54 | } llvm::Error clang::ASTNodeImporter::ImportArrayChecked<llvm::ArrayRef<clang::BindingDecl*>, clang::BindingDecl**>(llvm::ArrayRef<clang::BindingDecl*> const&, clang::BindingDecl**) Line | Count | Source | 730 | 48 | Error ImportArrayChecked(const InContainerTy &InContainer, OIter Obegin) { | 731 | 48 | return ImportArrayChecked(InContainer.begin(), InContainer.end(), Obegin); | 732 | 48 | } |
llvm::Error clang::ASTNodeImporter::ImportArrayChecked<llvm::iterator_range<clang::Stmt::CastIterator<clang::Expr, clang::Expr*, clang::Stmt*> >, clang::Expr**>(llvm::iterator_range<clang::Stmt::CastIterator<clang::Expr, clang::Expr*, clang::Stmt*> > const&, clang::Expr**) Line | Count | Source | 730 | 3 | Error ImportArrayChecked(const InContainerTy &InContainer, OIter Obegin) { | 731 | 3 | return ImportArrayChecked(InContainer.begin(), InContainer.end(), Obegin); | 732 | 3 | } |
llvm::Error clang::ASTNodeImporter::ImportArrayChecked<llvm::iterator_range<clang::Stmt::CastIterator<clang::AddrLabelExpr, clang::AddrLabelExpr*, clang::Stmt*> >, clang::Expr**>(llvm::iterator_range<clang::Stmt::CastIterator<clang::AddrLabelExpr, clang::AddrLabelExpr*, clang::Stmt*> > const&, clang::Expr**) Line | Count | Source | 730 | 3 | Error ImportArrayChecked(const InContainerTy &InContainer, OIter Obegin) { | 731 | 3 | return ImportArrayChecked(InContainer.begin(), InContainer.end(), Obegin); | 732 | 3 | } |
|
733 | | |
734 | | Error ImportOverriddenMethods(CXXMethodDecl *ToMethod, |
735 | | CXXMethodDecl *FromMethod); |
736 | | |
737 | | Expected<FunctionDecl *> FindFunctionTemplateSpecialization( |
738 | | FunctionDecl *FromFD); |
739 | | |
740 | | // Returns true if the given function has a placeholder return type and |
741 | | // that type is declared inside the body of the function. |
742 | | // E.g. auto f() { struct X{}; return X(); } |
743 | | bool hasAutoReturnTypeDeclaredInside(FunctionDecl *D); |
744 | | }; |
745 | | |
746 | | template <typename InContainerTy> |
747 | | Error ASTNodeImporter::ImportTemplateArgumentListInfo( |
748 | | SourceLocation FromLAngleLoc, SourceLocation FromRAngleLoc, |
749 | 49.0k | const InContainerTy &Container, TemplateArgumentListInfo &Result) { |
750 | 49.0k | auto ToLAngleLocOrErr = import(FromLAngleLoc); |
751 | 49.0k | if (!ToLAngleLocOrErr) |
752 | 0 | return ToLAngleLocOrErr.takeError(); |
753 | 49.0k | auto ToRAngleLocOrErr = import(FromRAngleLoc); |
754 | 49.0k | if (!ToRAngleLocOrErr) |
755 | 0 | return ToRAngleLocOrErr.takeError(); |
756 | | |
757 | 49.0k | TemplateArgumentListInfo ToTAInfo(*ToLAngleLocOrErr, *ToRAngleLocOrErr); |
758 | 49.0k | if (auto Err = ImportTemplateArgumentListInfo(Container, ToTAInfo)) |
759 | 0 | return Err; |
760 | 49.0k | Result = ToTAInfo; |
761 | 49.0k | return Error::success(); |
762 | 49.0k | } |
763 | | |
764 | | template <> |
765 | | Error ASTNodeImporter::ImportTemplateArgumentListInfo<TemplateArgumentListInfo>( |
766 | 470 | const TemplateArgumentListInfo &From, TemplateArgumentListInfo &Result) { |
767 | 470 | return ImportTemplateArgumentListInfo( |
768 | 470 | From.getLAngleLoc(), From.getRAngleLoc(), From.arguments(), Result); |
769 | 470 | } |
770 | | |
771 | | template <> |
772 | | Error ASTNodeImporter::ImportTemplateArgumentListInfo< |
773 | | ASTTemplateArgumentListInfo>( |
774 | | const ASTTemplateArgumentListInfo &From, |
775 | 2.96k | TemplateArgumentListInfo &Result) { |
776 | 2.96k | return ImportTemplateArgumentListInfo( |
777 | 2.96k | From.LAngleLoc, From.RAngleLoc, From.arguments(), Result); |
778 | 2.96k | } |
779 | | |
780 | | Expected<ASTNodeImporter::FunctionTemplateAndArgsTy> |
781 | | ASTNodeImporter::ImportFunctionTemplateWithTemplateArgsFromSpecialization( |
782 | 32.1k | FunctionDecl *FromFD) { |
783 | 32.1k | assert(FromFD->getTemplatedKind() == |
784 | 32.1k | FunctionDecl::TK_FunctionTemplateSpecialization); |
785 | | |
786 | 0 | FunctionTemplateAndArgsTy Result; |
787 | | |
788 | 32.1k | auto *FTSInfo = FromFD->getTemplateSpecializationInfo(); |
789 | 32.1k | if (Error Err = importInto(std::get<0>(Result), FTSInfo->getTemplate())) |
790 | 0 | return std::move(Err); |
791 | | |
792 | | // Import template arguments. |
793 | 32.1k | auto TemplArgs = FTSInfo->TemplateArguments->asArray(); |
794 | 32.1k | if (Error Err = ImportTemplateArguments(TemplArgs.data(), TemplArgs.size(), |
795 | 32.1k | std::get<1>(Result))) |
796 | 0 | return std::move(Err); |
797 | | |
798 | 32.1k | return Result; |
799 | 32.1k | } |
800 | | |
801 | | template <> |
802 | | Expected<TemplateParameterList *> |
803 | 506k | ASTNodeImporter::import(TemplateParameterList *From) { |
804 | 506k | SmallVector<NamedDecl *, 4> To(From->size()); |
805 | 506k | if (Error Err = ImportContainerChecked(*From, To)) |
806 | 0 | return std::move(Err); |
807 | | |
808 | 506k | ExpectedExpr ToRequiresClause = import(From->getRequiresClause()); |
809 | 506k | if (!ToRequiresClause) |
810 | 0 | return ToRequiresClause.takeError(); |
811 | | |
812 | 506k | auto ToTemplateLocOrErr = import(From->getTemplateLoc()); |
813 | 506k | if (!ToTemplateLocOrErr) |
814 | 0 | return ToTemplateLocOrErr.takeError(); |
815 | 506k | auto ToLAngleLocOrErr = import(From->getLAngleLoc()); |
816 | 506k | if (!ToLAngleLocOrErr) |
817 | 0 | return ToLAngleLocOrErr.takeError(); |
818 | 506k | auto ToRAngleLocOrErr = import(From->getRAngleLoc()); |
819 | 506k | if (!ToRAngleLocOrErr) |
820 | 0 | return ToRAngleLocOrErr.takeError(); |
821 | | |
822 | 506k | return TemplateParameterList::Create( |
823 | 506k | Importer.getToContext(), |
824 | 506k | *ToTemplateLocOrErr, |
825 | 506k | *ToLAngleLocOrErr, |
826 | 506k | To, |
827 | 506k | *ToRAngleLocOrErr, |
828 | 506k | *ToRequiresClause); |
829 | 506k | } |
830 | | |
831 | | template <> |
832 | | Expected<TemplateArgument> |
833 | 2.09M | ASTNodeImporter::import(const TemplateArgument &From) { |
834 | 2.09M | switch (From.getKind()) { |
835 | 0 | case TemplateArgument::Null: |
836 | 0 | return TemplateArgument(); |
837 | | |
838 | 1.70M | case TemplateArgument::Type: { |
839 | 1.70M | ExpectedType ToTypeOrErr = import(From.getAsType()); |
840 | 1.70M | if (!ToTypeOrErr) |
841 | 0 | return ToTypeOrErr.takeError(); |
842 | 1.70M | return TemplateArgument(*ToTypeOrErr); |
843 | 1.70M | } |
844 | | |
845 | 48.5k | case TemplateArgument::Integral: { |
846 | 48.5k | ExpectedType ToTypeOrErr = import(From.getIntegralType()); |
847 | 48.5k | if (!ToTypeOrErr) |
848 | 0 | return ToTypeOrErr.takeError(); |
849 | 48.5k | return TemplateArgument(From, *ToTypeOrErr); |
850 | 48.5k | } |
851 | | |
852 | 0 | case TemplateArgument::Declaration: { |
853 | 0 | Expected<ValueDecl *> ToOrErr = import(From.getAsDecl()); |
854 | 0 | if (!ToOrErr) |
855 | 0 | return ToOrErr.takeError(); |
856 | 0 | ExpectedType ToTypeOrErr = import(From.getParamTypeForDecl()); |
857 | 0 | if (!ToTypeOrErr) |
858 | 0 | return ToTypeOrErr.takeError(); |
859 | 0 | return TemplateArgument(*ToOrErr, *ToTypeOrErr); |
860 | 0 | } |
861 | | |
862 | 378 | case TemplateArgument::NullPtr: { |
863 | 378 | ExpectedType ToTypeOrErr = import(From.getNullPtrType()); |
864 | 378 | if (!ToTypeOrErr) |
865 | 0 | return ToTypeOrErr.takeError(); |
866 | 378 | return TemplateArgument(*ToTypeOrErr, /*isNullPtr*/true); |
867 | 378 | } |
868 | | |
869 | 2.66k | case TemplateArgument::Template: { |
870 | 2.66k | Expected<TemplateName> ToTemplateOrErr = import(From.getAsTemplate()); |
871 | 2.66k | if (!ToTemplateOrErr) |
872 | 0 | return ToTemplateOrErr.takeError(); |
873 | | |
874 | 2.66k | return TemplateArgument(*ToTemplateOrErr); |
875 | 2.66k | } |
876 | | |
877 | 0 | case TemplateArgument::TemplateExpansion: { |
878 | 0 | Expected<TemplateName> ToTemplateOrErr = |
879 | 0 | import(From.getAsTemplateOrTemplatePattern()); |
880 | 0 | if (!ToTemplateOrErr) |
881 | 0 | return ToTemplateOrErr.takeError(); |
882 | | |
883 | 0 | return TemplateArgument( |
884 | 0 | *ToTemplateOrErr, From.getNumTemplateExpansions()); |
885 | 0 | } |
886 | | |
887 | 315k | case TemplateArgument::Expression: |
888 | 315k | if (ExpectedExpr ToExpr = import(From.getAsExpr())) |
889 | 315k | return TemplateArgument(*ToExpr); |
890 | 0 | else |
891 | 0 | return ToExpr.takeError(); |
892 | | |
893 | 15.0k | case TemplateArgument::Pack: { |
894 | 15.0k | SmallVector<TemplateArgument, 2> ToPack; |
895 | 15.0k | ToPack.reserve(From.pack_size()); |
896 | 15.0k | if (Error Err = ImportTemplateArguments( |
897 | 15.0k | From.pack_begin(), From.pack_size(), ToPack)) |
898 | 0 | return std::move(Err); |
899 | | |
900 | 15.0k | return TemplateArgument( |
901 | 15.0k | llvm::makeArrayRef(ToPack).copy(Importer.getToContext())); |
902 | 15.0k | } |
903 | 2.09M | } |
904 | | |
905 | 0 | llvm_unreachable("Invalid template argument kind"); |
906 | 0 | } |
907 | | |
908 | | template <> |
909 | | Expected<TemplateArgumentLoc> |
910 | 71.7k | ASTNodeImporter::import(const TemplateArgumentLoc &TALoc) { |
911 | 71.7k | Expected<TemplateArgument> ArgOrErr = import(TALoc.getArgument()); |
912 | 71.7k | if (!ArgOrErr) |
913 | 0 | return ArgOrErr.takeError(); |
914 | 71.7k | TemplateArgument Arg = *ArgOrErr; |
915 | | |
916 | 71.7k | TemplateArgumentLocInfo FromInfo = TALoc.getLocInfo(); |
917 | | |
918 | 71.7k | TemplateArgumentLocInfo ToInfo; |
919 | 71.7k | if (Arg.getKind() == TemplateArgument::Expression) { |
920 | 11.3k | ExpectedExpr E = import(FromInfo.getAsExpr()); |
921 | 11.3k | if (!E) |
922 | 0 | return E.takeError(); |
923 | 11.3k | ToInfo = TemplateArgumentLocInfo(*E); |
924 | 60.4k | } else if (Arg.getKind() == TemplateArgument::Type) { |
925 | 59.1k | if (auto TSIOrErr = import(FromInfo.getAsTypeSourceInfo())) |
926 | 59.1k | ToInfo = TemplateArgumentLocInfo(*TSIOrErr); |
927 | 0 | else |
928 | 0 | return TSIOrErr.takeError(); |
929 | 59.1k | } else { |
930 | 1.26k | auto ToTemplateQualifierLocOrErr = |
931 | 1.26k | import(FromInfo.getTemplateQualifierLoc()); |
932 | 1.26k | if (!ToTemplateQualifierLocOrErr) |
933 | 0 | return ToTemplateQualifierLocOrErr.takeError(); |
934 | 1.26k | auto ToTemplateNameLocOrErr = import(FromInfo.getTemplateNameLoc()); |
935 | 1.26k | if (!ToTemplateNameLocOrErr) |
936 | 0 | return ToTemplateNameLocOrErr.takeError(); |
937 | 1.26k | auto ToTemplateEllipsisLocOrErr = |
938 | 1.26k | import(FromInfo.getTemplateEllipsisLoc()); |
939 | 1.26k | if (!ToTemplateEllipsisLocOrErr) |
940 | 0 | return ToTemplateEllipsisLocOrErr.takeError(); |
941 | 1.26k | ToInfo = TemplateArgumentLocInfo( |
942 | 1.26k | Importer.getToContext(), *ToTemplateQualifierLocOrErr, |
943 | 1.26k | *ToTemplateNameLocOrErr, *ToTemplateEllipsisLocOrErr); |
944 | 1.26k | } |
945 | | |
946 | 71.7k | return TemplateArgumentLoc(Arg, ToInfo); |
947 | 71.7k | } |
948 | | |
949 | | template <> |
950 | 226k | Expected<DeclGroupRef> ASTNodeImporter::import(const DeclGroupRef &DG) { |
951 | 226k | if (DG.isNull()) |
952 | 0 | return DeclGroupRef::Create(Importer.getToContext(), nullptr, 0); |
953 | 226k | size_t NumDecls = DG.end() - DG.begin(); |
954 | 226k | SmallVector<Decl *, 1> ToDecls; |
955 | 226k | ToDecls.reserve(NumDecls); |
956 | 230k | for (Decl *FromD : DG) { |
957 | 230k | if (auto ToDOrErr = import(FromD)) |
958 | 230k | ToDecls.push_back(*ToDOrErr); |
959 | 0 | else |
960 | 0 | return ToDOrErr.takeError(); |
961 | 230k | } |
962 | 226k | return DeclGroupRef::Create(Importer.getToContext(), |
963 | 226k | ToDecls.begin(), |
964 | 226k | NumDecls); |
965 | 226k | } |
966 | | |
967 | | template <> |
968 | | Expected<ASTNodeImporter::Designator> |
969 | 69 | ASTNodeImporter::import(const Designator &D) { |
970 | 69 | if (D.isFieldDesignator()) { |
971 | 43 | IdentifierInfo *ToFieldName = Importer.Import(D.getFieldName()); |
972 | | |
973 | 43 | ExpectedSLoc ToDotLocOrErr = import(D.getDotLoc()); |
974 | 43 | if (!ToDotLocOrErr) |
975 | 0 | return ToDotLocOrErr.takeError(); |
976 | | |
977 | 43 | ExpectedSLoc ToFieldLocOrErr = import(D.getFieldLoc()); |
978 | 43 | if (!ToFieldLocOrErr) |
979 | 0 | return ToFieldLocOrErr.takeError(); |
980 | | |
981 | 43 | return Designator(ToFieldName, *ToDotLocOrErr, *ToFieldLocOrErr); |
982 | 43 | } |
983 | | |
984 | 26 | ExpectedSLoc ToLBracketLocOrErr = import(D.getLBracketLoc()); |
985 | 26 | if (!ToLBracketLocOrErr) |
986 | 0 | return ToLBracketLocOrErr.takeError(); |
987 | | |
988 | 26 | ExpectedSLoc ToRBracketLocOrErr = import(D.getRBracketLoc()); |
989 | 26 | if (!ToRBracketLocOrErr) |
990 | 0 | return ToRBracketLocOrErr.takeError(); |
991 | | |
992 | 26 | if (D.isArrayDesignator()) |
993 | 26 | return Designator(D.getFirstExprIndex(), |
994 | 26 | *ToLBracketLocOrErr, *ToRBracketLocOrErr); |
995 | | |
996 | 0 | ExpectedSLoc ToEllipsisLocOrErr = import(D.getEllipsisLoc()); |
997 | 0 | if (!ToEllipsisLocOrErr) |
998 | 0 | return ToEllipsisLocOrErr.takeError(); |
999 | | |
1000 | 0 | assert(D.isArrayRangeDesignator()); |
1001 | 0 | return Designator( |
1002 | 0 | D.getFirstExprIndex(), *ToLBracketLocOrErr, *ToEllipsisLocOrErr, |
1003 | 0 | *ToRBracketLocOrErr); |
1004 | 0 | } |
1005 | | |
1006 | | template <> |
1007 | 26 | Expected<LambdaCapture> ASTNodeImporter::import(const LambdaCapture &From) { |
1008 | 26 | VarDecl *Var = nullptr; |
1009 | 26 | if (From.capturesVariable()) { |
1010 | 21 | if (auto VarOrErr = import(From.getCapturedVar())) |
1011 | 21 | Var = *VarOrErr; |
1012 | 0 | else |
1013 | 0 | return VarOrErr.takeError(); |
1014 | 21 | } |
1015 | | |
1016 | 26 | auto LocationOrErr = import(From.getLocation()); |
1017 | 26 | if (!LocationOrErr) |
1018 | 0 | return LocationOrErr.takeError(); |
1019 | | |
1020 | 26 | SourceLocation EllipsisLoc; |
1021 | 26 | if (From.isPackExpansion()) |
1022 | 0 | if (Error Err = importInto(EllipsisLoc, From.getEllipsisLoc())) |
1023 | 0 | return std::move(Err); |
1024 | | |
1025 | 26 | return LambdaCapture( |
1026 | 26 | *LocationOrErr, From.isImplicit(), From.getCaptureKind(), Var, |
1027 | 26 | EllipsisLoc); |
1028 | 26 | } |
1029 | | |
1030 | | template <typename T> |
1031 | 4.57M | bool ASTNodeImporter::hasSameVisibilityContextAndLinkage(T *Found, T *From) { |
1032 | 4.57M | if (Found->getLinkageInternal() != From->getLinkageInternal()) |
1033 | 466 | return false; |
1034 | | |
1035 | 4.57M | if (From->hasExternalFormalLinkage()) |
1036 | 4.57M | return Found->hasExternalFormalLinkage(); |
1037 | 622 | if (Importer.GetFromTU(Found) != From->getTranslationUnitDecl()) |
1038 | 181 | return false; |
1039 | 441 | if (From->isInAnonymousNamespace()) |
1040 | 58 | return Found->isInAnonymousNamespace(); |
1041 | 383 | else |
1042 | 383 | return !Found->isInAnonymousNamespace() && |
1043 | 383 | !Found->hasExternalFormalLinkage(); |
1044 | 441 | } bool clang::ASTNodeImporter::hasSameVisibilityContextAndLinkage<clang::EnumDecl>(clang::EnumDecl*, clang::EnumDecl*) Line | Count | Source | 1031 | 139 | bool ASTNodeImporter::hasSameVisibilityContextAndLinkage(T *Found, T *From) { | 1032 | 139 | if (Found->getLinkageInternal() != From->getLinkageInternal()) | 1033 | 0 | return false; | 1034 | | | 1035 | 139 | if (From->hasExternalFormalLinkage()) | 1036 | 119 | return Found->hasExternalFormalLinkage(); | 1037 | 20 | if (Importer.GetFromTU(Found) != From->getTranslationUnitDecl()) | 1038 | 16 | return false; | 1039 | 4 | if (From->isInAnonymousNamespace()) | 1040 | 4 | return Found->isInAnonymousNamespace(); | 1041 | 0 | else | 1042 | 0 | return !Found->isInAnonymousNamespace() && | 1043 | 0 | !Found->hasExternalFormalLinkage(); | 1044 | 4 | } |
bool clang::ASTNodeImporter::hasSameVisibilityContextAndLinkage<clang::RecordDecl>(clang::RecordDecl*, clang::RecordDecl*) Line | Count | Source | 1031 | 4.26k | bool ASTNodeImporter::hasSameVisibilityContextAndLinkage(T *Found, T *From) { | 1032 | 4.26k | if (Found->getLinkageInternal() != From->getLinkageInternal()) | 1033 | 0 | return false; | 1034 | | | 1035 | 4.26k | if (From->hasExternalFormalLinkage()) | 1036 | 4.24k | return Found->hasExternalFormalLinkage(); | 1037 | 25 | if (Importer.GetFromTU(Found) != From->getTranslationUnitDecl()) | 1038 | 17 | return false; | 1039 | 8 | if (From->isInAnonymousNamespace()) | 1040 | 8 | return Found->isInAnonymousNamespace(); | 1041 | 0 | else | 1042 | 0 | return !Found->isInAnonymousNamespace() && | 1043 | 0 | !Found->hasExternalFormalLinkage(); | 1044 | 8 | } |
bool clang::ASTNodeImporter::hasSameVisibilityContextAndLinkage<clang::FunctionDecl>(clang::FunctionDecl*, clang::FunctionDecl*) Line | Count | Source | 1031 | 1.15M | bool ASTNodeImporter::hasSameVisibilityContextAndLinkage(T *Found, T *From) { | 1032 | 1.15M | if (Found->getLinkageInternal() != From->getLinkageInternal()) | 1033 | 244 | return false; | 1034 | | | 1035 | 1.15M | if (From->hasExternalFormalLinkage()) | 1036 | 1.15M | return Found->hasExternalFormalLinkage(); | 1037 | 293 | if (Importer.GetFromTU(Found) != From->getTranslationUnitDecl()) | 1038 | 36 | return false; | 1039 | 257 | if (From->isInAnonymousNamespace()) | 1040 | 8 | return Found->isInAnonymousNamespace(); | 1041 | 249 | else | 1042 | 249 | return !Found->isInAnonymousNamespace() && | 1043 | 249 | !Found->hasExternalFormalLinkage(); | 1044 | 257 | } |
bool clang::ASTNodeImporter::hasSameVisibilityContextAndLinkage<clang::VarDecl>(clang::VarDecl*, clang::VarDecl*) Line | Count | Source | 1031 | 7.20k | bool ASTNodeImporter::hasSameVisibilityContextAndLinkage(T *Found, T *From) { | 1032 | 7.20k | if (Found->getLinkageInternal() != From->getLinkageInternal()) | 1033 | 64 | return false; | 1034 | | | 1035 | 7.13k | if (From->hasExternalFormalLinkage()) | 1036 | 7.05k | return Found->hasExternalFormalLinkage(); | 1037 | 84 | if (Importer.GetFromTU(Found) != From->getTranslationUnitDecl()) | 1038 | 64 | return false; | 1039 | 20 | if (From->isInAnonymousNamespace()) | 1040 | 16 | return Found->isInAnonymousNamespace(); | 1041 | 4 | else | 1042 | 4 | return !Found->isInAnonymousNamespace() && | 1043 | 4 | !Found->hasExternalFormalLinkage(); | 1044 | 20 | } |
bool clang::ASTNodeImporter::hasSameVisibilityContextAndLinkage<clang::ClassTemplateDecl>(clang::ClassTemplateDecl*, clang::ClassTemplateDecl*) Line | Count | Source | 1031 | 95.0k | bool ASTNodeImporter::hasSameVisibilityContextAndLinkage(T *Found, T *From) { | 1032 | 95.0k | if (Found->getLinkageInternal() != From->getLinkageInternal()) | 1033 | 0 | return false; | 1034 | | | 1035 | 95.0k | if (From->hasExternalFormalLinkage()) | 1036 | 95.0k | return Found->hasExternalFormalLinkage(); | 1037 | 30 | if (Importer.GetFromTU(Found) != From->getTranslationUnitDecl()) | 1038 | 16 | return false; | 1039 | 14 | if (From->isInAnonymousNamespace()) | 1040 | 14 | return Found->isInAnonymousNamespace(); | 1041 | 0 | else | 1042 | 0 | return !Found->isInAnonymousNamespace() && | 1043 | 0 | !Found->hasExternalFormalLinkage(); | 1044 | 14 | } |
bool clang::ASTNodeImporter::hasSameVisibilityContextAndLinkage<clang::FunctionTemplateDecl>(clang::FunctionTemplateDecl*, clang::FunctionTemplateDecl*) Line | Count | Source | 1031 | 3.31M | bool ASTNodeImporter::hasSameVisibilityContextAndLinkage(T *Found, T *From) { | 1032 | 3.31M | if (Found->getLinkageInternal() != From->getLinkageInternal()) | 1033 | 158 | return false; | 1034 | | | 1035 | 3.31M | if (From->hasExternalFormalLinkage()) | 1036 | 3.31M | return Found->hasExternalFormalLinkage(); | 1037 | 170 | if (Importer.GetFromTU(Found) != From->getTranslationUnitDecl()) | 1038 | 32 | return false; | 1039 | 138 | if (From->isInAnonymousNamespace()) | 1040 | 8 | return Found->isInAnonymousNamespace(); | 1041 | 130 | else | 1042 | 130 | return !Found->isInAnonymousNamespace() && | 1043 | 130 | !Found->hasExternalFormalLinkage(); | 1044 | 138 | } |
|
1045 | | |
1046 | | template <> |
1047 | | bool ASTNodeImporter::hasSameVisibilityContextAndLinkage(TypedefNameDecl *Found, |
1048 | 18.8k | TypedefNameDecl *From) { |
1049 | 18.8k | if (Found->getLinkageInternal() != From->getLinkageInternal()) |
1050 | 0 | return false; |
1051 | | |
1052 | 18.8k | if (From->isInAnonymousNamespace() && Found->isInAnonymousNamespace()0 ) |
1053 | 0 | return Importer.GetFromTU(Found) == From->getTranslationUnitDecl(); |
1054 | 18.8k | return From->isInAnonymousNamespace() == Found->isInAnonymousNamespace(); |
1055 | 18.8k | } |
1056 | | |
1057 | | } // namespace clang |
1058 | | |
1059 | | //---------------------------------------------------------------------------- |
1060 | | // Import Types |
1061 | | //---------------------------------------------------------------------------- |
1062 | | |
1063 | | using namespace clang; |
1064 | | |
1065 | 327 | ExpectedType ASTNodeImporter::VisitType(const Type *T) { |
1066 | 327 | Importer.FromDiag(SourceLocation(), diag::err_unsupported_ast_node) |
1067 | 327 | << T->getTypeClassName(); |
1068 | 327 | return make_error<ImportError>(ImportError::UnsupportedConstruct); |
1069 | 327 | } |
1070 | | |
1071 | 67 | ExpectedType ASTNodeImporter::VisitAtomicType(const AtomicType *T){ |
1072 | 67 | ExpectedType UnderlyingTypeOrErr = import(T->getValueType()); |
1073 | 67 | if (!UnderlyingTypeOrErr) |
1074 | 0 | return UnderlyingTypeOrErr.takeError(); |
1075 | | |
1076 | 67 | return Importer.getToContext().getAtomicType(*UnderlyingTypeOrErr); |
1077 | 67 | } |
1078 | | |
1079 | 34.1k | ExpectedType ASTNodeImporter::VisitBuiltinType(const BuiltinType *T) { |
1080 | 34.1k | switch (T->getKind()) { |
1081 | 0 | #define IMAGE_TYPE(ImgType, Id, SingletonId, Access, Suffix) \ |
1082 | 0 | case BuiltinType::Id: \ |
1083 | 0 | return Importer.getToContext().SingletonId; |
1084 | 0 | #include "clang/Basic/OpenCLImageTypes.def" |
1085 | 0 | #define EXT_OPAQUE_TYPE(ExtType, Id, Ext) \ |
1086 | 0 | case BuiltinType::Id: \ |
1087 | 0 | return Importer.getToContext().Id##Ty; |
1088 | 0 | #include "clang/Basic/OpenCLExtensionTypes.def" |
1089 | 0 | #define SVE_TYPE(Name, Id, SingletonId) \ |
1090 | 13 | case BuiltinType::Id: \ |
1091 | 13 | return Importer.getToContext().SingletonId; |
1092 | 0 | #include "clang/Basic/AArch64SVEACLETypes.def" |
1093 | 0 | #define PPC_VECTOR_TYPE(Name, Id, Size) \ |
1094 | 0 | case BuiltinType::Id: \ |
1095 | 0 | return Importer.getToContext().Id##Ty; |
1096 | 1 | #include "clang/Basic/PPCTypes.def" |
1097 | 0 | #define RVV_TYPE(Name, Id, SingletonId) \ |
1098 | 0 | case BuiltinType::Id: \ |
1099 | 0 | return Importer.getToContext().SingletonId; |
1100 | 0 | #include "clang/Basic/RISCVVTypes.def" |
1101 | 0 | #define SHARED_SINGLETON_TYPE(Expansion) |
1102 | 0 | #define BUILTIN_TYPE(Id, SingletonId) \ |
1103 | 31.4k | case BuiltinType::Id: return Importer.getToContext().SingletonId; |
1104 | 0 | #include "clang/AST/BuiltinTypes.def" |
1105 | | |
1106 | | // FIXME: for Char16, Char32, and NullPtr, make sure that the "to" |
1107 | | // context supports C++. |
1108 | | |
1109 | | // FIXME: for ObjCId, ObjCClass, and ObjCSel, make sure that the "to" |
1110 | | // context supports ObjC. |
1111 | | |
1112 | 0 | case BuiltinType::Char_U: |
1113 | | // The context we're importing from has an unsigned 'char'. If we're |
1114 | | // importing into a context with a signed 'char', translate to |
1115 | | // 'unsigned char' instead. |
1116 | 0 | if (Importer.getToContext().getLangOpts().CharIsSigned) |
1117 | 0 | return Importer.getToContext().UnsignedCharTy; |
1118 | | |
1119 | 0 | return Importer.getToContext().CharTy; |
1120 | | |
1121 | 2.55k | case BuiltinType::Char_S: |
1122 | | // The context we're importing from has an unsigned 'char'. If we're |
1123 | | // importing into a context with a signed 'char', translate to |
1124 | | // 'unsigned char' instead. |
1125 | 2.55k | if (!Importer.getToContext().getLangOpts().CharIsSigned) |
1126 | 0 | return Importer.getToContext().SignedCharTy; |
1127 | | |
1128 | 2.55k | return Importer.getToContext().CharTy; |
1129 | | |
1130 | 85 | case BuiltinType::WChar_S: |
1131 | 85 | case BuiltinType::WChar_U: |
1132 | | // FIXME: If not in C++, shall we translate to the C equivalent of |
1133 | | // wchar_t? |
1134 | 85 | return Importer.getToContext().WCharTy; |
1135 | 34.1k | } |
1136 | | |
1137 | 0 | llvm_unreachable("Invalid BuiltinType Kind!"); |
1138 | 0 | } |
1139 | | |
1140 | 539 | ExpectedType ASTNodeImporter::VisitDecayedType(const DecayedType *T) { |
1141 | 539 | ExpectedType ToOriginalTypeOrErr = import(T->getOriginalType()); |
1142 | 539 | if (!ToOriginalTypeOrErr) |
1143 | 29 | return ToOriginalTypeOrErr.takeError(); |
1144 | | |
1145 | 510 | return Importer.getToContext().getDecayedType(*ToOriginalTypeOrErr); |
1146 | 539 | } |
1147 | | |
1148 | 26 | ExpectedType ASTNodeImporter::VisitComplexType(const ComplexType *T) { |
1149 | 26 | ExpectedType ToElementTypeOrErr = import(T->getElementType()); |
1150 | 26 | if (!ToElementTypeOrErr) |
1151 | 0 | return ToElementTypeOrErr.takeError(); |
1152 | | |
1153 | 26 | return Importer.getToContext().getComplexType(*ToElementTypeOrErr); |
1154 | 26 | } |
1155 | | |
1156 | 146k | ExpectedType ASTNodeImporter::VisitPointerType(const PointerType *T) { |
1157 | 146k | ExpectedType ToPointeeTypeOrErr = import(T->getPointeeType()); |
1158 | 146k | if (!ToPointeeTypeOrErr) |
1159 | 29 | return ToPointeeTypeOrErr.takeError(); |
1160 | | |
1161 | 146k | return Importer.getToContext().getPointerType(*ToPointeeTypeOrErr); |
1162 | 146k | } |
1163 | | |
1164 | 37 | ExpectedType ASTNodeImporter::VisitBlockPointerType(const BlockPointerType *T) { |
1165 | | // FIXME: Check for blocks support in "to" context. |
1166 | 37 | ExpectedType ToPointeeTypeOrErr = import(T->getPointeeType()); |
1167 | 37 | if (!ToPointeeTypeOrErr) |
1168 | 0 | return ToPointeeTypeOrErr.takeError(); |
1169 | | |
1170 | 37 | return Importer.getToContext().getBlockPointerType(*ToPointeeTypeOrErr); |
1171 | 37 | } |
1172 | | |
1173 | | ExpectedType |
1174 | 305k | ASTNodeImporter::VisitLValueReferenceType(const LValueReferenceType *T) { |
1175 | | // FIXME: Check for C++ support in "to" context. |
1176 | 305k | ExpectedType ToPointeeTypeOrErr = import(T->getPointeeTypeAsWritten()); |
1177 | 305k | if (!ToPointeeTypeOrErr) |
1178 | 0 | return ToPointeeTypeOrErr.takeError(); |
1179 | | |
1180 | 305k | return Importer.getToContext().getLValueReferenceType(*ToPointeeTypeOrErr); |
1181 | 305k | } |
1182 | | |
1183 | | ExpectedType |
1184 | 64.1k | ASTNodeImporter::VisitRValueReferenceType(const RValueReferenceType *T) { |
1185 | | // FIXME: Check for C++0x support in "to" context. |
1186 | 64.1k | ExpectedType ToPointeeTypeOrErr = import(T->getPointeeTypeAsWritten()); |
1187 | 64.1k | if (!ToPointeeTypeOrErr) |
1188 | 0 | return ToPointeeTypeOrErr.takeError(); |
1189 | | |
1190 | 64.1k | return Importer.getToContext().getRValueReferenceType(*ToPointeeTypeOrErr); |
1191 | 64.1k | } |
1192 | | |
1193 | | ExpectedType |
1194 | 2 | ASTNodeImporter::VisitMemberPointerType(const MemberPointerType *T) { |
1195 | | // FIXME: Check for C++ support in "to" context. |
1196 | 2 | ExpectedType ToPointeeTypeOrErr = import(T->getPointeeType()); |
1197 | 2 | if (!ToPointeeTypeOrErr) |
1198 | 0 | return ToPointeeTypeOrErr.takeError(); |
1199 | | |
1200 | 2 | ExpectedTypePtr ClassTypeOrErr = import(T->getClass()); |
1201 | 2 | if (!ClassTypeOrErr) |
1202 | 0 | return ClassTypeOrErr.takeError(); |
1203 | | |
1204 | 2 | return Importer.getToContext().getMemberPointerType(*ToPointeeTypeOrErr, |
1205 | 2 | *ClassTypeOrErr); |
1206 | 2 | } |
1207 | | |
1208 | | ExpectedType |
1209 | 9.61k | ASTNodeImporter::VisitConstantArrayType(const ConstantArrayType *T) { |
1210 | 9.61k | Error Err = Error::success(); |
1211 | 9.61k | auto ToElementType = importChecked(Err, T->getElementType()); |
1212 | 9.61k | auto ToSizeExpr = importChecked(Err, T->getSizeExpr()); |
1213 | 9.61k | if (Err) |
1214 | 0 | return std::move(Err); |
1215 | | |
1216 | 9.61k | return Importer.getToContext().getConstantArrayType( |
1217 | 9.61k | ToElementType, T->getSize(), ToSizeExpr, T->getSizeModifier(), |
1218 | 9.61k | T->getIndexTypeCVRQualifiers()); |
1219 | 9.61k | } |
1220 | | |
1221 | | ExpectedType |
1222 | 590 | ASTNodeImporter::VisitIncompleteArrayType(const IncompleteArrayType *T) { |
1223 | 590 | ExpectedType ToElementTypeOrErr = import(T->getElementType()); |
1224 | 590 | if (!ToElementTypeOrErr) |
1225 | 29 | return ToElementTypeOrErr.takeError(); |
1226 | | |
1227 | 561 | return Importer.getToContext().getIncompleteArrayType(*ToElementTypeOrErr, |
1228 | 561 | T->getSizeModifier(), |
1229 | 561 | T->getIndexTypeCVRQualifiers()); |
1230 | 590 | } |
1231 | | |
1232 | | ExpectedType |
1233 | 4 | ASTNodeImporter::VisitVariableArrayType(const VariableArrayType *T) { |
1234 | 4 | Error Err = Error::success(); |
1235 | 4 | QualType ToElementType = importChecked(Err, T->getElementType()); |
1236 | 4 | Expr *ToSizeExpr = importChecked(Err, T->getSizeExpr()); |
1237 | 4 | SourceRange ToBracketsRange = importChecked(Err, T->getBracketsRange()); |
1238 | 4 | if (Err) |
1239 | 0 | return std::move(Err); |
1240 | 4 | return Importer.getToContext().getVariableArrayType( |
1241 | 4 | ToElementType, ToSizeExpr, T->getSizeModifier(), |
1242 | 4 | T->getIndexTypeCVRQualifiers(), ToBracketsRange); |
1243 | 4 | } |
1244 | | |
1245 | | ExpectedType ASTNodeImporter::VisitDependentSizedArrayType( |
1246 | 1.62k | const DependentSizedArrayType *T) { |
1247 | 1.62k | Error Err = Error::success(); |
1248 | 1.62k | QualType ToElementType = importChecked(Err, T->getElementType()); |
1249 | 1.62k | Expr *ToSizeExpr = importChecked(Err, T->getSizeExpr()); |
1250 | 1.62k | SourceRange ToBracketsRange = importChecked(Err, T->getBracketsRange()); |
1251 | 1.62k | if (Err) |
1252 | 0 | return std::move(Err); |
1253 | | // SizeExpr may be null if size is not specified directly. |
1254 | | // For example, 'int a[]'. |
1255 | | |
1256 | 1.62k | return Importer.getToContext().getDependentSizedArrayType( |
1257 | 1.62k | ToElementType, ToSizeExpr, T->getSizeModifier(), |
1258 | 1.62k | T->getIndexTypeCVRQualifiers(), ToBracketsRange); |
1259 | 1.62k | } |
1260 | | |
1261 | 4 | ExpectedType ASTNodeImporter::VisitVectorType(const VectorType *T) { |
1262 | 4 | ExpectedType ToElementTypeOrErr = import(T->getElementType()); |
1263 | 4 | if (!ToElementTypeOrErr) |
1264 | 0 | return ToElementTypeOrErr.takeError(); |
1265 | | |
1266 | 4 | return Importer.getToContext().getVectorType(*ToElementTypeOrErr, |
1267 | 4 | T->getNumElements(), |
1268 | 4 | T->getVectorKind()); |
1269 | 4 | } |
1270 | | |
1271 | 14 | ExpectedType ASTNodeImporter::VisitExtVectorType(const ExtVectorType *T) { |
1272 | 14 | ExpectedType ToElementTypeOrErr = import(T->getElementType()); |
1273 | 14 | if (!ToElementTypeOrErr) |
1274 | 0 | return ToElementTypeOrErr.takeError(); |
1275 | | |
1276 | 14 | return Importer.getToContext().getExtVectorType(*ToElementTypeOrErr, |
1277 | 14 | T->getNumElements()); |
1278 | 14 | } |
1279 | | |
1280 | | ExpectedType |
1281 | 86 | ASTNodeImporter::VisitFunctionNoProtoType(const FunctionNoProtoType *T) { |
1282 | | // FIXME: What happens if we're importing a function without a prototype |
1283 | | // into C++? Should we make it variadic? |
1284 | 86 | ExpectedType ToReturnTypeOrErr = import(T->getReturnType()); |
1285 | 86 | if (!ToReturnTypeOrErr) |
1286 | 0 | return ToReturnTypeOrErr.takeError(); |
1287 | | |
1288 | 86 | return Importer.getToContext().getFunctionNoProtoType(*ToReturnTypeOrErr, |
1289 | 86 | T->getExtInfo()); |
1290 | 86 | } |
1291 | | |
1292 | | ExpectedType |
1293 | 753k | ASTNodeImporter::VisitFunctionProtoType(const FunctionProtoType *T) { |
1294 | 753k | ExpectedType ToReturnTypeOrErr = import(T->getReturnType()); |
1295 | 753k | if (!ToReturnTypeOrErr) |
1296 | 0 | return ToReturnTypeOrErr.takeError(); |
1297 | | |
1298 | | // Import argument types |
1299 | 753k | SmallVector<QualType, 4> ArgTypes; |
1300 | 1.06M | for (const auto &A : T->param_types()) { |
1301 | 1.06M | ExpectedType TyOrErr = import(A); |
1302 | 1.06M | if (!TyOrErr) |
1303 | 13 | return TyOrErr.takeError(); |
1304 | 1.06M | ArgTypes.push_back(*TyOrErr); |
1305 | 1.06M | } |
1306 | | |
1307 | | // Import exception types |
1308 | 753k | SmallVector<QualType, 4> ExceptionTypes; |
1309 | 753k | for (const auto &E : T->exceptions()) { |
1310 | 0 | ExpectedType TyOrErr = import(E); |
1311 | 0 | if (!TyOrErr) |
1312 | 0 | return TyOrErr.takeError(); |
1313 | 0 | ExceptionTypes.push_back(*TyOrErr); |
1314 | 0 | } |
1315 | | |
1316 | 753k | FunctionProtoType::ExtProtoInfo FromEPI = T->getExtProtoInfo(); |
1317 | 753k | Error Err = Error::success(); |
1318 | 753k | FunctionProtoType::ExtProtoInfo ToEPI; |
1319 | 753k | ToEPI.ExtInfo = FromEPI.ExtInfo; |
1320 | 753k | ToEPI.Variadic = FromEPI.Variadic; |
1321 | 753k | ToEPI.HasTrailingReturn = FromEPI.HasTrailingReturn; |
1322 | 753k | ToEPI.TypeQuals = FromEPI.TypeQuals; |
1323 | 753k | ToEPI.RefQualifier = FromEPI.RefQualifier; |
1324 | 753k | ToEPI.ExceptionSpec.Type = FromEPI.ExceptionSpec.Type; |
1325 | 753k | ToEPI.ExceptionSpec.NoexceptExpr = |
1326 | 753k | importChecked(Err, FromEPI.ExceptionSpec.NoexceptExpr); |
1327 | 753k | ToEPI.ExceptionSpec.SourceDecl = |
1328 | 753k | importChecked(Err, FromEPI.ExceptionSpec.SourceDecl); |
1329 | 753k | ToEPI.ExceptionSpec.SourceTemplate = |
1330 | 753k | importChecked(Err, FromEPI.ExceptionSpec.SourceTemplate); |
1331 | 753k | ToEPI.ExceptionSpec.Exceptions = ExceptionTypes; |
1332 | | |
1333 | 753k | if (Err) |
1334 | 0 | return std::move(Err); |
1335 | | |
1336 | 753k | return Importer.getToContext().getFunctionType( |
1337 | 753k | *ToReturnTypeOrErr, ArgTypes, ToEPI); |
1338 | 753k | } |
1339 | | |
1340 | | ExpectedType ASTNodeImporter::VisitUnresolvedUsingType( |
1341 | 268 | const UnresolvedUsingType *T) { |
1342 | 268 | Error Err = Error::success(); |
1343 | 268 | auto ToD = importChecked(Err, T->getDecl()); |
1344 | 268 | auto ToPrevD = importChecked(Err, T->getDecl()->getPreviousDecl()); |
1345 | 268 | if (Err) |
1346 | 0 | return std::move(Err); |
1347 | | |
1348 | 268 | return Importer.getToContext().getTypeDeclType( |
1349 | 268 | ToD, cast_or_null<TypeDecl>(ToPrevD)); |
1350 | 268 | } |
1351 | | |
1352 | 1.64k | ExpectedType ASTNodeImporter::VisitParenType(const ParenType *T) { |
1353 | 1.64k | ExpectedType ToInnerTypeOrErr = import(T->getInnerType()); |
1354 | 1.64k | if (!ToInnerTypeOrErr) |
1355 | 0 | return ToInnerTypeOrErr.takeError(); |
1356 | | |
1357 | 1.64k | return Importer.getToContext().getParenType(*ToInnerTypeOrErr); |
1358 | 1.64k | } |
1359 | | |
1360 | 249k | ExpectedType ASTNodeImporter::VisitTypedefType(const TypedefType *T) { |
1361 | 249k | Expected<TypedefNameDecl *> ToDeclOrErr = import(T->getDecl()); |
1362 | 249k | if (!ToDeclOrErr) |
1363 | 4 | return ToDeclOrErr.takeError(); |
1364 | | |
1365 | 249k | return Importer.getToContext().getTypeDeclType(*ToDeclOrErr); |
1366 | 249k | } |
1367 | | |
1368 | 3 | ExpectedType ASTNodeImporter::VisitTypeOfExprType(const TypeOfExprType *T) { |
1369 | 3 | ExpectedExpr ToExprOrErr = import(T->getUnderlyingExpr()); |
1370 | 3 | if (!ToExprOrErr) |
1371 | 0 | return ToExprOrErr.takeError(); |
1372 | | |
1373 | 3 | return Importer.getToContext().getTypeOfExprType(*ToExprOrErr); |
1374 | 3 | } |
1375 | | |
1376 | 0 | ExpectedType ASTNodeImporter::VisitTypeOfType(const TypeOfType *T) { |
1377 | 0 | ExpectedType ToUnderlyingTypeOrErr = import(T->getUnderlyingType()); |
1378 | 0 | if (!ToUnderlyingTypeOrErr) |
1379 | 0 | return ToUnderlyingTypeOrErr.takeError(); |
1380 | | |
1381 | 0 | return Importer.getToContext().getTypeOfType(*ToUnderlyingTypeOrErr); |
1382 | 0 | } |
1383 | | |
1384 | 1.80k | ExpectedType ASTNodeImporter::VisitUsingType(const UsingType *T) { |
1385 | 1.80k | Expected<UsingShadowDecl *> FoundOrErr = import(T->getFoundDecl()); |
1386 | 1.80k | if (!FoundOrErr) |
1387 | 0 | return FoundOrErr.takeError(); |
1388 | 1.80k | Expected<QualType> UnderlyingOrErr = import(T->getUnderlyingType()); |
1389 | 1.80k | if (!UnderlyingOrErr) |
1390 | 0 | return UnderlyingOrErr.takeError(); |
1391 | | |
1392 | 1.80k | return Importer.getToContext().getUsingType(*FoundOrErr, *UnderlyingOrErr); |
1393 | 1.80k | } |
1394 | | |
1395 | 6.94k | ExpectedType ASTNodeImporter::VisitDecltypeType(const DecltypeType *T) { |
1396 | | // FIXME: Make sure that the "to" context supports C++0x! |
1397 | 6.94k | ExpectedExpr ToExprOrErr = import(T->getUnderlyingExpr()); |
1398 | 6.94k | if (!ToExprOrErr) |
1399 | 0 | return ToExprOrErr.takeError(); |
1400 | | |
1401 | 6.94k | ExpectedType ToUnderlyingTypeOrErr = import(T->getUnderlyingType()); |
1402 | 6.94k | if (!ToUnderlyingTypeOrErr) |
1403 | 0 | return ToUnderlyingTypeOrErr.takeError(); |
1404 | | |
1405 | 6.94k | return Importer.getToContext().getDecltypeType( |
1406 | 6.94k | *ToExprOrErr, *ToUnderlyingTypeOrErr); |
1407 | 6.94k | } |
1408 | | |
1409 | | ExpectedType |
1410 | 189 | ASTNodeImporter::VisitUnaryTransformType(const UnaryTransformType *T) { |
1411 | 189 | ExpectedType ToBaseTypeOrErr = import(T->getBaseType()); |
1412 | 189 | if (!ToBaseTypeOrErr) |
1413 | 0 | return ToBaseTypeOrErr.takeError(); |
1414 | | |
1415 | 189 | ExpectedType ToUnderlyingTypeOrErr = import(T->getUnderlyingType()); |
1416 | 189 | if (!ToUnderlyingTypeOrErr) |
1417 | 0 | return ToUnderlyingTypeOrErr.takeError(); |
1418 | | |
1419 | 189 | return Importer.getToContext().getUnaryTransformType( |
1420 | 189 | *ToBaseTypeOrErr, *ToUnderlyingTypeOrErr, T->getUTTKind()); |
1421 | 189 | } |
1422 | | |
1423 | 986 | ExpectedType ASTNodeImporter::VisitAutoType(const AutoType *T) { |
1424 | | // FIXME: Make sure that the "to" context supports C++11! |
1425 | 986 | ExpectedType ToDeducedTypeOrErr = import(T->getDeducedType()); |
1426 | 986 | if (!ToDeducedTypeOrErr) |
1427 | 0 | return ToDeducedTypeOrErr.takeError(); |
1428 | | |
1429 | 986 | ExpectedDecl ToTypeConstraintConcept = import(T->getTypeConstraintConcept()); |
1430 | 986 | if (!ToTypeConstraintConcept) |
|