MCPcopy Index your code
hub / github.com/sql-js/sql.js / intArrayFromString

Function intArrayFromString

js/sql-debug.js:5371–5377  ·  view source on GitHub ↗

@type {function(string, boolean=, number=)}

(stringy, dontAddNull, length)

Source from the content-addressed store, hash-verified

5369
5370/** @type {function(string, boolean=, number=)} */
5371function intArrayFromString(stringy, dontAddNull, length) {
5372 var len = length > 0 ? length : lengthBytesUTF8(stringy)+1;
5373 var u8array = new Array(len);
5374 var numBytesWritten = stringToUTF8Array(stringy, u8array, 0, u8array.length);
5375 if (dontAddNull) u8array.length = numBytesWritten;
5376 return u8array;
5377}
5378
5379function intArrayToString(array) {
5380 var ret = [];

Callers 3

sql-debug.jsFile · 0.70
_getenvFunction · 0.70
_tzsetFunction · 0.70

Calls 2

lengthBytesUTF8Function · 0.70
stringToUTF8ArrayFunction · 0.70

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…