From 22d0e57fa40fdc1a81eb5f419aea3e039bb76bb0 Mon Sep 17 00:00:00 2001 From: Henning Baldersheim Date: Tue, 9 Oct 2018 09:36:23 +0000 Subject: Use assignment to avoid gcc 8 ambiguity. --- metrics/src/vespa/metrics/metricset.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/metrics/src/vespa/metrics/metricset.cpp b/metrics/src/vespa/metrics/metricset.cpp index a8e22c8dfc4..9fb731d7583 100644 --- a/metrics/src/vespa/metrics/metricset.cpp +++ b/metrics/src/vespa/metrics/metricset.cpp @@ -254,7 +254,7 @@ MetricSet::addTo(Metric& other, std::vector *ownerList) const std::vector newOrder; newOrder.reserve(o._metricOrder.size() + newMetrics.size()); for (const Metric* metric : _metricOrder) { - TmpString v(metric->getMangledName()); + TmpString v = metric->getMangledName(); target = std::lower_bound(map2.begin(), map2.end(), v); if ((target != map2.end()) && (target->first == v)) { newOrder.push_back(target->second); @@ -267,7 +267,7 @@ MetricSet::addTo(Metric& other, std::vector *ownerList) const } // If target had unique metrics, add them at the end for (Metric* metric : o._metricOrder) { - TmpString v(metric->getMangledName()); + TmpString v = metric->getMangledName(); if ( ! std::binary_search(map1.begin(), map1.end(), v) ) { LOG(debug, "Metric %s exist in one snapshot but not other." "Order will be messed up. Adding target unique " -- cgit v1.2.3