diff options
| author | Alexander Karatarakis <alkarata@microsoft.com> | 2017-09-01 17:08:21 -0700 |
|---|---|---|
| committer | Alexander Karatarakis <alkarata@microsoft.com> | 2017-09-01 17:08:21 -0700 |
| commit | 66eeab0015866417f4386a3822127ce7d40c49f9 (patch) | |
| tree | e17324b07fef53295531f1852ed9a396089961be /toolsrc/src/triplet.cpp | |
| parent | 2d758beea9d8068f189f79d79b4087e40d42154b (diff) | |
| download | vcpkg-66eeab0015866417f4386a3822127ce7d40c49f9.tar.gz vcpkg-66eeab0015866417f4386a3822127ce7d40c49f9.zip | |
[Triplet] Naming convention and missing const
Diffstat (limited to 'toolsrc/src/triplet.cpp')
| -rw-r--r-- | toolsrc/src/triplet.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/toolsrc/src/triplet.cpp b/toolsrc/src/triplet.cpp index 451deb040..3b56da02a 100644 --- a/toolsrc/src/triplet.cpp +++ b/toolsrc/src/triplet.cpp @@ -15,7 +15,7 @@ namespace vcpkg bool operator==(const TripletInstance& o) const { return o.value == value; } }; - const TripletInstance Triplet::default_instance({}); + const TripletInstance Triplet::DEFAULT_INSTANCE({}); } template<> @@ -41,10 +41,10 @@ namespace vcpkg Triplet Triplet::from_canonical_name(const std::string& triplet_as_string) { std::string s(Strings::ascii_to_lowercase(triplet_as_string)); - auto it = std::find(s.cbegin(), s.cend(), '-'); + const auto it = std::find(s.cbegin(), s.cend(), '-'); Checks::check_exit(VCPKG_LINE_INFO, it != s.cend(), "Invalid triplet: %s", triplet_as_string); - auto p = g_triplet_instances.emplace(std::move(s)); + const auto p = g_triplet_instances.emplace(std::move(s)); return &*p.first; } |
