diff options
author | Ben Burdette <bburdette@gmail.com> | 2021-09-14 10:49:22 -0600 |
---|---|---|
committer | Ben Burdette <bburdette@gmail.com> | 2021-09-14 10:49:22 -0600 |
commit | 21071bfdeb0a5bc2b75018c91a4c2f138f233e33 (patch) | |
tree | 8fbdb2f7de3682ef977c737fd59970d2ed5dabb8 /src/libexpr/parser.y | |
parent | 176911102ce2c0be06bbfed9099f364d71c3c679 (diff) |
shared_ptr for StaticEnv
Diffstat (limited to 'src/libexpr/parser.y')
-rw-r--r-- | src/libexpr/parser.y | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/libexpr/parser.y b/src/libexpr/parser.y index f948dde47..d1e898677 100644 --- a/src/libexpr/parser.y +++ b/src/libexpr/parser.y @@ -570,7 +570,7 @@ namespace nix { Expr * EvalState::parse(const char * text, FileOrigin origin, - const Path & path, const Path & basePath, StaticEnv & staticEnv) + const Path & path, const Path & basePath, std::shared_ptr<StaticEnv> & staticEnv) { yyscan_t scanner; ParseData data(*this); @@ -633,13 +633,13 @@ Expr * EvalState::parseExprFromFile(const Path & path) } -Expr * EvalState::parseExprFromFile(const Path & path, StaticEnv & staticEnv) +Expr * EvalState::parseExprFromFile(const Path & path, std::shared_ptr<StaticEnv> & staticEnv) { return parse(readFile(path).c_str(), foFile, path, dirOf(path), staticEnv); } -Expr * EvalState::parseExprFromString(std::string_view s, const Path & basePath, StaticEnv & staticEnv) +Expr * EvalState::parseExprFromString(std::string_view s, const Path & basePath, std::shared_ptr<StaticEnv> & staticEnv) { return parse(s.data(), foString, "", basePath, staticEnv); } |