mirror of
https://github.com/NixOS/nix.git
synced 2025-11-13 14:02:42 +01:00
libexpr: Use proxy ListView for all Value list accesses
This also makes it possible to make `payload` field private in the `ValueStorage` class template.
This commit is contained in:
parent
c39cc00404
commit
e73fcf7b53
16 changed files with 309 additions and 116 deletions
|
|
@ -289,7 +289,7 @@ static Flake readFlake(
|
|||
Explicit<bool> { state.forceBool(*setting.value, setting.pos, "") });
|
||||
else if (setting.value->type() == nList) {
|
||||
std::vector<std::string> ss;
|
||||
for (auto elem : setting.value->listItems()) {
|
||||
for (auto elem : setting.value->listView()) {
|
||||
if (elem->type() != nString)
|
||||
state.error<TypeError>("list element in flake configuration setting '%s' is %s while a string is expected",
|
||||
state.symbols[setting.name], showType(*setting.value)).debugThrow();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue