Nix 2.36.0
Nix, the purely functional package manager; unstable internal interfaces
Loading...
Searching...
No Matches
nix::ExprPath Struct Reference
Inheritance diagram for nix::ExprPath:
nix::Expr

Public Member Functions

 ExprPath (std::pmr::polymorphic_allocator< char > &alloc, ref< SourceAccessor > accessor, std::string_view sv)
Value * maybeThunk (EvalState &state, Env &env) override
void show (const SymbolTable &symbols, std::ostream &str) const override
void eval (EvalState &state, Env &env, Value &v) override
void bindVars (EvalState &es, const std::shared_ptr< const StaticEnv > &env) override
Public Member Functions inherited from nix::Expr
void eval (EvalState &state, Env &env, Value &v, std::string_view errorCtx)
virtual void evalForUpdate (EvalState &state, Env &env, UpdateQueue &q, std::string_view errorCtx)
virtual void setName (Symbol name)
virtual void setDocComment (DocComment docComment)
virtual PosIdx getPos () const
virtual void resetCursedOr ()
virtual void warnIfCursedOr (const SymbolTable &symbols, const PosTable &positions)

Public Attributes

ref< SourceAccessor > accessor
Value v

Additional Inherited Members

Static Public Attributes inherited from nix::Expr
static Counter nrExprs

Member Function Documentation

◆ bindVars()

void nix::ExprPath::bindVars ( EvalState & es,
const std::shared_ptr< const StaticEnv > & env )
overridevirtual

Reimplemented from nix::Expr.

◆ eval()

void nix::ExprPath::eval ( EvalState & state,
Env & env,
Value & v )
overridevirtual

Normal evaluation, implemented directly by all subclasses.

Reimplemented from nix::Expr.

◆ maybeThunk()

Value * nix::ExprPath::maybeThunk ( EvalState & state,
Env & env )
overridevirtual

Create a thunk for the delayed computation of the given expression in the given environment. But if the expression is a variable, then look it up right away. This significantly reduces the number of thunks allocated.

Reimplemented from nix::Expr.

◆ show()

void nix::ExprPath::show ( const SymbolTable & symbols,
std::ostream & str ) const
overridevirtual

Reimplemented from nix::Expr.


The documentation for this struct was generated from the following files:
  • libexpr/include/nix/expr/nixexpr.hh
  • libexpr/eval.cc
  • libexpr/nixexpr.cc