aboutsummaryrefslogtreecommitdiff
path: root/build2/functions-builtin.cxx
diff options
context:
space:
mode:
authorKaren Arutyunov <karen@codesynthesis.com>2017-06-22 20:06:01 +0300
committerKaren Arutyunov <karen@codesynthesis.com>2017-06-26 13:46:57 +0300
commitf65377448e74fc7e575e4df258fb0a48a09e39cc (patch)
tree1339f77be0b16a46c5e7d500feec037021bfb3d8 /build2/functions-builtin.cxx
parente755de789e146beea66bf6a4b55685034502df41 (diff)
Add support for $path_search() and $path_match()
Diffstat (limited to 'build2/functions-builtin.cxx')
-rw-r--r--build2/functions-builtin.cxx11
1 files changed, 1 insertions, 10 deletions
diff --git a/build2/functions-builtin.cxx b/build2/functions-builtin.cxx
index f9bbda5..d6d9501 100644
--- a/build2/functions-builtin.cxx
+++ b/build2/functions-builtin.cxx
@@ -47,16 +47,7 @@ namespace build2
f["getenv"] = [](names name)
{
- // Note that if the name size is greater than one, we will fail with the
- // proper diagnostics.
- //
- assert (!name.empty ());
-
- string n (name.size () == 1
- ? convert<string> (move (name[0]))
- : convert<string> (move (name)));
-
- return getenv (n);
+ return getenv (convert<string> (move (name)));
};
}
}