Lines Matching refs:Out
29 raw_ostream &Out; member in __anon99da89d80111::DeclPrinter
50 DeclPrinter(raw_ostream &Out, const PrintingPolicy &Policy, in DeclPrinter() argument
52 : Out(Out), Policy(Policy), Indentation(Indentation), in DeclPrinter()
106 void Decl::print(raw_ostream &Out, unsigned Indentation, in print() argument
108 print(Out, getASTContext().getPrintingPolicy(), Indentation, PrintInstantiation); in print()
111 void Decl::print(raw_ostream &Out, const PrintingPolicy &Policy, in print() argument
113 DeclPrinter Printer(Out, Policy, Indentation, PrintInstantiation); in print()
152 raw_ostream &Out, const PrintingPolicy &Policy, in printGroup() argument
155 (*Begin)->print(Out, Policy, Indentation); in printGroup()
174 if (!isFirst) Out << ", "; in printGroup()
179 (*Begin)->print(Out, SubPolicy, Indentation); in printGroup()
196 Out << " "; in Indent()
197 return Out; in Indent()
213 A->printPretty(Out, Policy); in prettyPrintAttributes()
231 A->printPretty(Out, Policy); in prettyPrintPragmas()
249 T.print(Out, Policy, (Pack ? "..." : "") + DeclName, Indentation); in printDeclType()
254 Decl::printGroup(Decls.data(), Decls.size(), Out, Policy, Indentation); in ProcessDeclGroup()
255 Out << ";\n"; in ProcessDeclGroup()
263 case AS_public: Out << "public"; break; in Print()
264 case AS_protected: Out << "protected"; break; in Print()
265 case AS_private: Out << "private"; break; in Print()
328 Out << ":\n"; in VisitDeclContext()
361 Out << Terminator; in VisitDeclContext()
362 Out << "\n"; in VisitDeclContext()
367 Out << "#pragma omp end declare target\n"; in VisitDeclContext()
383 Out << "typedef "; in VisitTypedefDecl()
386 Out << "__module_private__ "; in VisitTypedefDecl()
389 Ty.print(Out, Policy, D->getName(), Indentation); in VisitTypedefDecl()
394 Out << "using " << *D; in VisitTypeAliasDecl()
396 Out << " = " << D->getTypeSourceInfo()->getType().getAsString(Policy); in VisitTypeAliasDecl()
401 Out << "__module_private__ "; in VisitEnumDecl()
402 Out << "enum "; in VisitEnumDecl()
405 Out << "class "; in VisitEnumDecl()
407 Out << "struct "; in VisitEnumDecl()
409 Out << *D; in VisitEnumDecl()
412 Out << " : " << D->getIntegerType().stream(Policy); in VisitEnumDecl()
415 Out << " {\n"; in VisitEnumDecl()
424 Out << "__module_private__ "; in VisitRecordDecl()
425 Out << D->getKindName(); in VisitRecordDecl()
430 Out << ' ' << *D; in VisitRecordDecl()
433 Out << " {\n"; in VisitRecordDecl()
440 Out << *D; in VisitEnumConstantDecl()
442 Out << " = "; in VisitEnumConstantDecl()
443 Init->printPretty(Out, nullptr, Policy, Indentation); in VisitEnumConstantDecl()
457 case SC_Extern: Out << "extern "; break; in VisitFunctionDecl()
458 case SC_Static: Out << "static "; break; in VisitFunctionDecl()
459 case SC_PrivateExtern: Out << "__private_extern__ "; break; in VisitFunctionDecl()
464 if (D->isInlineSpecified()) Out << "inline "; in VisitFunctionDecl()
465 if (D->isVirtualAsWritten()) Out << "virtual "; in VisitFunctionDecl()
466 if (D->isModulePrivate()) Out << "__module_private__ "; in VisitFunctionDecl()
467 if (D->isConstexpr() && !D->isExplicitlyDefaulted()) Out << "constexpr "; in VisitFunctionDecl()
470 Out << "explicit "; in VisitFunctionDecl()
564 Out << Proto; in VisitFunctionDecl()
568 Out << ", "; in VisitFunctionDecl()
572 Out << *FD; in VisitFunctionDecl()
574 Out << QualType(BMInitializer->getBaseClass(), 0).getAsString(Policy); in VisitFunctionDecl()
577 Out << "("; in VisitFunctionDecl()
601 SimpleInit->printPretty(Out, nullptr, Policy, Indentation); in VisitFunctionDecl()
609 Out << ", "; in VisitFunctionDecl()
610 Args[I]->printPretty(Out, nullptr, Policy, Indentation); in VisitFunctionDecl()
614 Out << ")"; in VisitFunctionDecl()
616 Out << "..."; in VisitFunctionDecl()
620 Out << "auto " << Proto << " -> "; in VisitFunctionDecl()
623 AFT->getReturnType().print(Out, Policy, Proto); in VisitFunctionDecl()
626 Out << Proto; in VisitFunctionDecl()
628 Ty.print(Out, Policy, Proto); in VisitFunctionDecl()
634 Out << " = 0"; in VisitFunctionDecl()
636 Out << " = delete"; in VisitFunctionDecl()
638 Out << " = default"; in VisitFunctionDecl()
643 Out << '\n'; in VisitFunctionDecl()
644 DeclPrinter ParamPrinter(Out, SubPolicy, Indentation); in VisitFunctionDecl()
649 Out << ";\n"; in VisitFunctionDecl()
653 Out << ' '; in VisitFunctionDecl()
656 D->getBody()->printPretty(Out, nullptr, SubPolicy, Indentation); in VisitFunctionDecl()
657 Out << '\n'; in VisitFunctionDecl()
666 Out << "friend "; in VisitFriendDecl()
667 Out << " " << TSI->getType().getAsString(Policy); in VisitFriendDecl()
671 Out << "friend "; in VisitFriendDecl()
676 Out << "friend "; in VisitFriendDecl()
681 Out << "friend "; in VisitFriendDecl()
689 Out << "mutable "; in VisitFieldDecl()
691 Out << "__module_private__ "; in VisitFieldDecl()
693 Out << D->getASTContext().getUnqualifiedObjCPointerType(D->getType()). in VisitFieldDecl()
697 Out << " : "; in VisitFieldDecl()
698 D->getBitWidth()->printPretty(Out, nullptr, Policy, Indentation); in VisitFieldDecl()
704 Out << " "; in VisitFieldDecl()
706 Out << " = "; in VisitFieldDecl()
707 Init->printPretty(Out, nullptr, Policy, Indentation); in VisitFieldDecl()
713 Out << *D << ":"; in VisitLabelDecl()
726 Out << VarDecl::getStorageClassSpecifierString(SC) << " "; in VisitVarDecl()
732 Out << "__thread "; in VisitVarDecl()
735 Out << "_Thread_local "; in VisitVarDecl()
738 Out << "thread_local "; in VisitVarDecl()
743 Out << "__module_private__ "; in VisitVarDecl()
746 Out << "constexpr "; in VisitVarDecl()
765 Out << "("; in VisitVarDecl()
767 Out << " = "; in VisitVarDecl()
772 Init->printPretty(Out, nullptr, SubPolicy, Indentation); in VisitVarDecl()
774 Out << ")"; in VisitVarDecl()
785 Out << "__asm ("; in VisitFileScopeAsmDecl()
786 D->getAsmString()->printPretty(Out, nullptr, Policy, Indentation); in VisitFileScopeAsmDecl()
787 Out << ")"; in VisitFileScopeAsmDecl()
791 Out << "@import " << D->getImportedModule()->getFullModuleName() in VisitImportDecl()
796 Out << "static_assert("; in VisitStaticAssertDecl()
797 D->getAssertExpr()->printPretty(Out, nullptr, Policy, Indentation); in VisitStaticAssertDecl()
799 Out << ", "; in VisitStaticAssertDecl()
800 SL->printPretty(Out, nullptr, Policy, Indentation); in VisitStaticAssertDecl()
802 Out << ")"; in VisitStaticAssertDecl()
810 Out << "inline "; in VisitNamespaceDecl()
811 Out << "namespace " << *D << " {\n"; in VisitNamespaceDecl()
817 Out << "using namespace "; in VisitUsingDirectiveDecl()
819 D->getQualifier()->print(Out, Policy); in VisitUsingDirectiveDecl()
820 Out << *D->getNominatedNamespaceAsWritten(); in VisitUsingDirectiveDecl()
824 Out << "namespace " << *D << " = "; in VisitNamespaceAliasDecl()
826 D->getQualifier()->print(Out, Policy); in VisitNamespaceAliasDecl()
827 Out << *D->getAliasedNamespace(); in VisitNamespaceAliasDecl()
837 Out << "__module_private__ "; in VisitCXXRecordDecl()
838 Out << D->getKindName(); in VisitCXXRecordDecl()
843 Out << ' ' << *D; in VisitCXXRecordDecl()
848 Out << " : "; in VisitCXXRecordDecl()
852 Out << ", "; in VisitCXXRecordDecl()
855 Out << "virtual "; in VisitCXXRecordDecl()
860 Out << " "; in VisitCXXRecordDecl()
862 Out << Base->getType().getAsString(Policy); in VisitCXXRecordDecl()
865 Out << "..."; in VisitCXXRecordDecl()
871 Out << " {\n"; in VisitCXXRecordDecl()
887 Out << "extern \"" << l << "\" "; in VisitLinkageSpecDecl()
889 Out << "{\n"; in VisitLinkageSpecDecl()
901 Out << "template <"; in PrintTemplateParameters()
905 Out << ", "; in PrintTemplateParameters()
912 Out << "typename "; in PrintTemplateParameters()
914 Out << "class "; in PrintTemplateParameters()
917 Out << "..."; in PrintTemplateParameters()
919 Out << *TTP; in PrintTemplateParameters()
922 Out << " = "; in PrintTemplateParameters()
923 Args->get(i).print(Policy, Out); in PrintTemplateParameters()
925 Out << " = "; in PrintTemplateParameters()
926 Out << TTP->getDefaultArgument().getAsString(Policy); in PrintTemplateParameters()
936 Out << " = "; in PrintTemplateParameters()
937 Args->get(i).print(Policy, Out); in PrintTemplateParameters()
939 Out << " = "; in PrintTemplateParameters()
940 NTTP->getDefaultArgument()->printPretty(Out, nullptr, Policy, in PrintTemplateParameters()
950 Out << "> "; in PrintTemplateParameters()
958 Out << "class "; in VisitTemplateDecl()
960 Out << "..."; in VisitTemplateDecl()
961 Out << D->getName(); in VisitTemplateDecl()
987 Out << '\n'; in VisitClassTemplateDecl()
1001 Out << '('; in PrintObjCMethodType()
1003 Out << "in "; in PrintObjCMethodType()
1005 Out << "inout "; in PrintObjCMethodType()
1007 Out << "out "; in PrintObjCMethodType()
1009 Out << "bycopy "; in PrintObjCMethodType()
1011 Out << "byref "; in PrintObjCMethodType()
1013 Out << "oneway "; in PrintObjCMethodType()
1016 Out << getNullabilitySpelling(*nullability, true) << ' '; in PrintObjCMethodType()
1019 Out << Ctx.getUnqualifiedObjCPointerType(T).getAsString(Policy); in PrintObjCMethodType()
1020 Out << ')'; in PrintObjCMethodType()
1024 Out << "<"; in PrintObjCTypeParams()
1030 Out << ", "; in PrintObjCTypeParams()
1038 Out << "__covariant "; in PrintObjCTypeParams()
1042 Out << "__contravariant "; in PrintObjCTypeParams()
1046 Out << Param->getDeclName().getAsString(); in PrintObjCTypeParams()
1049 Out << " : " << Param->getUnderlyingType().getAsString(Policy); in PrintObjCTypeParams()
1052 Out << ">"; in PrintObjCTypeParams()
1057 Out << "- "; in VisitObjCMethodDecl()
1059 Out << "+ "; in VisitObjCMethodDecl()
1070 Out << " " << name.substr(lastPos, pos - lastPos) << ':'; in VisitObjCMethodDecl()
1074 Out << *PI; in VisitObjCMethodDecl()
1079 Out << " " << name; in VisitObjCMethodDecl()
1082 Out << ", ..."; in VisitObjCMethodDecl()
1087 Out << ' '; in VisitObjCMethodDecl()
1088 OMD->getBody()->printPretty(Out, nullptr, Policy); in VisitObjCMethodDecl()
1091 Out << ';'; in VisitObjCMethodDecl()
1100 Out << "@implementation " << I << " : " << *SID; in VisitObjCImplementationDecl()
1102 Out << "@implementation " << I; in VisitObjCImplementationDecl()
1105 Out << "{\n"; in VisitObjCImplementationDecl()
1113 Out << "}\n"; in VisitObjCImplementationDecl()
1116 Out << "\n"; in VisitObjCImplementationDecl()
1121 Out << "\n"; in VisitObjCImplementationDecl()
1122 Out << "@end"; in VisitObjCImplementationDecl()
1130 Out << "@class " << I; in VisitObjCInterfaceDecl()
1136 Out << ";"; in VisitObjCInterfaceDecl()
1140 Out << "@interface " << I; in VisitObjCInterfaceDecl()
1147 Out << " : " << QualType(OID->getSuperClassType(), 0).getAsString(Policy); in VisitObjCInterfaceDecl()
1154 Out << (I == Protocols.begin() ? '<' : ',') << **I; in VisitObjCInterfaceDecl()
1155 Out << "> "; in VisitObjCInterfaceDecl()
1159 Out << "{\n"; in VisitObjCInterfaceDecl()
1168 Out << "}\n"; in VisitObjCInterfaceDecl()
1171 Out << "\n"; in VisitObjCInterfaceDecl()
1177 Out << "\n"; in VisitObjCInterfaceDecl()
1178 Out << "@end"; in VisitObjCInterfaceDecl()
1184 Out << "@protocol " << *PID << ";\n"; in VisitObjCProtocolDecl()
1190 Out << "@protocol " << *PID; in VisitObjCProtocolDecl()
1193 Out << (I == Protocols.begin() ? '<' : ',') << **I; in VisitObjCProtocolDecl()
1194 Out << ">\n"; in VisitObjCProtocolDecl()
1196 Out << "@protocol " << *PID << '\n'; in VisitObjCProtocolDecl()
1198 Out << "@end"; in VisitObjCProtocolDecl()
1202 Out << "@implementation " << *PID->getClassInterface() << '(' << *PID <<")\n"; in VisitObjCCategoryImplDecl()
1205 Out << "@end"; in VisitObjCCategoryImplDecl()
1210 Out << "@interface " << *PID->getClassInterface(); in VisitObjCCategoryDecl()
1214 Out << "(" << *PID << ")\n"; in VisitObjCCategoryDecl()
1216 Out << "{\n"; in VisitObjCCategoryDecl()
1222 Out << "}\n"; in VisitObjCCategoryDecl()
1226 Out << "@end"; in VisitObjCCategoryDecl()
1232 Out << "@compatibility_alias " << *AID in VisitObjCCompatibleAliasDecl()
1240 Out << "@required\n"; in VisitObjCPropertyDecl()
1242 Out << "@optional\n"; in VisitObjCPropertyDecl()
1246 Out << "@property"; in VisitObjCPropertyDecl()
1249 Out << " ("; in VisitObjCPropertyDecl()
1252 Out << (first ? ' ' : ',') << "readonly"; in VisitObjCPropertyDecl()
1257 Out << (first ? ' ' : ',') << "getter = "; in VisitObjCPropertyDecl()
1258 PDecl->getGetterName().print(Out); in VisitObjCPropertyDecl()
1262 Out << (first ? ' ' : ',') << "setter = "; in VisitObjCPropertyDecl()
1263 PDecl->getSetterName().print(Out); in VisitObjCPropertyDecl()
1268 Out << (first ? ' ' : ',') << "assign"; in VisitObjCPropertyDecl()
1274 Out << (first ? ' ' : ',') << "readwrite"; in VisitObjCPropertyDecl()
1279 Out << (first ? ' ' : ',') << "retain"; in VisitObjCPropertyDecl()
1284 Out << (first ? ' ' : ',') << "strong"; in VisitObjCPropertyDecl()
1289 Out << (first ? ' ' : ',') << "copy"; in VisitObjCPropertyDecl()
1295 Out << (first ? ' ' : ',') << "nonatomic"; in VisitObjCPropertyDecl()
1300 Out << (first ? ' ' : ',') << "atomic"; in VisitObjCPropertyDecl()
1310 Out << (first ? ' ' : ',') << "null_resettable"; in VisitObjCPropertyDecl()
1312 Out << (first ? ' ' : ',') in VisitObjCPropertyDecl()
1320 Out << (first ? ' ' : ',') << "class"; in VisitObjCPropertyDecl()
1325 Out << " )"; in VisitObjCPropertyDecl()
1327 Out << ' ' << PDecl->getASTContext().getUnqualifiedObjCPointerType(T). in VisitObjCPropertyDecl()
1330 Out << ';'; in VisitObjCPropertyDecl()
1335 Out << "@synthesize "; in VisitObjCPropertyImplDecl()
1337 Out << "@dynamic "; in VisitObjCPropertyImplDecl()
1338 Out << *PID->getPropertyDecl(); in VisitObjCPropertyImplDecl()
1340 Out << '=' << *PID->getPropertyIvarDecl(); in VisitObjCPropertyImplDecl()
1345 Out << "using "; in VisitUsingDecl()
1347 Out << "typename "; in VisitUsingDecl()
1348 D->getQualifier()->print(Out, Policy); in VisitUsingDecl()
1349 Out << *D; in VisitUsingDecl()
1354 Out << "using typename "; in VisitUnresolvedUsingTypenameDecl()
1355 D->getQualifier()->print(Out, Policy); in VisitUnresolvedUsingTypenameDecl()
1356 Out << D->getDeclName(); in VisitUnresolvedUsingTypenameDecl()
1361 Out << "using "; in VisitUnresolvedUsingValueDecl()
1362 D->getQualifier()->print(Out, Policy); in VisitUnresolvedUsingValueDecl()
1363 Out << D->getDeclName(); in VisitUnresolvedUsingValueDecl()
1371 Out << "#pragma omp threadprivate"; in VisitOMPThreadPrivateDecl()
1376 Out << (I == D->varlist_begin() ? '(' : ','); in VisitOMPThreadPrivateDecl()
1378 ND->printQualifiedName(Out); in VisitOMPThreadPrivateDecl()
1380 Out << ")"; in VisitOMPThreadPrivateDecl()
1386 Out << "#pragma omp declare reduction ("; in VisitOMPDeclareReductionDecl()
1397 Out << OpName; in VisitOMPDeclareReductionDecl()
1400 D->printName(Out); in VisitOMPDeclareReductionDecl()
1402 Out << " : "; in VisitOMPDeclareReductionDecl()
1403 D->getType().print(Out, Policy); in VisitOMPDeclareReductionDecl()
1404 Out << " : "; in VisitOMPDeclareReductionDecl()
1405 D->getCombiner()->printPretty(Out, nullptr, Policy, 0); in VisitOMPDeclareReductionDecl()
1406 Out << ")"; in VisitOMPDeclareReductionDecl()
1408 Out << " initializer("; in VisitOMPDeclareReductionDecl()
1409 Init->printPretty(Out, nullptr, Policy, 0); in VisitOMPDeclareReductionDecl()
1410 Out << ")"; in VisitOMPDeclareReductionDecl()
1416 D->getInit()->printPretty(Out, nullptr, Policy, Indentation); in VisitOMPCapturedExprDecl()