1 //===----------------------------------------------------------------------===//
2 //
3 //                     The LLVM Compiler Infrastructure
4 //
5 // This file is dual licensed under the MIT and the University of Illinois Open
6 // Source Licenses. See LICENSE.TXT for details.
7 //
8 //===----------------------------------------------------------------------===//
9 
10 // <chrono>
11 
12 // duration_values::min
13 
14 #include <chrono>
15 #include <limits>
16 #include <cassert>
17 
18 #include "../../rep.h"
19 
main()20 int main()
21 {
22     assert(std::chrono::duration_values<int>::min() ==
23            std::numeric_limits<int>::lowest());
24     assert(std::chrono::duration_values<double>::min() ==
25            std::numeric_limits<double>::lowest());
26     assert(std::chrono::duration_values<Rep>::min() ==
27            std::numeric_limits<Rep>::lowest());
28 #ifndef _LIBCPP_HAS_NO_CONSTEXPR
29     static_assert(std::chrono::duration_values<int>::min() ==
30            std::numeric_limits<int>::lowest(), "");
31     static_assert(std::chrono::duration_values<double>::min() ==
32            std::numeric_limits<double>::lowest(), "");
33     static_assert(std::chrono::duration_values<Rep>::min() ==
34            std::numeric_limits<Rep>::lowest(), "");
35 #endif
36 }
37