| /llvm-project/clang-tools-extra/unittests/clang-change-namespace/ |
| H A D | ChangeNamespaceTests.cpp | 34 std::string runChangeNamespaceOnCode(llvm::StringRef Code) { in runChangeNamespaceOnCode() argument 36 clang::FileID ID = Context.createInMemoryFile(FileName, Code); in runChangeNamespaceOnCode() 46 if (!tooling::runToolOnCodeWithArgs(Factory->create(), Code, {"-std=c++11"}, in runChangeNamespaceOnCode() 53 std::string format(llvm::StringRef Code) { in format() argument 55 format::getLLVMStyle(), Code, {tooling::Range(0, Code.size())}); in format() 56 auto ChangedCode = tooling::applyAllReplacements(Code, Replaces); in format() 73 std::string Code = "namespace na {\n" in TEST_F() local 83 EXPECT_EQ(format(Expected), runChangeNamespaceOnCode(Code)); in TEST_F() 87 std::string Code = "namespace na {\n" in TEST_F() local 98 EXPECT_EQ(format(Expected), runChangeNamespaceOnCode(Code)); in TEST_F() [all …]
|
| /llvm-project/clang/unittests/Tooling/ |
| H A D | HeaderIncludesTest.cpp | 23 std::string insert(llvm::StringRef Code, llvm::StringRef Header, in insert() argument 25 HeaderIncludes Includes(FileName, Code, Style); in insert() 30 return std::string(Code); in insert() 31 auto Result = applyAllReplacements(Code, Replacements(*R)); in insert() 36 std::string remove(llvm::StringRef Code, llvm::StringRef Header) { in remove() argument 37 HeaderIncludes Includes(FileName, Code, Style); in remove() 41 auto Result = applyAllReplacements(Code, Replaces); in remove() 51 std::string Code = "int main() {}"; in TEST_F() local 54 EXPECT_EQ(Expected, insert(Code, "\"a.h\"")); in TEST_F() 58 std::string Code; in TEST_F() local [all …]
|
| H A D | RangeSelectorTest.cpp | 42 template <typename M> TestMatch matchCode(StringRef Code, M Matcher) { in matchCode() argument 43 auto ASTUnit = tooling::buildASTFromCode(Code); in matchCode() 88 StringRef Code = R"cc( in selectFromAssorted() local 108 return Selector(matchCode(Code, Matcher).Result); in selectFromAssorted() 131 StringRef Code = R"cc( in TEST() local 139 TestMatch Match = matchCode(Code, M); in TEST() 150 StringRef Code = R"cc( in TEST() local 159 TestMatch Match = matchCode(Code, M); in TEST() 170 StringRef Code = R"cc( in TEST() local 175 TestMatch Match = matchCode(Code, callExpr().bind(Call)); in TEST() [all …]
|
| H A D | RefactoringCallbacksTest.cpp | 21 void expectRewritten(const std::string &Code, const std::string &Expected, in expectRewritten() argument 28 ASSERT_TRUE(tooling::runToolOnCode(Factory->create(), Code)) in expectRewritten() 29 << "Parsing error in \"" << Code << "\""; in expectRewritten() 31 FileID ID = Context.createInMemoryFile("input.cc", Code); in expectRewritten() 38 std::string Code = "void f() { int i = 1; }"; in TEST() local 41 expectRewritten(Code, Expected, declStmt().bind("id"), Callback); in TEST() 45 std::string Code = "#define A void f() { int i = 1; }\nA"; in TEST() local 48 expectRewritten(Code, Expected, declStmt().bind("id"), Callback); in TEST() 52 std::string Code = "#define A void f() { int i = 1; }"; in TEST() local 55 expectRewritten(Code, Expected, declStmt().bind("id"), Callback); in TEST() [all …]
|
| H A D | SourceCodeTest.cpp | 103 llvm::Annotations Code; member in __anon2a9822400111::AnnotatedCodeVisitor 106 AnnotatedCodeVisitor() : Code("$r[[]]") {} in AnnotatedCodeVisitor() 115 EqualsAnnotatedRange(this->Context, Code.range("r"))) in VisitDeclHelper() 116 << Code.code(); in VisitDeclHelper() 122 Code = llvm::Annotations(AnnotatedCode); 127 Code.code(), Args); 206 EqualsAnnotatedRange(Context, Code.range("r"))); in TEST() 227 EqualsAnnotatedRange(Context, Code.range("r"))); in TEST() 463 std::string Code = R"cpp( in TEST() 466 Visitor.runOver(Code); 460 std::string Code = R"cpp( TEST() local 473 llvm::Annotations Code(R"cpp( TEST_P() local 489 llvm::Annotations Code(R"cpp( TEST() local 506 llvm::Annotations Code(R"cpp( TEST() local 526 llvm::Annotations Code(R"cpp( TEST() local 574 std::string Code = R"cpp( TEST_P() local 588 llvm::Annotations Code(R"cpp( TEST_P() local 603 llvm::Annotations Code(R"cpp( TEST_P() local 620 llvm::StringRef Code = R"cpp( TEST() local 636 llvm::StringRef Code = R"cpp( TEST() local 654 llvm::StringRef Code = "int c = 10;"; TEST() local 667 llvm::StringRef Code = R"cpp( TEST() local 684 llvm::StringRef Code = R"cpp( TEST() local 699 llvm::StringRef Code = R"cpp( TEST() local 715 llvm::StringRef Code = R"cpp( TEST() local 730 llvm::Annotations Code{R"cpp( TEST() local [all...] |
| /llvm-project/clang/unittests/Format/ |
| H A D | CleanupTest.cpp | 25 std::string cleanup(StringRef Code, const std::vector<tooling::Range> &Ranges, in cleanup() argument 27 tooling::Replacements Replaces = format::cleanup(Style, Code, Ranges); in cleanup() 29 auto Result = applyAllReplacements(Code, Replaces); in cleanup() 35 std::string cleanupAroundOffsets(ArrayRef<unsigned> Offsets, StringRef Code, in cleanupAroundOffsets() argument 40 return cleanup(Code, Ranges, Style); in cleanupAroundOffsets() 45 std::string Code = "namespace A {\n" in TEST_F() local 56 EXPECT_EQ(Expected, cleanupAroundOffsets({28, 91, 132}, Code)); in TEST_F() 60 std::string Code = "namespace A {\n" in TEST_F() local 71 std::vector<tooling::Range> Ranges(1, tooling::Range(0, Code.size())); in TEST_F() 72 EXPECT_EQ(Expected, cleanup(Code, Ranges)); in TEST_F() [all …]
|
| H A D | SortIncludesTest.cpp | 23 std::vector<tooling::Range> GetCodeRange(StringRef Code) { in GetCodeRange() argument 24 return std::vector<tooling::Range>(1, tooling::Range(0, Code.size())); in GetCodeRange() 27 std::string sort(StringRef Code, std::vector<tooling::Range> Ranges, in sort() argument 30 auto Replaces = sortIncludes(FmtStyle, Code, Ranges, FileName); in sort() 33 auto Sorted = applyAllReplacements(Code, Replaces); in sort() 41 std::string sort(StringRef Code, StringRef FileName = "input.cpp", in sort() argument 43 return sort(Code, GetCodeRange(Code), FileName, ExpectedNumRanges); in sort() 46 unsigned newCursor(StringRef Code, unsigned Cursor) { in newCursor() argument 47 sortIncludes(FmtStyle, Code, GetCodeRang in newCursor() 160 StringRef Code = "#include <a>\n" TEST_F() local 170 StringRef Code = "#include <string>\n" TEST_F() local 227 StringRef Code = "// clang-format off\r\n" TEST_F() local 797 StringRef Code = "#include <ccc>\n" // Start of line: 0 TEST_F() local 811 StringRef Code = "#include \"b\"\n" // Start of line: 0 TEST_F() local 830 StringRef Code = "#include \"a\"\r\n" // Start of line: 0 TEST_F() local 853 StringRef Code = "#include \"a\"\r\n" // Start of line: 0 TEST_F() local 1013 StringRef Code = "#include <b>\n" // Start of line: 0 TEST_F() local 1050 StringRef Code = "#include <a>\n" TEST_F() local 1078 StringRef Code = "#include \"b.h\"\n" TEST_F() local 1087 StringRef Code = "#include \"b.h\"\r\n" TEST_F() local 1094 StringRef Code = "#include <a>\n" TEST_F() local 1212 StringRef Code = "#include \"d.h\"\r\n" TEST_F() local 1251 StringRef Code = "\xEF\xBB\xBF#include \"d.h\"\r\n" TEST_F() local 1269 StringRef Code = "\xEF\xBB\xBF#include \"d.h\"\r\n" TEST_F() local 1288 StringRef Code = "#include \"c.h\"\r\n" TEST_F() local 1459 StringRef Code{"/* #include \"foo.h\"\n" TEST_F() local [all...] |
| H A D | FormatTestBase.h | 34 virtual std::string messUp(StringRef Code) const { in messUp() argument 35 return test::messUp(Code); in messUp() 38 std::string format(StringRef Code, 43 LLVM_DEBUG(llvm::errs() << Code << "\n\n"); 47 : std::vector<tooling::Range>{1, tooling::Range(0, Code.size())}; 51 reformat(UsedStyle, Code, NonEmptyRanges, "<stdin>", &Status); 55 << Code << "\n\n"; 58 auto Result = applyAllReplacements(Code, Replaces); 84 StringRef Code, 87 testing::ScopedTrace t(File, Line, testing::Message() << Code 157 verifyGoogleFormat(Code) global() argument [all...] |
| H A D | FormatTestSelective.cpp | 22 std::string format(StringRef Code, unsigned Offset, unsigned Length) { in format() argument 24 LLVM_DEBUG(llvm::errs() << Code << "\n\n"); in format() 28 reformat(Style, Code, Ranges, "<stdin>", &Status); in format() 29 EXPECT_TRUE(Status.FormatComplete) << Code << "\n\n"; in format() 30 auto Result = applyAllReplacements(Code, Replaces); in format() 630 std::string Code = "#include <a> // line 1\n" // 23 chars long in TEST_F() 634 EXPECT_EQ(Code, format(Code, 47, 1)); in TEST_F() 639 std::string Code = "void f() {\n" in TEST_F() 642 EXPECT_EQ(Code, forma in TEST_F() 619 std::string Code = "#include <a> // line 1\n" // 23 chars long TEST_F() local 628 std::string Code = "void f() {\n" TEST_F() local 659 const StringRef Code{" class Foo {\n" TEST_F() local [all...] |
| /llvm-project/clang-tools-extra/clangd/unittests/ |
| H A D | FindTargetTests.cpp | 59 // - a piece of code (Code = "...") 60 // - Code should have a single AST node marked as a [[range]] 67 std::string Code; member in clang::clangd::__anon757ba52b0111::TargetDeclTest 70 // Asserts that `Code` has a marked selection of a node `NodeType`, 74 llvm::Annotations A(Code); in assertNodeAndPrintDecls() 83 ADD_FAILURE() << "No node selected!\n" << Code; in assertNodeAndPrintDecls() 102 << Code 106 Code = R"cpp( in TEST_F() 112 Code = R"cpp( in TEST_F() 118 Code in TEST_F() 1282 newTU(llvm::StringRef Code) newTU() argument 1294 annotatedReferences(llvm::StringRef Code,ParsedAST & AST,std::vector<ReferenceLoc> Refs) annotatedReferences() argument 1336 annotateAllReferences(llvm::StringRef Code) annotateAllReferences() argument 1351 annotateReferencesInFoo(llvm::StringRef Code) annotateReferencesInFoo() argument [all...] |
| H A D | InsertionPointTests.cpp | 26 Annotations Code(R"cpp( in TEST() local 46 auto AST = TestTU::withCode(Code.code()).build(); in TEST() 54 EXPECT_EQ(Point("a", Anchor::Above), Code.point("a")); in TEST() 55 EXPECT_EQ(Point("a", Anchor::Below), Code.point("b")); in TEST() 56 EXPECT_EQ(Point("b", Anchor::Above), Code.point("b")); in TEST() 57 EXPECT_EQ(Point("b", Anchor::Below), Code.point("c")); in TEST() 58 EXPECT_EQ(Point("c", Anchor::Above), Code.point("c")); in TEST() 59 EXPECT_EQ(Point("c", Anchor::Below), Code.point("a2")); in TEST() 60 EXPECT_EQ(Point("", Anchor::Above), Code.point("a")); in TEST() 61 EXPECT_EQ(Point("", Anchor::Below), Code.point("end")); in TEST() [all …]
|
| /llvm-project/llvm/test/tools/llvm-debuginfo-analyzer/DWARF/ |
| H A D | pr-incorrect-logical-instructions.test | 45 ; ONE-NEXT: [003] {Code} 'pushq %rbp' 46 ; ONE-NEXT: [003] {Code} 'movq %rsp, %rbp' 47 ; ONE-NEXT: [003] {Code} 'movl %edi, -0x4(%rbp)' 49 ; ONE-NEXT: [003] {Code} 'movl -0x4(%rbp), %eax' 51 ; ONE-NEXT: [003] {Code} 'imull $0xf423f, -0x4(%rbp), %ecx' 53 ; ONE-NEXT: [003] {Code} 'addl %ecx, %eax' 55 ; ONE-NEXT: [003] {Code} 'subl $0x42, %eax' 57 ; ONE-NEXT: [003] {Code} 'popq %rbp' 58 ; ONE-NEXT: [003] {Code} 'retq' 61 ; ONE-NEXT: [003] {Code} 'pushq %rbp' [all …]
|
| H A D | 02-dwarf-logical-lines.test | 31 ; ONE-NEXT: [003] {Code} 'pushq %rbp' 32 ; ONE-NEXT: [003] {Code} 'movq %rsp, %rbp' 33 ; ONE-NEXT: [003] {Code} 'subq $0x10, %rsp' 34 ; ONE-NEXT: [003] {Code} 'movl $0x0, -0x4(%rbp)' 36 ; ONE-NEXT: [003] {Code} 'leaq (%rip), %rdi' 37 ; ONE-NEXT: [003] {Code} 'movb $0x0, %al' 38 ; ONE-NEXT: [003] {Code} 'callq 0x0' 40 ; ONE-NEXT: [003] {Code} 'xorl %eax, %eax' 41 ; ONE-NEXT: [003] {Code} 'addq $0x10, %rsp' 42 ; ONE-NEXT: [003] {Code} 'popq %rbp' [all …]
|
| /llvm-project/llvm/test/tools/llvm-debuginfo-analyzer/WebAssembly/ |
| H A D | 01-wasm-print-basic-details.test | 47 ; ONE-NEXT: [004] {Code} 'i32.const 7' 48 ; ONE-NEXT: [004] {Code} 'local.set 10' 49 ; ONE-NEXT: [004] {Code} 'local.get 5' 50 ; ONE-NEXT: [004] {Code} 'local.get 10' 51 ; ONE-NEXT: [004] {Code} 'i32.store 12' 53 ; ONE-NEXT: [004] {Code} 'i32.const 7' 54 ; ONE-NEXT: [004] {Code} 'local.set 11' 55 ; ONE-NEXT: [004] {Code} 'local.get 5' 56 ; ONE-NEXT: [004] {Code} 'local.get 11' 57 ; ONE-NEXT: [004] {Code} 'i32.store 28' [all …]
|
| H A D | 02-wasm-logical-lines.test | 33 ; ONE-NEXT: [003] {Code} 'nop' 34 ; ONE-NEXT: [003] {Code} 'rethrow 127' 35 ; ONE-NEXT: [003] {Code} 'global.get 0' 36 ; ONE-NEXT: [003] {Code} 'local.set 0' 37 ; ONE-NEXT: [003] {Code} 'i32.const 16' 38 ; ONE-NEXT: [003] {Code} 'local.set 1' 39 ; ONE-NEXT: [003] {Code} 'local.get 0' 40 ; ONE-NEXT: [003] {Code} 'local.get 1' 41 ; ONE-NEXT: [003] {Code} 'i32.sub' 42 ; ONE-NEXT: [003] {Code} 'local.set 2' [all …]
|
| H A D | 06-wasm-full-logical-view.test | 54 ; ONE-NEXT: [0x000000004c][004] {Code} 'i32.const 7' 55 ; ONE-NEXT: [0x000000004e][004] {Code} 'local.set 10' 56 ; ONE-NEXT: [0x0000000050][004] {Code} 'local.get 5' 57 ; ONE-NEXT: [0x0000000052][004] {Code} 'local.get 10' 58 ; ONE-NEXT: [0x0000000054][004] {Code} 'i32.store 12' 60 ; ONE-NEXT: [0x0000000057][004] {Code} 'i32.const 7' 61 ; ONE-NEXT: [0x0000000059][004] {Code} 'local.set 11' 62 ; ONE-NEXT: [0x000000005b][004] {Code} 'local.get 5' 63 ; ONE-NEXT: [0x000000005d][004] {Code} 'local.get 11' 64 ; ONE-NEXT: [0x000000005f][004] {Code} 'i32.store 28' [all …]
|
| /llvm-project/clang/unittests/Sema/ |
| H A D | CodeCompleteTest.cpp | 142 ParsedSourceLocation offsetToPosition(llvm::StringRef Code, size_t Offset) { in offsetToPosition() argument 143 Offset = std::min(Code.size(), Offset); in offsetToPosition() 144 StringRef Before = Code.substr(0, Offset); in offsetToPosition() 152 CompletionContext runCompletion(StringRef Code, size_t Offset) { in runCompletion() argument 155 std::make_unique<CodeCompleteAction>(offsetToPosition(Code, Offset), in runCompletion() 157 Code, {"-std=c++11"}, TestCCName); in runCompletion() 183 CollectCompletedFunctions(StringRef Code, std::size_t Point) { in CollectCompletedFunctions() argument 186 std::make_unique<CodeCompleteAction>(offsetToPosition(Code, Point), in CollectCompletedFunctions() 188 Code, {"-std=c++11"}, TestCCName); in CollectCompletedFunctions() 193 llvm::Annotations Code(R"cpp( in TEST() local [all …]
|
| /llvm-project/clang/unittests/ASTMatchers/Dynamic/ |
| H A D | ParserTest.cpp | 46 void parse(StringRef Code) { in parse() argument 49 Parser::parseExpression(Code, this, &Value, &Error); in parse() 221 StringRef Code = in TEST() local 225 Parser::parseMatcherExpression(Code, &Error)); in TEST() 233 Code = "implicitCastExpr(hasCastKind(\"CK_IntegralToBoolean\"))"; in TEST() 235 Parser::parseMatcherExpression(Code, nullptr, nullptr, &Error)); in TEST() 242 Code = "functionDecl(hasParameter(1, hasName(\"x\")))"; in TEST() 244 Parser::parseMatcherExpression(Code, &Error)); in TEST() 254 Code = "functionDecl(hasParamA, hasParameter(1, hasName(nameX)))"; in TEST() 256 Parser::parseMatcherExpression(Code, nullptr, &NamedValues, &Error)); in TEST() [all …]
|
| /llvm-project/offload/src/OpenMP/OMPT/ |
| H A D | Callback.cpp | 31 #define defineOmptCallback(Name, Type, Code) \ 78 void *Code) { in createRegionId() 87 /*TgtDeviceNum=*/DeviceId, Size, Code); in beginTargetDataAlloc() 95 /*TgtDeviceNum=*/DeviceId, Size, Code); in beginTargetDataAlloc() 101 void *Code) { in beginTargetDataAlloc() 110 /*TgtDeviceNum=*/DeviceId, Size, Code); in endTargetDataAlloc() 117 size_t Size, void *Code) { in endTargetDataAlloc() 125 DstPtrBegin, DstDeviceId, Size, Code); in beginTargetDataSubmit() 132 SrcPtrBegin, SrcDeviceId, DstPtrBegin, DstDeviceId, Size, Code); in beginTargetDataSubmit() 138 size_t Size, void *Code) { in beginTargetDataSubmit() 40 defineOmptCallback(Name,Type,Code) global() argument 85 beginTargetDataAlloc(int64_t DeviceId,void * HstPtrBegin,void ** TgtPtrBegin,size_t Size,void * Code) beginTargetDataAlloc() argument 108 endTargetDataAlloc(int64_t DeviceId,void * HstPtrBegin,void ** TgtPtrBegin,size_t Size,void * Code) endTargetDataAlloc() argument 124 beginTargetDataSubmit(int64_t SrcDeviceId,void * SrcPtrBegin,int64_t DstDeviceId,void * DstPtrBegin,size_t Size,void * Code) beginTargetDataSubmit() argument 145 endTargetDataSubmit(int64_t SrcDeviceId,void * SrcPtrBegin,int64_t DstDeviceId,void * DstPtrBegin,size_t Size,void * Code) endTargetDataSubmit() argument 159 beginTargetDataDelete(int64_t DeviceId,void * TgtPtrBegin,void * Code) beginTargetDataDelete() argument 180 endTargetDataDelete(int64_t DeviceId,void * TgtPtrBegin,void * Code) endTargetDataDelete() argument 195 beginTargetDataRetrieve(int64_t SrcDeviceId,void * SrcPtrBegin,int64_t DstDeviceId,void * DstPtrBegin,size_t Size,void * Code) beginTargetDataRetrieve() argument 216 endTargetDataRetrieve(int64_t SrcDeviceId,void * SrcPtrBegin,int64_t DstDeviceId,void * DstPtrBegin,size_t Size,void * Code) endTargetDataRetrieve() argument 252 beginTargetDataEnter(int64_t DeviceId,void * Code) beginTargetDataEnter() argument 266 endTargetDataEnter(int64_t DeviceId,void * Code) endTargetDataEnter() argument 280 beginTargetDataExit(int64_t DeviceId,void * Code) beginTargetDataExit() argument 295 endTargetDataExit(int64_t DeviceId,void * Code) endTargetDataExit() argument 308 beginTargetUpdate(int64_t DeviceId,void * Code) beginTargetUpdate() argument 322 endTargetUpdate(int64_t DeviceId,void * Code) endTargetUpdate() argument 335 beginTarget(int64_t DeviceId,void * Code) beginTarget() argument 349 endTarget(int64_t DeviceId,void * Code) endTarget() argument 468 bindOmptCallback(Name,Type,Code) connectLibrary() argument [all...] |
| /llvm-project/clang/unittests/ASTMatchers/ |
| H A D | ASTMatchersTest.h | 91 const Twine &Code, const T &AMatcher, bool ExpectMatch, 128 Factory->create(), Code, Args, Filename, "clang-tool", 130 return testing::AssertionFailure() << "Parsing error in \"" << Code << "\""; 139 << "Could not find match in \"" << Code << "\""; 142 << "Found unexpected match in \"" << Code << "\""; 149 matchesConditionally(const Twine &Code, const T &AMatcher, bool ExpectMatch, 153 Code, AMatcher, ExpectMatch, getCommandLineArgsForTesting(Lang), in matchesConditionally() 164 matches(const Twine &Code, const T &AMatcher, 166 return matchesConditionally(Code, AMatcher, true, TestLanguages); 171 notMatches(const Twine &Code, cons 150 matchesConditionally(const Twine & Code,const T & AMatcher,bool ExpectMatch,ArrayRef<TestLanguage> TestLanguages) matchesConditionally() argument 187 matchesC(const Twine & Code,const T & AMatcher) matchesC() argument 193 notMatchesObjC(const Twine & Code,const T & AMatcher) notMatchesObjC() argument 201 matchesConditionallyWithCuda(const Twine & Code,const T & AMatcher,bool ExpectMatch,llvm::StringRef CompileArg) matchesConditionallyWithCuda() argument 257 matchesWithCuda(const Twine & Code,const T & AMatcher) matchesWithCuda() argument 262 notMatchesWithCuda(const Twine & Code,const T & AMatcher) notMatchesWithCuda() argument 268 matchesWithOpenMP(const Twine & Code,const T & AMatcher) matchesWithOpenMP() argument 274 notMatchesWithOpenMP(const Twine & Code,const T & AMatcher) notMatchesWithOpenMP() argument 280 matchesWithOpenMP51(const Twine & Code,const T & AMatcher) matchesWithOpenMP51() argument 287 notMatchesWithOpenMP51(const Twine & Code,const T & AMatcher) notMatchesWithOpenMP51() argument 445 matches(const Twine & Code,const T & AMatcher) matches() argument 453 notMatches(const Twine & Code,const T & AMatcher) notMatches() argument [all...] |
| H A D | ASTMatchersTraversalTest.cpp | 574 StringRef Code = R"cpp( in TEST() 589 Code, cxxConstructorDecl( in TEST() 594 Code, cxxConstructorDecl( in TEST() 599 Code, cxxDestructorDecl( in TEST() 603 Code, cxxConversionDecl(hasBody(compoundStmt(has(returnStmt( in TEST() 1539 static const char Code[] = in TEST() 1548 EXPECT_TRUE(matches(Code, cxxConstructorDecl(hasAnyConstructorInitializer( in TEST() 1550 EXPECT_TRUE(matches(Code, cxxConstructorDecl(hasAnyConstructorInitializer( in TEST() 1552 EXPECT_TRUE(matches(Code, cxxConstructorDecl(hasAnyConstructorInitializer( in TEST() 1554 EXPECT_TRUE(notMatches(Code, cxxConstructorDec in TEST() 568 StringRef Code = R"cpp( TEST() local 1531 static const char Code[] = TEST() local 1551 static const char Code[] = TEST() local 1563 static const char Code[] = TEST() local 1579 static const char Code[] = TEST() local 1648 StringRef Code = R"cpp( TEST() local 1875 StringRef Code = R"cpp( TEST() local 2515 StringRef Code = R"( TEST() local 2619 StringRef Code = R"cpp( TEST() local 3169 StringRef Code = R"cpp( TEST() local 3734 matcherTemplateWithBinding(StringRef Code,const MatcherT & M) matcherTemplateWithBinding() argument 3744 llvm::StringRef Code = R"cpp( TEST() local 3757 StringRef Code = R"cpp( TEST() local 3782 StringRef Code = R"cpp( TEST() local 3801 StringRef Code = R"cpp( TEST() local 3826 StringRef Code = R"cpp( TEST() local 4682 StringRef Code = R"cpp( TEST() local 5139 StringRef Code = R"cpp( TEST() local 5221 const std::string Code = R"( TEST() local 5249 const std::string Code = R"( TEST() local [all...] |
| /llvm-project/clang/include/clang/AST/ |
| H A D | StmtDataCollectors.td | 2 code Code = [{ 12 code Code = [{ 19 code Code = [{ 24 code Code = [{ 29 code Code = [{ 34 code Code = [{ 43 code Code = [{ 68 code Code = [{ 73 code Code = [{ 80 code Code [all...] |
| /llvm-project/clang/unittests/AST/ |
| H A D | NamedDeclPrinterTest.cpp | 66 StringRef Code, const std::vector<std::string> &Args, in PrintedDeclMatches() argument 71 Code, Args, NodeMatch, ExpectedPrinted, FileName, in PrintedDeclMatches() 78 PrintedNamedDeclMatches(StringRef Code, const std::vector<std::string> &Args, in PrintedNamedDeclMatches() argument 82 return PrintedDeclMatches(Code, Args, NodeMatch, ExpectedPrinted, FileName, in PrintedNamedDeclMatches() 93 PrintedNamedDeclCXX98Matches(StringRef Code, StringRef DeclName, in PrintedNamedDeclCXX98Matches() argument 96 return PrintedNamedDeclMatches(Code, Args, in PrintedNamedDeclCXX98Matches() 103 PrintedWrittenNamedDeclCXX11Matches(StringRef Code, StringRef DeclName, in PrintedWrittenNamedDeclCXX11Matches() argument 106 return PrintedNamedDeclMatches(Code, Args, in PrintedWrittenNamedDeclCXX11Matches() 113 PrintedWrittenPropertyDeclObjCMatches(StringRef Code, StringRef DeclName, in PrintedWrittenPropertyDeclObjCMatches() argument 116 return PrintedNamedDeclMatches(Code, Args, in PrintedWrittenPropertyDeclObjCMatches() [all …]
|
| /llvm-project/clang/unittests/Analysis/FlowSensitive/ |
| H A D | TransferTest.cpp | 85 llvm::StringRef Code, in runDataflow() 93 ASSERT_THAT_ERROR(checkDataflowWithNoopAnalysis(Code, VerifyResults, Options, in runDataflow() 99 llvm::StringRef Code, in runDataflow() 106 runDataflow(Code, std::move(VerifyResults), in runDataflow() 113 llvm::StringRef Code, in runDataflowOnLambda() 122 Code, in runDataflowOnLambda() 130 llvm::StringRef Code, in runDataflowOnLambda() 137 runDataflowOnLambda(Code, std::move(VerifyResults), in runDataflowOnLambda() 187 std::string Code = R"( in TEST() 194 Code, in TEST() 84 runDataflow(llvm::StringRef Code,std::function<void (const llvm::StringMap<DataflowAnalysisState<NoopLattice>> &,ASTContext &)> VerifyResults,DataflowAnalysisOptions Options,LangStandard::Kind Std=LangStandard::lang_cxx17,llvm::StringRef TargetFun="target") runDataflow() argument 98 runDataflow(llvm::StringRef Code,std::function<void (const llvm::StringMap<DataflowAnalysisState<NoopLattice>> &,ASTContext &)> VerifyResults,LangStandard::Kind Std=LangStandard::lang_cxx17,bool ApplyBuiltinTransfer=true,llvm::StringRef TargetFun="target") runDataflow() argument 112 runDataflowOnLambda(llvm::StringRef Code,std::function<void (const llvm::StringMap<DataflowAnalysisState<NoopLattice>> &,ASTContext &)> VerifyResults,DataflowAnalysisOptions Options,LangStandard::Kind Std=LangStandard::lang_cxx17) runDataflowOnLambda() argument 129 runDataflowOnLambda(llvm::StringRef Code,std::function<void (const llvm::StringMap<DataflowAnalysisState<NoopLattice>> &,ASTContext &)> VerifyResults,LangStandard::Kind Std=LangStandard::lang_cxx17,bool ApplyBuiltinTransfer=true) runDataflowOnLambda() argument 177 std::string Code = R"( TEST() local 200 std::string Code = R"( TEST() local 225 std::string Code = R"( TEST() local 250 std::string Code = R"( TEST() local 279 std::string Code = R"( TEST() local 331 std::string Code = R"( TEST() local 372 std::string Code = R"( TEST() local 415 std::string Code = R"( TEST() local 437 std::string Code = R"( TEST() local 479 std::string Code = R"( TEST() local 505 std::string Code = R"( TEST() local 610 std::string Code = R"( TEST() local 640 std::string Code = R"( TEST() local 754 std::string Code = R"( TEST() local 776 std::string Code = R"( TEST() local 811 std::string Code = R"( TEST() local 865 std::string Code = R"( TEST() local 894 std::string Code = R"( TEST() local 919 std::string Code = R"( TEST() local 947 std::string Code = R"( TEST() local 980 std::string Code = R"( TEST() local 1016 std::string Code = R"( TEST() local 1067 std::string Code = R"( TEST() local 1101 std::string Code = R"( TEST() local 1141 std::string Code = R"( TEST() local 1165 std::string Code = R"( TEST() local 1193 std::string Code = R"( TEST() local 1239 std::string Code = R"( TEST() local 1261 std::string Code = R"( TEST() local 1394 std::string Code = R"( TEST() local 1413 std::string Code = R"( TEST() local 1432 std::string Code = R"( TEST() local 1483 std::string Code = R"( TEST() local 1524 std::string Code = R"( TEST() local 1549 std::string Code = R"( TEST() local 1583 std::string Code = R"( TEST() local 1641 std::string Code = R"( TEST() local 1689 std::string Code = R"( TEST() local 1734 std::string Code = R"( TEST() local 1780 std::string Code = R"( TEST() local 1850 std::string Code = R"( TEST() local 1920 std::string Code = R"( TEST() local 2065 std::string Code = R"( TEST() local 2097 std::string Code = R"( TEST() local 2130 std::string Code = R"( TEST() local 2165 std::string Code = R"( TEST() local 2198 std::string Code = R"( TEST() local 2230 std::string Code = R"( TEST() local 2317 std::string Code = R"( TEST() local 2351 std::string Code = R"( TEST() local 2392 std::string Code = R"( TEST() local 2413 std::string Code = R"( TEST() local 2433 std::string Code = R"( TEST() local 2451 std::string Code = R"( TEST() local 2499 std::string Code = R"( TEST() local 2518 std::string Code = R"( TEST() local 2537 std::string Code = R"( TEST() local 2555 std::string Code = R"cc( TEST() local 2570 std::string Code = R"cc( TEST() local 2601 std::string Code = R"cc( TEST() local 2635 std::string Code = R"cc( TEST() local 2668 std::string Code = R"( TEST() local 2737 std::string Code = R"( TEST() local 2782 std::string Code = R"( TEST() local 2825 std::string Code = R"( TEST() local 2859 std::string Code = R"( TEST() local 2873 std::string Code = R"( TEST() local 2942 std::string Code = R"( TEST() local 2978 std::string Code = R"( TEST() local 3037 std::string Code = R"( TEST() local 3071 std::string Code = R"( TEST() local 3110 std::string Code = R"( TEST() local 3140 std::string Code = R"cc( TEST() local 3176 std::string Code = R"cc( TEST() local 3215 std::string Code = R"( TEST() local 3265 std::string Code = R"( TEST() local 3297 std::string Code = R"( TEST() local 3323 std::string Code = R"( TEST() local 3349 std::string Code = R"( TEST() local 3375 std::string Code = R"( TEST() local 3420 std::string Code = R"( TEST() local 3442 __anon7f451ee25602(llvm::StringRef Code, llvm::StringRef TargetFun) TEST() argument 3451 std::string Code = R"cc( TEST() local 3492 std::string Code = R"( TEST() local 3520 std::string Code = R"( TEST() local 3539 std::string Code = R"( TEST() local 3559 std::string Code = R"( TEST() local 3587 std::string Code = R"cc( TEST() local 3603 std::string Code = R"( TEST() local 3668 std::string Code = R"( TEST() local 3691 std::string Code = R"( TEST() local 3714 std::string Code = R"( TEST() local 3736 std::string Code = R"( TEST() local 3764 std::string Code = R"( TEST() local 3790 std::string Code = R"( TEST() local 3816 std::string Code = R"( TEST() local 3843 std::string Code = R"( TEST() local 3861 std::string Code = R"( TEST() local 3871 std::string Code = R"( TEST() local 3883 std::string Code = R"( TEST() local 3917 std::string Code = R"( TEST() local 3955 std::string Code = R"( TEST() local 4064 std::string Code = R"( TEST() local 4090 std::string Code = R"( TEST() local 4127 std::string Code = R"( TEST() local 4143 std::string Code = R"( TEST() local 4193 std::string Code = R"( TEST() local 4228 std::string Code = R"( TEST() local 4276 std::string Code = R"( TEST() local 4324 std::string Code = R"( TEST() local 4378 std::string Code = R"( TEST() local 4411 std::string Code = R"( TEST() local 4438 std::string Code = R"( TEST() local 4462 std::string Code = R"( TEST() local 4494 std::string Code = R"( TEST() local 4525 std::string Code = R"( TEST() local 4555 std::string Code = R"( TEST() local 4580 std::string Code = R"( TEST() local 4617 std::string Code = R"( TEST() local 4646 std::string Code = R"( TEST() local 4677 std::string Code = R"( TEST() local 4708 std::string Code = R"( TEST() local 4750 std::string Code = R"( TEST() local 4784 std::string Code = R"( TEST() local 4818 std::string Code = R"cc( TEST() local 4878 std::string Code = R"cc( TEST() local 4906 std::string Code = R"( TEST() local 4925 std::string Code = R"( TEST() local 4975 std::string Code = R"( TEST() local 5006 std::string Code = R"( TEST() local 5043 std::string Code = R"( TEST() local 5073 std::string Code = R"( TEST() local 5126 std::string Code = R"cc( TEST() local 5144 std::string Code = R"cc( TEST() local 5166 std::string Code = R"cc( TEST() local 5184 std::string Code = R"cc( TEST() local 5208 std::string Code = R"cc( TEST() local 5230 std::string Code = (CoroutineLibrary + R"cc( TEST() local 5246 std::string Code = R"( TEST() local 5306 std::string Code = R"( TEST() local 5365 std::string Code = R"( TEST() local 5425 std::string Code = R"( TEST() local 5506 std::string Code = R"( TEST() local 5588 std::string Code = R"( TEST() local 5616 std::string Code = R"( TEST() local 5650 std::string Code = R"( TEST() local 5679 std::string Code = R"cc( TEST() local 5709 std::string Code = R"( TEST() local 5742 std::string Code = R"( TEST() local 5776 std::string Code = R"( TEST() local 5819 std::string Code = R"( TEST() local 5853 std::string Code = R"( TEST() local 5878 std::string Code = R"( TEST() local 5906 std::string Code = R"( TEST() local 5932 std::string Code = R"( TEST() local 5961 std::string Code = R"( TEST() local 6012 std::string Code = R"( TEST() local 6040 std::string Code = R"( TEST() local 6067 std::string Code = R"( TEST() local 6094 std::string Code = R"( TEST() local 6132 std::string Code = R"( TEST() local 6161 std::string Code = R"( TEST() local 6189 std::string Code = R"( TEST() local 6219 std::string Code = R"( TEST() local 6248 std::string Code = R"( TEST() local 6292 std::string Code = R"( TEST() local 6330 std::string Code = R"( TEST() local 6372 std::string Code = R"( TEST() local 6391 std::string Code = R"( TEST() local 6416 std::string Code = R"( TEST() local 6441 std::string Code = R"( TEST() local 6469 std::string Code = R"( TEST() local 6488 std::string Code = R"( TEST() local 6521 std::string Code = R"( TEST() local 6553 std::string Code = R"( TEST() local 6582 std::string Code = R"( TEST() local 6614 std::string Code = R"( TEST() local 6646 std::string Code = R"( TEST() local 6681 std::string Code = R"( TEST() local 6715 std::string Code = R"( TEST() local 6749 std::string Code = R"( TEST() local 6780 std::string Code = R"( TEST() local 6811 std::string Code = R"( TEST() local 6844 std::string Code = R"( TEST() local 6877 std::string Code = R"( TEST() local 6903 std::string Code = R"( TEST() local 6923 std::string Code = R"( TEST() local 6989 std::string Code = R"( TEST() local 7009 std::string Code = R"( TEST() local 7048 std::string Code = R"( TEST() local 7089 std::string Code = R"( TEST() local 7127 std::string Code = R"( TEST() local 7174 std::string Code = R"( TEST() local 7206 std::string Code = R"( TEST() local 7237 std::string Code = R"( TEST() local 7275 std::string Code = R"( TEST() local 7290 std::string Code = R"( TEST() local 7323 std::string Code = R"( TEST() local 7356 std::string Code = R"( TEST() local 7389 std::string Code = R"( TEST() local 7424 std::string Code = R"( TEST() local 7459 std::string Code = R"( TEST() local 7496 std::string Code = R"( TEST() local 7532 std::string Code = R"cc( TEST() local [all...] |
| /llvm-project/clang/lib/ASTMatchers/Dynamic/ |
| H A D | Parser.cpp | 72 : Code(MatcherCode), StartOfLine(MatcherCode), Error(Error) { in CodeTokenizer() 78 : Code(MatcherCode), StartOfLine(MatcherCode), Error(Error), in CodeTokenizer() 114 if (CodeCompletionLocation && CodeCompletionLocation <= Code.data()) { in getNextToken() 121 if (Code.empty()) { in getNextToken() 127 switch (Code[0]) { in getNextToken() 129 Code = Code.drop_until([](char c) { return c == '\n'; }); in getNextToken() 133 Result.Text = Code.substr(0, 1); in getNextToken() 134 Code = Code.drop_front(); in getNextToken() 138 Result.Text = Code.substr(0, 1); in getNextToken() 139 Code = Code.drop_front(); in getNextToken() [all …]
|