Nix 2.36.0
Nix, the purely functional package manager; unstable internal interfaces
Loading...
Searching...
No Matches
nix::EvalMemory Class Reference

Classes

struct  Statistics

Public Member Functions

 EvalMemory (const EvalMemory &)=delete
 EvalMemory (EvalMemory &&)=delete
EvalMemory & operator= (const EvalMemory &)=delete
EvalMemory & operator= (EvalMemory &&)=delete
void * allocBytes (size_t n)
template<typename T, std::size_t N = 0>
void * allocBytes (size_t count)
void * allocBytesAtomic (size_t n)
template<typename T, std::size_t N = 0>
void * allocBytesAtomic (size_t count)
Value * allocValue ()
Env & allocEnv (size_t size)
Bindings * allocBindings (size_t capacity)
BindingsBuilder buildBindings (SymbolTable &symbols, size_t capacity)
ListBuilder buildList (size_t size)
const Statistics & getStats () const &

Public Attributes

Exprs exprs

Member Function Documentation

◆ allocBytes() [1/2]

template<typename T, std::size_t N>
void * nix::EvalMemory::allocBytes ( size_t count)
inline

Allocates count * sizeof(T) + N contiguous bytes.

Exceptions
bad_allocif the computation would overflow.

◆ allocBytes() [2/2]

void * nix::EvalMemory::allocBytes ( size_t n)
inline

Note: Various places expect the allocated memory to be zeroed.

◆ allocBytesAtomic() [1/2]

template<typename T, std::size_t N>
void * nix::EvalMemory::allocBytesAtomic ( size_t count)
inline

Allocates count * sizeof(T) + N contiguous bytes that the garbage collector does not scan for pointers. The memory is not zeroed.

Exceptions
bad_allocif the computation would overflow.

◆ allocBytesAtomic() [2/2]

void * nix::EvalMemory::allocBytesAtomic ( size_t n)
inline

Allocates n bytes that the garbage collector does not scan for pointers. Unlike allocBytes(), the memory is not zeroed.

Member Data Documentation

◆ exprs

Exprs nix::EvalMemory::exprs

Storage for the AST nodes


The documentation for this class was generated from the following files:
  • libexpr/include/nix/expr/eval.hh
  • libexpr/attr-set.cc
  • libexpr/eval.cc
  • libexpr/include/nix/expr/eval-inline.hh