MCPcopy Create free account
hub / github.com/Tracktion/choc / writeBlock

Method writeBlock

choc/text/choc_CodePrinter.h:317–333  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

315}
316
317inline void CodePrinter::writeBlock (std::string_view text)
318{
319 auto lineStart = text.begin();
320 auto end = text.end();
321
322 for (auto i = lineStart; i != end; ++i)
323 {
324 if (*i == '\n')
325 {
326 auto nextLine = i + 1;
327 append ({ lineStart, nextLine });
328 lineStart = nextLine;
329 }
330 }
331
332 append ({ lineStart, end });
333}
334
335inline void CodePrinter::trimTrailingBlankLines()
336{

Callers

nothing calls this directly

Calls 2

beginMethod · 0.45
endMethod · 0.45

Tested by

no test coverage detected