Commit ea55f1f5 authored by Abseil Team's avatar Abseil Team Committed by Copybara-Service
Browse files

Address conversion warning by explicitly casting to size_t

Closes #3762

PiperOrigin-RevId: 428593750
Change-Id: Ifac216568fbc7d999adb71996ec6a1bbe3b97412
parent 0e402173
...@@ -45,6 +45,7 @@ ...@@ -45,6 +45,7 @@
#include <cmath> #include <cmath>
#include <cstdint> #include <cstdint>
#include <iomanip> #include <iomanip>
#include <iterator>
#include <limits> #include <limits>
#include <list> #include <list>
#include <map> #include <map>
...@@ -745,7 +746,8 @@ class UnitTestFilter { ...@@ -745,7 +746,8 @@ class UnitTestFilter {
const auto exact_match_patterns_begin = std::partition( const auto exact_match_patterns_begin = std::partition(
all_patterns.begin(), all_patterns.end(), &IsGlobPattern); all_patterns.begin(), all_patterns.end(), &IsGlobPattern);
glob_patterns_.reserve(exact_match_patterns_begin - all_patterns.begin()); glob_patterns_.reserve(static_cast<size_t>(
std::distance(all_patterns.begin(), exact_match_patterns_begin)));
std::move(all_patterns.begin(), exact_match_patterns_begin, std::move(all_patterns.begin(), exact_match_patterns_begin,
std::inserter(glob_patterns_, glob_patterns_.begin())); std::inserter(glob_patterns_, glob_patterns_.begin()));
std::move( std::move(
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment