diff options
author | John Ericson <John.Ericson@Obsidian.Systems> | 2021-03-10 02:20:32 +0000 |
---|---|---|
committer | John Ericson <John.Ericson@Obsidian.Systems> | 2022-03-11 22:30:10 +0000 |
commit | 91adfb8894b4b8183c2948712d56a97bb9d93d9f (patch) | |
tree | 4b0cef091af49d7cd3d3c39321b634d846aa7e8d /src/libexpr/eval.cc | |
parent | d5322698a2abbc6d141e1d244e17b0d226a2f18b (diff) |
Create some type aliases for string Contexts
Diffstat (limited to 'src/libexpr/eval.cc')
-rw-r--r-- | src/libexpr/eval.cc | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/libexpr/eval.cc b/src/libexpr/eval.cc index c65ef9738..126e0af8c 100644 --- a/src/libexpr/eval.cc +++ b/src/libexpr/eval.cc @@ -1903,7 +1903,7 @@ std::string_view EvalState::forceString(Value & v, const Pos & pos) /* Decode a context string ‘!<name>!<path>’ into a pair <path, name>. */ -std::pair<std::string, std::string> decodeContext(std::string_view s) +NixStringContextElem decodeContext(std::string_view s) { if (s.at(0) == '!') { size_t index = s.find("!", 1); @@ -1921,9 +1921,9 @@ void copyContext(const Value & v, PathSet & context) } -std::vector<std::pair<Path, std::string>> Value::getContext() +NixStringContext Value::getContext() { - std::vector<std::pair<Path, std::string>> res; + NixStringContext res; assert(internalType == tString); if (string.context) for (const char * * p = string.context; *p; ++p) |