mirror of
https://github.com/catchorg/Catch2.git
synced 2024-11-22 05:16:10 +01:00
Make operator BenchmarkStats<Duration2> explicit
This commit is contained in:
parent
96790b1d23
commit
f9ec34ce01
@ -950,7 +950,7 @@ namespace Catch {
|
|||||||
#include <iosfwd>
|
#include <iosfwd>
|
||||||
|
|
||||||
namespace Catch {
|
namespace Catch {
|
||||||
|
|
||||||
struct ITransientExpression;
|
struct ITransientExpression;
|
||||||
|
|
||||||
class LazyExpression {
|
class LazyExpression {
|
||||||
@ -1430,7 +1430,7 @@ namespace Catch {
|
|||||||
double outlierVariance;
|
double outlierVariance;
|
||||||
|
|
||||||
template <typename Duration2>
|
template <typename Duration2>
|
||||||
operator BenchmarkStats<Duration2>() const {
|
explicit operator BenchmarkStats<Duration2>() const {
|
||||||
std::vector<Duration2> samples2;
|
std::vector<Duration2> samples2;
|
||||||
samples2.reserve(samples.size());
|
samples2.reserve(samples.size());
|
||||||
for (auto const& sample : samples) {
|
for (auto const& sample : samples) {
|
||||||
@ -2575,7 +2575,7 @@ namespace Catch {
|
|||||||
analysis.outlier_variance,
|
analysis.outlier_variance,
|
||||||
};
|
};
|
||||||
} else {
|
} else {
|
||||||
std::vector<Duration> samples;
|
std::vector<Duration> samples;
|
||||||
samples.reserve(last - first);
|
samples.reserve(last - first);
|
||||||
|
|
||||||
Duration mean = Duration(0);
|
Duration mean = Duration(0);
|
||||||
|
Loading…
Reference in New Issue
Block a user