(string, ops, length = ops.byteLength(string))
| 504 | } |
| 505 | |
| 506 | function createFromString(string, ops, length = ops.byteLength(string)) { |
| 507 | const buf = Buffer.allocUnsafeSlow(length); |
| 508 | const actual = ops.write(buf, string, 0, length); |
| 509 | return actual < length ? new FastBuffer(buf.buffer, 0, actual) : buf; |
| 510 | } |
| 511 | |
| 512 | function fromString(string, encoding) { |
| 513 | let ops; |
no test coverage detected
searching dependent graphs…