Lines Matching refs:Code
22 std::string format(StringRef Code, unsigned Offset, unsigned Length) {
24 LLVM_DEBUG(llvm::errs() << Code << "\n\n");
28 reformat(Style, Code, Ranges, "<stdin>", &Status);
29 EXPECT_TRUE(Status.FormatComplete) << Code << "\n\n";
30 auto Result = applyAllReplacements(Code, Replaces);
630 std::string Code = "#include <a> // line 1\n" // 23 chars long
634 EXPECT_EQ(Code, format(Code, 47, 1));
639 std::string Code = "void f() {\n"
642 EXPECT_EQ(Code, format(Code, 40, 0));
647 Code = "\n"
650 EXPECT_EQ(Code, format(Code, 0, 0));
655 Code = "namespace ns {\n"
658 EXPECT_EQ(Code, format(Code, 51, 0));
670 const StringRef Code{" class Foo {\n"
685 format(Code, 57, 0));
695 format(Code, 57, 0));
705 format(Code, 57, 0));