MCPcopy Index your code
hub / github.com/TypeScriptToLua/TypeScriptToLua / nodeStartsWithParenthesis

Method nodeStartsWithParenthesis

src/LuaPrinter.ts:302–314  ·  view source on GitHub ↗
(sourceNode: SourceNode)

Source from the content-addressed store, hash-verified

300 }
301
302 private nodeStartsWithParenthesis(sourceNode: SourceNode): boolean {
303 let result: boolean | undefined;
304 sourceNode.walk(chunk => {
305 if (result === undefined) {
306 chunk = chunk.trimLeft(); // Ignore leading whitespace
307
308 if (chunk.length > 0) {
309 result = chunk.startsWith("(");
310 }
311 }
312 });
313 return result ?? false;
314 }
315
316 protected printStatementArray(statements: lua.Statement[]): SourceChunk[] {
317 const statementNodes: SourceNode[] = [];

Callers 1

printStatementArrayMethod · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected