aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--libbuild2/cc/common.cxx3
-rw-r--r--libbuild2/file.cxx4
-rw-r--r--libbuild2/utility.hxx3
3 files changed, 6 insertions, 4 deletions
diff --git a/libbuild2/cc/common.cxx b/libbuild2/cc/common.cxx
index c1e60d2..dfc78e7 100644
--- a/libbuild2/cc/common.cxx
+++ b/libbuild2/cc/common.cxx
@@ -1567,8 +1567,7 @@ namespace build2
//
string d ("-DLIB");
- d += sanitize_identifier (
- ucase (const_cast<const string&> (t.name)));
+ d += sanitize_identifier (ucase (t.name));
d += '_';
d += suffix;
diff --git a/libbuild2/file.cxx b/libbuild2/file.cxx
index f755506..fcd3c7c 100644
--- a/libbuild2/file.cxx
+++ b/libbuild2/file.cxx
@@ -2335,7 +2335,7 @@ namespace build2
//
const path* p (nullptr);
- string valv (sanitize_identifier (string (tgt.value)));
+ string valv (sanitize_identifier (tgt.value));
if (tgt.typed ())
{
@@ -2350,7 +2350,7 @@ namespace build2
if (p == nullptr)
{
- string ttv (sanitize_identifier (string (tgt.type)));
+ string ttv (sanitize_identifier (tgt.type));
p = lookup (vp.insert (n + '.' + valv + '.' + ttv), e);
}
}
diff --git a/libbuild2/utility.hxx b/libbuild2/utility.hxx
index f4fd7bc..99d6806 100644
--- a/libbuild2/utility.hxx
+++ b/libbuild2/utility.hxx
@@ -73,7 +73,9 @@ namespace build2
using butl::icase_compare_string;
using butl::icase_compare_c_string;
using butl::lcase;
+ using butl::make_lcase;
using butl::ucase;
+ using butl::make_ucase;
using butl::alpha;
using butl::alnum;
using butl::digit;
@@ -82,6 +84,7 @@ namespace build2
using butl::trim;
using butl::next_word;
using butl::sanitize_identifier;
+ using butl::make_sanitized_identifier;
using butl::sanitize_strlit;
using butl::make_guard;