assumes already started
(s String)
| 151 | |
| 152 | // assumes already started |
| 153 | func (b *unicodeStringBuilder) writeString(s String) { |
| 154 | a, u := devirtualizeString(s) |
| 155 | if u != nil { |
| 156 | b.buf = append(b.buf, u[1:]...) |
| 157 | b.unicode = true |
| 158 | } else { |
| 159 | for i := 0; i < len(a); i++ { |
| 160 | b.buf = append(b.buf, uint16(a[i])) |
| 161 | } |
| 162 | } |
| 163 | } |
| 164 | |
| 165 | func (b *unicodeStringBuilder) String() String { |
| 166 | if b.unicode { |
no test coverage detected