summaryrefslogtreecommitdiff
path: root/src/mongo/util/duration.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/mongo/util/duration.h')
-rw-r--r--src/mongo/util/duration.h3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/mongo/util/duration.h b/src/mongo/util/duration.h
index 97c67ba04e4..353cb1fca9f 100644
--- a/src/mongo/util/duration.h
+++ b/src/mongo/util/duration.h
@@ -219,8 +219,7 @@ public:
typename Rep2,
stdx::enable_if_t<std::is_convertible<Rep2, rep>::value && std::is_integral<Rep2>::value,
int> = 0>
- constexpr explicit Duration(const Rep2& r)
- : _count(r) {
+ constexpr explicit Duration(const Rep2& r) : _count(r) {
static_assert(std::is_signed<Rep2>::value || sizeof(Rep2) < sizeof(rep),
"Durations must be constructed from values of integral type that are "
"representable as 64-bit signed integers");