aboutsummaryrefslogtreecommitdiff
path: root/src/libexpr/symbol-table.hh
diff options
context:
space:
mode:
authorEelco Dolstra <edolstra@gmail.com>2022-02-21 16:37:25 +0100
committerEelco Dolstra <edolstra@gmail.com>2022-02-21 16:37:25 +0100
commit36c7b12f3354606a50808197f6695c185fd02893 (patch)
treefbd1e816de491509af74ce21eed1ae1923e8acb9 /src/libexpr/symbol-table.hh
parent1ac2664472d0135503e54f0d924a802023855003 (diff)
Remove std::string alias
Diffstat (limited to 'src/libexpr/symbol-table.hh')
-rw-r--r--src/libexpr/symbol-table.hh8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/libexpr/symbol-table.hh b/src/libexpr/symbol-table.hh
index a090ebae5..48d20c29d 100644
--- a/src/libexpr/symbol-table.hh
+++ b/src/libexpr/symbol-table.hh
@@ -17,8 +17,8 @@ namespace nix {
class Symbol
{
private:
- const string * s; // pointer into SymbolTable
- Symbol(const string * s) : s(s) { };
+ const std::string * s; // pointer into SymbolTable
+ Symbol(const std::string * s) : s(s) { };
friend class SymbolTable;
public:
@@ -72,7 +72,7 @@ class SymbolTable
{
private:
std::unordered_map<std::string_view, Symbol> symbols;
- std::list<string> store;
+ std::list<std::string> store;
public:
Symbol create(std::string_view s)
@@ -84,7 +84,7 @@ public:
auto it = symbols.find(s);
if (it != symbols.end()) return it->second;
- const string & rawSym = store.emplace_back(s);
+ auto & rawSym = store.emplace_back(s);
return symbols.emplace(rawSym, Symbol(&rawSym)).first->second;
}