Nix 2.36.0
Nix, the purely functional package manager; unstable internal interfaces
Loading...
Searching...
No Matches
nix::FunctionCallTrace Class Reference
Inheritance diagram for nix::FunctionCallTrace:
nix::EvalProfiler

Public Member Functions

void preFunctionCallHook (EvalState &state, const Value &v, std::span< Value *const > args, const PosIdx pos) override
void postFunctionCallHook (EvalState &state, const Value &v, std::span< Value *const > args, const PosIdx pos) override
Public Member Functions inherited from nix::EvalProfiler
Hooks getNeededHooks ()

Additional Inherited Members

Public Types inherited from nix::EvalProfiler
enum  Hook { preFunctionCall , postFunctionCall }
using Hooks = std::bitset<numHooks>
Static Public Attributes inherited from nix::EvalProfiler
static constexpr std::size_t numHooks = Hook::postFunctionCall + 1
Protected Member Functions inherited from nix::EvalProfiler
void invalidateNeededHooks ()

Member Function Documentation

◆ postFunctionCallHook()

void nix::FunctionCallTrace::postFunctionCallHook ( EvalState & state,
const Value & v,
std::span< Value *const > args,
const PosIdx pos )
overridevirtual

Hook called on EvalState::callFunction exit. Gets called only if (getNeededHooks().test(Hook::postFunctionCall)) is true.

Parameters
stateEvaluator state.
vFunction being invoked.
argsFunction arguments.
posFunction position.

Reimplemented from nix::EvalProfiler.

◆ preFunctionCallHook()

void nix::FunctionCallTrace::preFunctionCallHook ( EvalState & state,
const Value & v,
std::span< Value *const > args,
const PosIdx pos )
overridevirtual

Hook called in the EvalState::callFunction preamble. Gets called only if (getNeededHooks().test(Hook::preFunctionCall)) is true.

Parameters
stateEvaluator state.
vFunction being invoked.
argsFunction arguments.
posFunction position.

Reimplemented from nix::EvalProfiler.


The documentation for this class was generated from the following files: