MCPcopy Create free account
hub / github.com/Achain-Dev/Achain / PrintBreakStatement

Function PrintBreakStatement

src/Chain/libraries/glua/glua_statement.cpp:115–128  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

113 }
114
115 void PrintBreakStatement(AstStatement* stmt, std::stringstream &buff, int indent) {
116 AstStatement* parent = stmt->parent;
117 // "break;" and not the last statement of the block
118 if ((parent->sub_print_count + parent->comment_print_count + 1) < parent->sub->size) {
119 PrintIndent(buff, indent);
120 buff << "do break end\n";
121 // StringBuffer_addPrintf(buff, "do break end\n", stmt->code.c_str());
122 }
123 else {
124 PrintIndent(buff, indent);
125 buff << "break\n";
126 // StringBuffer_addPrintf(buff, "break\n", stmt->code.c_str());
127 }
128 }
129
130 void PrintReturnStatement(AstStatement* stmt, std::stringstream &buff, int indent) {
131 AstStatement* parent = stmt->parent;

Callers 1

PrintAstStatementFunction · 0.85

Calls 1

PrintIndentFunction · 0.85

Tested by

no test coverage detected