MCPcopy Index your code
hub / github.com/nodejs/node / latin1Write

Function latin1Write

lib/internal/buffer.js:972–980  ·  view source on GitHub ↗
(buf, string, offset = 0, length = buf.byteLength - offset)

Source from the content-addressed store, hash-verified

970}
971
972function latin1Write(buf, string, offset = 0, length = buf.byteLength - offset) {
973 if (offset < 0 || offset > buf.byteLength) {
974 throw new ERR_BUFFER_OUT_OF_BOUNDS('offset');
975 }
976 if (length < 0 || length > buf.byteLength - offset) {
977 throw new ERR_BUFFER_OUT_OF_BOUNDS('length');
978 }
979 return latin1WriteStatic(buf, string, offset, length);
980}
981
982function utf8Write(buf, string, offset = 0, length = buf.byteLength - offset) {
983 if (offset < 0 || offset > buf.byteLength) {

Callers 1

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…