go/printer.printer.linebreak (method)
14 uses
go/printer (current package)
nodes.go#L48: func (p *printer) linebreak(line, min int, ws whiteSpace, newSection bool) (nbreaks int) {
nodes.go#L179: if prev.IsValid() && prev.Line < line && p.linebreak(line, 0, ws, true) > 0 {
nodes.go#L255: nbreaks := p.linebreak(line, 0, ws, useFF || prevBreak+1 < i)
nodes.go#L350: if needsLinebreak && p.linebreak(parLineBeg, 0, ws, true) > 0 {
nodes.go#L375: p.linebreak(closing, 0, ignore, true)
nodes.go#L499: p.linebreak(p.lineFor(f.Pos()), 1, ignore, p.linesFrom(line) > 0)
nodes.go#L543: p.linebreak(p.lineFor(f.Pos()), 1, ignore, p.linesFrom(line) > 0)
nodes.go#L721: if p.linebreak(yline, 1, ws, true) > 0 {
nodes.go#L1090: p.linebreak(p.lineFor(s.Pos()), 1, ignore, i == 0 || nindent == 0 || p.linesFrom(line) > 0)
nodes.go#L1117: p.linebreak(p.lineFor(b.Rbrace), 1, ignore, true)
nodes.go#L1259: p.linebreak(p.lineFor(s.Stmt.Pos()), 1, ignore, true)
nodes.go#L1620: p.linebreak(p.lineFor(s.Pos()), 1, ignore, p.linesFrom(line) > 0)
nodes.go#L1629: p.linebreak(p.lineFor(s.Pos()), 1, ignore, p.linesFrom(line) > 0)
nodes.go#L1832: p.linebreak(p.lineFor(d.Pos()), min, ignore, tok == token.FUNC && p.numLines(d) > 1)
 |
The pages are generated with Golds v0.3.2-preview. (GOOS=darwin GOARCH=amd64)
Golds is a Go 101 project developed by Tapir Liu.
PR and bug reports are welcome and can be submitted to the issue list.
Please follow @Go100and1 (reachable from the left QR code) to get the latest news of Golds. |