MCPcopy Create free account
hub / github.com/Koihik/LuaFormatter / visitFunctiondef

Method visitFunctiondef

src/FormatVisitor.cpp:1468–1479  ·  view source on GitHub ↗

FUNCTION funcbody;

Source from the content-addressed store, hash-verified

1466
1467// FUNCTION funcbody;
1468antlrcpp::Any FormatVisitor::visitFunctiondef(LuaParser::FunctiondefContext* ctx) {
1469 LOG_FUNCTION_BEGIN();
1470 cur_writer() << ctx->FUNCTION()->getText();
1471 cur_writer() << commentAfter(ctx->FUNCTION(), "");
1472 // disable indentForAlign_ in function body
1473 int temp = indentForAlign_;
1474 indentForAlign_ = 0;
1475 visitFuncbody(ctx->funcbody());
1476 indentForAlign_ = temp;
1477 LOG_FUNCTION_END();
1478 return nullptr;
1479}
1480
1481// LP parlist? RP block END
1482antlrcpp::Any FormatVisitor::visitFuncbody(LuaParser::FuncbodyContext* ctx) {

Callers

nothing calls this directly

Calls 2

FUNCTIONMethod · 0.80
funcbodyMethod · 0.80

Tested by

no test coverage detected