mirror of
https://github.com/NixOS/nix
synced 2025-06-25 10:41:16 +02:00
autoCallFunction: accept const Bindings &
It does not need to mutate the attrs. `const` is shallow. Avoids a const_cast in the hercules-ci-cnix-expr bindings.
This commit is contained in:
parent
8f553f6eef
commit
a3613f2a3c
2 changed files with 2 additions and 2 deletions
|
@ -1730,7 +1730,7 @@ void EvalState::incrFunctionCall(ExprLambda * fun)
|
|||
}
|
||||
|
||||
|
||||
void EvalState::autoCallFunction(Bindings & args, Value & fun, Value & res)
|
||||
void EvalState::autoCallFunction(const Bindings & args, Value & fun, Value & res)
|
||||
{
|
||||
auto pos = fun.determinePos(noPos);
|
||||
|
||||
|
|
|
@ -693,7 +693,7 @@ public:
|
|||
* Automatically call a function for which each argument has a
|
||||
* default value or has a binding in the `args` map.
|
||||
*/
|
||||
void autoCallFunction(Bindings & args, Value & fun, Value & res);
|
||||
void autoCallFunction(const Bindings & args, Value & fun, Value & res);
|
||||
|
||||
/**
|
||||
* Allocation primitives.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue