about summary refs log tree commit diff
path: root/third_party/nix/src/libexpr/value-to-json.cc
diff options
context:
space:
mode:
Diffstat (limited to 'third_party/nix/src/libexpr/value-to-json.cc')
-rw-r--r--third_party/nix/src/libexpr/value-to-json.cc6
1 files changed, 3 insertions, 3 deletions
diff --git a/third_party/nix/src/libexpr/value-to-json.cc b/third_party/nix/src/libexpr/value-to-json.cc
index 52ab44083b91..0b641a41b5ac 100644
--- a/third_party/nix/src/libexpr/value-to-json.cc
+++ b/third_party/nix/src/libexpr/value-to-json.cc
@@ -51,15 +51,15 @@ void printValueAsJSON(EvalState& state, bool strict, Value& v,
         auto obj(out.object());
         StringSet names;
         for (auto& j : *v.attrs) {
-          names.insert(j.name);
+          names.insert(j.second.name);
         }
         for (auto& j : names) {
-          Attr& a(*v.attrs->find(state.symbols.Create(j)));
+          auto [_, a] = *v.attrs->find(state.symbols.Create(j));
           auto placeholder(obj.placeholder(j));
           printValueAsJSON(state, strict, *a.value, placeholder, context);
         }
       } else {
-        printValueAsJSON(state, strict, *i->value, out, context);
+        printValueAsJSON(state, strict, *i->second.value, out, context);
       }
       break;
     }