finishString casts the given buffer to a string and returns the unused portion of the buffer. The caller must not use buf again.
(buf []byte)
| 84 | // finishString casts the given buffer to a string and returns the unused |
| 85 | // portion of the buffer. The caller must not use buf again. |
| 86 | func (s *scanner) finishString(buf []byte) string { |
| 87 | str := *(*string)(unsafe.Pointer(&buf)) |
| 88 | s.returnBuffer(buf) |
| 89 | return str |
| 90 | } |
| 91 | |
| 92 | func (s *scanner) scan(lval *sqlSymType) { |
| 93 | lval.id = 0 |
no test coverage detected