blob: 413d8cd6f697c575b7391299d387882646ad8309 [file] [log] [blame]
Howard Hinnant94b2dd02010-08-22 00:59:46 +00001//===----------------------------------------------------------------------===//
2//
Chandler Carruth57b08b02019-01-19 10:56:40 +00003// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4// See https://llvm.org/LICENSE.txt for license information.
5// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
Howard Hinnant94b2dd02010-08-22 00:59:46 +00006//
7//===----------------------------------------------------------------------===//
8
9// <chrono>
10
11// typedef duration<signed integral type of at least 29 bits, ratio< 60>> minutes;
12
13#include <chrono>
14#include <type_traits>
15#include <limits>
16
17int main()
18{
19 typedef std::chrono::minutes D;
20 typedef D::rep Rep;
21 typedef D::period Period;
22 static_assert(std::is_signed<Rep>::value, "");
23 static_assert(std::is_integral<Rep>::value, "");
24 static_assert(std::numeric_limits<Rep>::digits >= 28, "");
25 static_assert((std::is_same<Period, std::ratio<60> >::value), "");
26}