//===----------------------------------------------------------------------===// // // The LLVM Compiler Infrastructure // // This file is dual licensed under the MIT and the University of Illinois Open // Source Licenses. See LICENSE.TXT for details. // //===----------------------------------------------------------------------===// // Adaptation to Boost of the libcxx // Copyright 2010 Vicente J. Botet Escriba // Distributed under the Boost Software License, Version 1.0. // See http://www.boost.org/LICENSE_1_0.txt #include #include #include template void check_max() { typedef typename D::rep Rep; Rep max_rep = (boost::chrono::duration_values::max)(); BOOST_TEST((D::max)().count() == max_rep); } template void check_min() { typedef typename D::rep Rep; Rep min_rep = (boost::chrono::duration_values::min)(); BOOST_TEST((D::min)().count() == min_rep); } template void check_zero() { typedef typename D::rep Rep; Rep zero_rep = boost::chrono::duration_values::zero(); BOOST_TEST(D::zero().count() == zero_rep); } int main() { check_max >(); check_max >(); check_min >(); check_min >(); check_zero >(); check_zero >(); return boost::report_errors(); }