Lines Matching defs:stream

12 void Function::PrintDeclarationHeader(std::ostream& stream,
15 stream << std::string(indentation, ' ') << "// " << description_ << "\n";
17 stream << std::string(indentation, ' ') << "// " << pos_ << "\n";
18 stream << std::string(indentation, ' ');
19 if (IsExport()) stream << "V8_EXPORT_PRIVATE ";
21 stream << "V8_INLINE ";
23 stream << "inline ";
24 if (IsStatic()) stream << "static ";
25 if (IsConstexpr()) stream << "constexpr ";
26 stream << return_type_ << " " << name_ << "(";
29 if (!first) stream << ", ";
30 stream << p.type;
31 if (!p.name.empty()) stream << " " << p.name;
32 if (!p.default_value.empty()) stream << " = " << p.default_value;
35 stream << ")";
36 if (IsConst()) stream << " const";
39 void Function::PrintDeclaration(std::ostream& stream, int indentation) const {
43 PrintDeclarationHeader(stream, indentation);
44 stream << ";\n";
48 std::ostream& stream, const std::function<void(std::ostream&)>& builder,
50 PrintBeginDefinition(stream, indentation);
52 builder(stream);
54 PrintEndDefinition(stream, indentation);
58 std::ostream& stream, const std::function<void(std::ostream&)>& builder,
60 PrintDeclarationHeader(stream, indentation);
61 stream << " {\n";
63 builder(stream);
65 PrintEndDefinition(stream, indentation);
68 void Function::PrintBeginDefinition(std::ostream& stream,
70 stream << std::string(indentation, ' ') << "// " << pos_ << "\n";
77 stream << std::string(indentation, ' ');
78 stream << "template<";
83 stream << ", ";
87 stream << "class " << p.name;
89 stream << p.type << " " << p.name;
94 stream << ">\n";
99 stream << std::string(indentation, ' ') << return_type_ << " " << scope
103 if (!first) stream << ", ";
104 stream << p.type;
105 if (!p.name.empty()) stream << " " << p.name;
108 stream << ")";
110 stream << " const";
112 stream << " {\n";
115 void Function::PrintEndDefinition(std::ostream& stream, int indentation) const {
116 stream << std::string(indentation, ' ');
117 stream << "}\n\n";