diff options
author | Boris Kolpackov <boris@codesynthesis.com> | 2017-01-19 12:45:04 +0200 |
---|---|---|
committer | Boris Kolpackov <boris@codesynthesis.com> | 2017-01-19 12:45:04 +0200 |
commit | 5607313a91e5ca0113b1f8b9acfd02c1fb105346 (patch) | |
tree | b14fd2737b88f90e9d142d8e6eff36876e0f8b5a /build2/cc/pkgconfig.cxx | |
parent | 8ecc2d18bf86b1021a31a2e5d01e71afbaa1efd0 (diff) |
Get rid of project_name_pool
With small string optimizations this is most likely a hindrance rather
that an optimization.
Diffstat (limited to 'build2/cc/pkgconfig.cxx')
-rw-r--r-- | build2/cc/pkgconfig.cxx | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/build2/cc/pkgconfig.cxx b/build2/cc/pkgconfig.cxx index 1b14960..f8d35af 100644 --- a/build2/cc/pkgconfig.cxx +++ b/build2/cc/pkgconfig.cxx @@ -41,7 +41,7 @@ namespace build2 lib& lt, liba* at, libs* st, - const string* proj, + const optional<string>& proj, const string& stem, const dir_path& libd, const dir_paths& sysd) const @@ -56,7 +56,7 @@ namespace build2 // names). // path f; - auto search = [&f, proj, &stem, &libd] (const dir_path& dir) -> bool + auto search = [&f, &proj, &stem, &libd] (const dir_path& dir) -> bool { // Check if we have this directory inrelative to this library's // directory. @@ -93,7 +93,7 @@ namespace build2 if (exists (f)) return true; - if (proj != nullptr) + if (proj) { f = pkgd; f /= *proj; @@ -420,7 +420,7 @@ namespace build2 const string* ext (nullptr); prerequisite_key pk { - nullptr, {&lib::static_type, &out, &out, &name, ext}, &s}; + nullopt, {&lib::static_type, &out, &out, &name, ext}, &s}; if (lib* lt = static_cast<lib*> (search_library (sysd, usrd, pk))) { |