MCPcopy Index your code
hub / github.com/bytenode/bytenode / runBytecodeFile

Function runBytecodeFile

lib/index.js:472–480  ·  view source on GitHub ↗
(filename)

Source from the content-addressed store, hash-verified

470 * @returns {any} The result of the very last statement executed in the script.
471 */
472const runBytecodeFile = function (filename) {
473 if (typeof filename !== 'string') {
474 throw new Error(`filename must be a string. ${typeof filename} was given.`);
475 }
476
477 const bytecodeBuffer = fs.readFileSync(filename);
478
479 return runBytecode(bytecodeBuffer);
480};
481
482Module._extensions[COMPILED_EXTNAME] = function (fileModule, filename) {
483 const bytecodeBuffer = fs.readFileSync(filename);

Callers

nothing calls this directly

Calls 1

runBytecodeFunction · 0.85

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…