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

Function addDeserializeCallback

lib/internal/v8/startup_snapshot.js:47–59  ·  view source on GitHub ↗
(callback, data)

Source from the content-addressed store, hash-verified

45}
46
47function addDeserializeCallback(callback, data) {
48 throwIfNotBuildingSnapshot();
49 validateFunction(callback, 'callback');
50 if (!deserializeCallbackIsSet) {
51 // TODO(joyeecheung): when the main function handling is done in JS,
52 // the deserialize callbacks can always be invoked. For now only
53 // store it in C++ when it's actually used to avoid unnecessary
54 // C++ -> JS costs.
55 setDeserializeCallback(runDeserializeCallbacks);
56 deserializeCallbackIsSet = true;
57 }
58 deserializeCallbacks.push([callback, data]);
59}
60
61const serializeCallbacks = [];
62const afterUserSerializeCallbacks = []; // Callbacks to run after user callbacks

Callers 6

tls.jsFile · 0.85
buffer.jsFile · 0.85
[kSerializeResolver]Method · 0.85
mainFunction · 0.85

Calls 2

pushMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…