diff options
author | Tuomas Tynkkynen <tuomas@tuxera.com> | 2018-02-16 05:13:39 +0200 |
---|---|---|
committer | Tuomas Tynkkynen <tuomas@tuxera.com> | 2018-02-17 16:54:21 +0200 |
commit | 37264ed0ad898cdd6880de8ce6e5dda7977eed5f (patch) | |
tree | 9050b8950967a0ff44b9e9c7ce2319ecde7c91e8 /src/libexpr | |
parent | 66eeff33456d544e5852e580d8cac21f0c38c11f (diff) |
libexpr: Avoid an unnecessary string copy in prim_derivationStrict
Diffstat (limited to 'src/libexpr')
-rw-r--r-- | src/libexpr/primops.cc | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/libexpr/primops.cc b/src/libexpr/primops.cc index f6c34d525..a800d2429 100644 --- a/src/libexpr/primops.cc +++ b/src/libexpr/primops.cc @@ -553,7 +553,7 @@ static void prim_derivationStrict(EvalState & state, const Pos & pos, Value * * for (auto & i : args[0]->attrs->lexicographicOrder()) { if (i->name == state.sIgnoreNulls) continue; - string key = i->name; + const string & key = i->name; vomit("processing attribute '%1%'", key); auto handleHashMode = [&](const std::string & s) { |