indent performs indentation according to the depth level and cs.Indent option.
()
| 60 | // indent performs indentation according to the depth level and cs.Indent |
| 61 | // option. |
| 62 | func (d *dumpState) indent() { |
| 63 | if d.ignoreNextIndent { |
| 64 | d.ignoreNextIndent = false |
| 65 | return |
| 66 | } |
| 67 | d.w.Write(bytes.Repeat([]byte(d.cs.Indent), d.depth)) |
| 68 | } |
| 69 | |
| 70 | // unpackValue returns values inside of non-nil interfaces when possible. |
| 71 | // This is useful for data types like structs, arrays, slices, and maps which |