1
1
Fork 0
mirror of https://github.com/NixOS/nix.git synced 2025-11-13 05:56:03 +01:00

Flake schemas

This applies upstream https://github.com/NixOS/nix/pull/8892.
This commit is contained in:
Eelco Dolstra 2024-07-11 16:49:49 +02:00
parent 51583851a2
commit 6406619c44
25 changed files with 702 additions and 819 deletions

View file

@ -34,7 +34,11 @@ class EvalCache : public std::enable_shared_from_this<EvalCache>
friend struct CachedEvalError;
std::shared_ptr<AttrDb> db;
public:
EvalState & state;
private:
typedef std::function<Value *()> RootLoader;
RootLoader rootLoader;
RootValue value;
@ -89,7 +93,10 @@ class AttrCursor : public std::enable_shared_from_this<AttrCursor>
friend class EvalCache;
friend struct CachedEvalError;
public:
ref<EvalCache> root;
private:
typedef std::optional<std::pair<std::shared_ptr<AttrCursor>, Symbol>> Parent;
Parent parent;
RootValue _value;