Home
last modified time | relevance | path

Searched refs:chrono (Results 1 – 25 of 1705) sorted by relevance

12345678910>>...69

/external/llvm-project/libcxx/test/std/utilities/time/time.cal/time.cal.month/time.cal.month.nonmembers/
Dliterals.pass.cpp35 ASSERT_SAME_TYPE(const std::chrono::month, decltype(std::chrono::January)); in main()
36 ASSERT_SAME_TYPE(const std::chrono::month, decltype(std::chrono::February)); in main()
37 ASSERT_SAME_TYPE(const std::chrono::month, decltype(std::chrono::March)); in main()
38 ASSERT_SAME_TYPE(const std::chrono::month, decltype(std::chrono::April)); in main()
39 ASSERT_SAME_TYPE(const std::chrono::month, decltype(std::chrono::May)); in main()
40 ASSERT_SAME_TYPE(const std::chrono::month, decltype(std::chrono::June)); in main()
41 ASSERT_SAME_TYPE(const std::chrono::month, decltype(std::chrono::July)); in main()
42 ASSERT_SAME_TYPE(const std::chrono::month, decltype(std::chrono::August)); in main()
43 ASSERT_SAME_TYPE(const std::chrono::month, decltype(std::chrono::September)); in main()
44 ASSERT_SAME_TYPE(const std::chrono::month, decltype(std::chrono::October)); in main()
[all …]
/external/libcxx/test/std/utilities/time/time.cal/time.cal.month/time.cal.month.nonmembers/
Dliterals.pass.cpp36 ASSERT_SAME_TYPE(const std::chrono::month, decltype(std::chrono::January)); in main()
37 ASSERT_SAME_TYPE(const std::chrono::month, decltype(std::chrono::February)); in main()
38 ASSERT_SAME_TYPE(const std::chrono::month, decltype(std::chrono::March)); in main()
39 ASSERT_SAME_TYPE(const std::chrono::month, decltype(std::chrono::April)); in main()
40 ASSERT_SAME_TYPE(const std::chrono::month, decltype(std::chrono::May)); in main()
41 ASSERT_SAME_TYPE(const std::chrono::month, decltype(std::chrono::June)); in main()
42 ASSERT_SAME_TYPE(const std::chrono::month, decltype(std::chrono::July)); in main()
43 ASSERT_SAME_TYPE(const std::chrono::month, decltype(std::chrono::August)); in main()
44 ASSERT_SAME_TYPE(const std::chrono::month, decltype(std::chrono::September)); in main()
45 ASSERT_SAME_TYPE(const std::chrono::month, decltype(std::chrono::October)); in main()
[all …]
/external/libcxx/test/std/utilities/time/time.cal/time.cal.weekday/time.cal.weekday.nonmembers/
Dliterals.pass.cpp31 ASSERT_SAME_TYPE(const std::chrono::weekday, decltype(std::chrono::Sunday)); in main()
32 ASSERT_SAME_TYPE(const std::chrono::weekday, decltype(std::chrono::Monday)); in main()
33 ASSERT_SAME_TYPE(const std::chrono::weekday, decltype(std::chrono::Tuesday)); in main()
34 ASSERT_SAME_TYPE(const std::chrono::weekday, decltype(std::chrono::Wednesday)); in main()
35 ASSERT_SAME_TYPE(const std::chrono::weekday, decltype(std::chrono::Thursday)); in main()
36 ASSERT_SAME_TYPE(const std::chrono::weekday, decltype(std::chrono::Friday)); in main()
37 ASSERT_SAME_TYPE(const std::chrono::weekday, decltype(std::chrono::Saturday)); in main()
39 static_assert( std::chrono::Sunday == std::chrono::weekday(0), ""); in main()
40 static_assert( std::chrono::Monday == std::chrono::weekday(1), ""); in main()
41 static_assert( std::chrono::Tuesday == std::chrono::weekday(2), ""); in main()
[all …]
/external/llvm-project/libcxx/test/std/utilities/time/time.cal/time.cal.weekday/time.cal.weekday.nonmembers/
Dliterals.pass.cpp30 ASSERT_SAME_TYPE(const std::chrono::weekday, decltype(std::chrono::Sunday)); in main()
31 ASSERT_SAME_TYPE(const std::chrono::weekday, decltype(std::chrono::Monday)); in main()
32 ASSERT_SAME_TYPE(const std::chrono::weekday, decltype(std::chrono::Tuesday)); in main()
33 ASSERT_SAME_TYPE(const std::chrono::weekday, decltype(std::chrono::Wednesday)); in main()
34 ASSERT_SAME_TYPE(const std::chrono::weekday, decltype(std::chrono::Thursday)); in main()
35 ASSERT_SAME_TYPE(const std::chrono::weekday, decltype(std::chrono::Friday)); in main()
36 ASSERT_SAME_TYPE(const std::chrono::weekday, decltype(std::chrono::Saturday)); in main()
38 static_assert( std::chrono::Sunday == std::chrono::weekday(0), ""); in main()
39 static_assert( std::chrono::Monday == std::chrono::weekday(1), ""); in main()
40 static_assert( std::chrono::Tuesday == std::chrono::weekday(2), ""); in main()
[all …]
/external/llvm-project/libcxx/test/std/utilities/time/time.point/time.point.cast/
Dtime_point_cast.pass.cpp27 typedef std::chrono::system_clock Clock; in test()
28 typedef std::chrono::time_point<Clock, FromDuration> FromTimePoint; in test()
29 typedef std::chrono::time_point<Clock, ToDuration> ToTimePoint; in test()
33 typedef decltype(std::chrono::time_point_cast<ToDuration>(f)) R; in test()
35 assert(std::chrono::time_point_cast<ToDuration>(f) == t); in test()
44 typedef std::chrono::system_clock Clock; in test_constexpr()
45 typedef std::chrono::time_point<Clock, FromDuration> FromTimePoint; in test_constexpr()
46 typedef std::chrono::time_point<Clock, ToDuration> ToTimePoint; in test_constexpr()
50 static_assert(std::chrono::time_point_cast<ToDuration>(f) == t, ""); in test_constexpr()
59 test(std::chrono::milliseconds(7265000), std::chrono::hours(2)); in main()
[all …]
Dfloor.pass.cpp28 typedef std::chrono::system_clock Clock; in test()
29 typedef std::chrono::time_point<Clock, FromDuration> FromTimePoint; in test()
30 typedef std::chrono::time_point<Clock, ToDuration> ToTimePoint; in test()
34 typedef decltype(std::chrono::floor<ToDuration>(f)) R; in test()
36 assert(std::chrono::floor<ToDuration>(f) == t); in test()
43 typedef std::chrono::system_clock Clock; in test_constexpr()
44 typedef std::chrono::time_point<Clock, FromDuration> FromTimePoint; in test_constexpr()
45 typedef std::chrono::time_point<Clock, ToDuration> ToTimePoint; in test_constexpr()
49 static_assert(std::chrono::floor<ToDuration>(f) == t, ""); in test_constexpr()
56 test(std::chrono::milliseconds( 7290000), std::chrono::hours( 2)); in main()
[all …]
Dceil.pass.cpp28 typedef std::chrono::system_clock Clock; in test()
29 typedef std::chrono::time_point<Clock, FromDuration> FromTimePoint; in test()
30 typedef std::chrono::time_point<Clock, ToDuration> ToTimePoint; in test()
34 typedef decltype(std::chrono::ceil<ToDuration>(f)) R; in test()
36 assert(std::chrono::ceil<ToDuration>(f) == t); in test()
43 typedef std::chrono::system_clock Clock; in test_constexpr()
44 typedef std::chrono::time_point<Clock, FromDuration> FromTimePoint; in test_constexpr()
45 typedef std::chrono::time_point<Clock, ToDuration> ToTimePoint; in test_constexpr()
49 static_assert(std::chrono::ceil<ToDuration>(f) == t, ""); in test_constexpr()
57 test(std::chrono::milliseconds( 7290000), std::chrono::hours( 3)); in main()
[all …]
Dround.pass.cpp28 typedef std::chrono::system_clock Clock; in test()
29 typedef std::chrono::time_point<Clock, FromDuration> FromTimePoint; in test()
30 typedef std::chrono::time_point<Clock, ToDuration> ToTimePoint; in test()
34 typedef decltype(std::chrono::round<ToDuration>(f)) R; in test()
36 assert(std::chrono::round<ToDuration>(f) == t); in test()
43 typedef std::chrono::system_clock Clock; in test_constexpr()
44 typedef std::chrono::time_point<Clock, FromDuration> FromTimePoint; in test_constexpr()
45 typedef std::chrono::time_point<Clock, ToDuration> ToTimePoint; in test_constexpr()
49 static_assert(std::chrono::round<ToDuration>(f) == t, ""); in test_constexpr()
56 test(std::chrono::milliseconds( 7290000), std::chrono::hours( 2)); in main()
[all …]
/external/libcxx/test/std/utilities/time/time.point/time.point.cast/
Dtime_point_cast.pass.cpp28 typedef std::chrono::system_clock Clock; in test()
29 typedef std::chrono::time_point<Clock, FromDuration> FromTimePoint; in test()
30 typedef std::chrono::time_point<Clock, ToDuration> ToTimePoint; in test()
34 typedef decltype(std::chrono::time_point_cast<ToDuration>(f)) R; in test()
36 assert(std::chrono::time_point_cast<ToDuration>(f) == t); in test()
45 typedef std::chrono::system_clock Clock; in test_constexpr()
46 typedef std::chrono::time_point<Clock, FromDuration> FromTimePoint; in test_constexpr()
47 typedef std::chrono::time_point<Clock, ToDuration> ToTimePoint; in test_constexpr()
51 static_assert(std::chrono::time_point_cast<ToDuration>(f) == t, ""); in test_constexpr()
60 test(std::chrono::milliseconds(7265000), std::chrono::hours(2)); in main()
[all …]
Dfloor.pass.cpp27 typedef std::chrono::system_clock Clock; in test()
28 typedef std::chrono::time_point<Clock, FromDuration> FromTimePoint; in test()
29 typedef std::chrono::time_point<Clock, ToDuration> ToTimePoint; in test()
33 typedef decltype(std::chrono::floor<ToDuration>(f)) R; in test()
35 assert(std::chrono::floor<ToDuration>(f) == t); in test()
42 typedef std::chrono::system_clock Clock; in test_constexpr()
43 typedef std::chrono::time_point<Clock, FromDuration> FromTimePoint; in test_constexpr()
44 typedef std::chrono::time_point<Clock, ToDuration> ToTimePoint; in test_constexpr()
48 static_assert(std::chrono::floor<ToDuration>(f) == t, ""); in test_constexpr()
55 test(std::chrono::milliseconds( 7290000), std::chrono::hours( 2)); in main()
[all …]
Dround.pass.cpp27 typedef std::chrono::system_clock Clock; in test()
28 typedef std::chrono::time_point<Clock, FromDuration> FromTimePoint; in test()
29 typedef std::chrono::time_point<Clock, ToDuration> ToTimePoint; in test()
33 typedef decltype(std::chrono::round<ToDuration>(f)) R; in test()
35 assert(std::chrono::round<ToDuration>(f) == t); in test()
42 typedef std::chrono::system_clock Clock; in test_constexpr()
43 typedef std::chrono::time_point<Clock, FromDuration> FromTimePoint; in test_constexpr()
44 typedef std::chrono::time_point<Clock, ToDuration> ToTimePoint; in test_constexpr()
48 static_assert(std::chrono::round<ToDuration>(f) == t, ""); in test_constexpr()
55 test(std::chrono::milliseconds( 7290000), std::chrono::hours( 2)); in main()
[all …]
Dceil.pass.cpp27 typedef std::chrono::system_clock Clock; in test()
28 typedef std::chrono::time_point<Clock, FromDuration> FromTimePoint; in test()
29 typedef std::chrono::time_point<Clock, ToDuration> ToTimePoint; in test()
33 typedef decltype(std::chrono::ceil<ToDuration>(f)) R; in test()
35 assert(std::chrono::ceil<ToDuration>(f) == t); in test()
42 typedef std::chrono::system_clock Clock; in test_constexpr()
43 typedef std::chrono::time_point<Clock, FromDuration> FromTimePoint; in test_constexpr()
44 typedef std::chrono::time_point<Clock, ToDuration> ToTimePoint; in test_constexpr()
48 static_assert(std::chrono::ceil<ToDuration>(f) == t, ""); in test_constexpr()
56 test(std::chrono::milliseconds( 7290000), std::chrono::hours( 3)); in main()
[all …]
/external/fmtlib/test/
Dchrono-test.cc99 std::chrono::system_clock::time_point point = std::chrono::system_clock::now(); in TEST()
101 std::time_t t = std::chrono::system_clock::to_time_t(point); in TEST()
119 EXPECT_EQ("42s", fmt::format("{}", std::chrono::seconds(42))); in TEST()
121 fmt::format("{}", std::chrono::duration<int, std::atto>(42))); in TEST()
123 fmt::format("{}", std::chrono::duration<int, std::femto>(42))); in TEST()
125 fmt::format("{}", std::chrono::duration<int, std::pico>(42))); in TEST()
126 EXPECT_EQ("42ns", fmt::format("{}", std::chrono::nanoseconds(42))); in TEST()
127 EXPECT_EQ("42µs", fmt::format("{}", std::chrono::microseconds(42))); in TEST()
128 EXPECT_EQ("42ms", fmt::format("{}", std::chrono::milliseconds(42))); in TEST()
130 fmt::format("{}", std::chrono::duration<int, std::centi>(42))); in TEST()
[all …]
/external/python/pybind11/tests/
Dtest_chrono.cpp16 using time_point_h = std::chrono::time_point<
17 std::chrono::system_clock, std::chrono::hours>;
18 using time_point_m = std::chrono::time_point<
19 std::chrono::system_clock, std::chrono::minutes>;
20 using time_point_s = std::chrono::time_point<
21 std::chrono::system_clock, std::chrono::seconds>;
22 using time_point_ms = std::chrono::time_point<
23 std::chrono::system_clock, std::chrono::milliseconds>;
24 using time_point_us = std::chrono::time_point<
25 std::chrono::system_clock, std::chrono::microseconds>;
[all …]
/external/libcxx/test/std/utilities/time/time.duration/time.duration.cast/
Dduration_cast.pass.cpp30 typedef decltype(std::chrono::duration_cast<ToDuration>(f)) R; in test()
32 assert(std::chrono::duration_cast<ToDuration>(f) == d); in test()
38 test(std::chrono::milliseconds(7265000), std::chrono::hours(2)); in main()
39 test(std::chrono::milliseconds(7265000), std::chrono::minutes(121)); in main()
40 test(std::chrono::milliseconds(7265000), std::chrono::seconds(7265)); in main()
41 test(std::chrono::milliseconds(7265000), std::chrono::milliseconds(7265000)); in main()
42 test(std::chrono::milliseconds(7265000), std::chrono::microseconds(7265000000LL)); in main()
43 test(std::chrono::milliseconds(7265000), std::chrono::nanoseconds(7265000000000LL)); in main()
44 test(std::chrono::milliseconds(7265000), in main()
45 std::chrono::duration<double, std::ratio<3600> >(7265./3600)); in main()
[all …]
/external/llvm-project/libcxx/test/std/utilities/time/time.duration/time.duration.cast/
Dduration_cast.pass.cpp29 typedef decltype(std::chrono::duration_cast<ToDuration>(f)) R; in test()
31 assert(std::chrono::duration_cast<ToDuration>(f) == d); in test()
37 test(std::chrono::milliseconds(7265000), std::chrono::hours(2)); in main()
38 test(std::chrono::milliseconds(7265000), std::chrono::minutes(121)); in main()
39 test(std::chrono::milliseconds(7265000), std::chrono::seconds(7265)); in main()
40 test(std::chrono::milliseconds(7265000), std::chrono::milliseconds(7265000)); in main()
41 test(std::chrono::milliseconds(7265000), std::chrono::microseconds(7265000000LL)); in main()
42 test(std::chrono::milliseconds(7265000), std::chrono::nanoseconds(7265000000000LL)); in main()
43 test(std::chrono::milliseconds(7265000), in main()
44 std::chrono::duration<double, std::ratio<3600> >(7265./3600)); in main()
[all …]
/external/llvm-project/libcxx/test/std/utilities/time/time.cal/time.cal.ymwd/time.cal.ymwd.nonmembers/
Dminus.pass.cpp29 …std::chrono::year_month_weekday ym0{std::chrono::year{1234}, std::chrono::January, std::chrono::we… in testConstexprYears()
30 std::chrono::year_month_weekday ym1 = ym0 - std::chrono::years{10}; in testConstexprYears()
32 ym1.year() == std::chrono::year{1234-10} in testConstexprYears()
33 && ym1.month() == std::chrono::January in testConstexprYears()
34 && ym1.weekday() == std::chrono::Tuesday in testConstexprYears()
41 …std::chrono::year_month_weekday ym0{std::chrono::year{1234}, std::chrono::November, std::chrono::w… in testConstexprMonths()
42 std::chrono::year_month_weekday ym1 = ym0 - std::chrono::months{6}; in testConstexprMonths()
44 ym1.year() == std::chrono::year{1234} in testConstexprMonths()
45 && ym1.month() == std::chrono::May in testConstexprMonths()
46 && ym1.weekday() == std::chrono::Tuesday in testConstexprMonths()
[all …]
/external/libcxx/test/std/utilities/time/time.cal/time.cal.ymwd/time.cal.ymwd.nonmembers/
Dminus.pass.cpp31 …std::chrono::year_month_weekday ym0{std::chrono::year{1234}, std::chrono::January, std::chrono::we… in testConstexprYears()
32 std::chrono::year_month_weekday ym1 = ym0 - std::chrono::years{10}; in testConstexprYears()
34 ym1.year() == std::chrono::year{1234-10} in testConstexprYears()
35 && ym1.month() == std::chrono::January in testConstexprYears()
36 && ym1.weekday() == std::chrono::Tuesday in testConstexprYears()
43 …std::chrono::year_month_weekday ym0{std::chrono::year{1234}, std::chrono::November, std::chrono::w… in testConstexprMonths()
44 std::chrono::year_month_weekday ym1 = ym0 - std::chrono::months{6}; in testConstexprMonths()
46 ym1.year() == std::chrono::year{1234} in testConstexprMonths()
47 && ym1.month() == std::chrono::May in testConstexprMonths()
48 && ym1.weekday() == std::chrono::Tuesday in testConstexprMonths()
[all …]
/external/llvm-project/libcxx/test/std/utilities/time/time.duration/time.duration.alg/
Dabs.pass.cpp29 typedef decltype(std::chrono::abs(f)) R; in test()
31 assert(std::chrono::abs(f) == d); in test()
38 test(std::chrono::milliseconds( 7290000), std::chrono::milliseconds( 7290000)); in main()
39 test(std::chrono::milliseconds(-7290000), std::chrono::milliseconds( 7290000)); in main()
40 test(std::chrono::minutes( 122), std::chrono::minutes( 122)); in main()
41 test(std::chrono::minutes(-122), std::chrono::minutes( 122)); in main()
42 test(std::chrono::hours(0), std::chrono::hours(0)); in main()
46 constexpr std::chrono::hours h1 = std::chrono::abs(std::chrono::hours(-3)); in main()
48 constexpr std::chrono::hours h2 = std::chrono::abs(std::chrono::hours(3)); in main()
54 constexpr auto d = std::chrono::abs(std::chrono::duration<int, std::ratio<60, 100>>{2}); in main()
/external/llvm-project/libcxx/test/std/utilities/time/time.duration/time.duration.comparisons/
Dop_equal.pass.cpp31 std::chrono::seconds s1(3); in main()
32 std::chrono::seconds s2(3); in main()
37 std::chrono::seconds s1(3); in main()
38 std::chrono::seconds s2(4); in main()
43 std::chrono::milliseconds s1(3); in main()
44 std::chrono::microseconds s2(3000); in main()
49 std::chrono::milliseconds s1(3); in main()
50 std::chrono::microseconds s2(4000); in main()
55 std::chrono::duration<int, std::ratio<2, 3> > s1(9); in main()
56 std::chrono::duration<int, std::ratio<3, 5> > s2(10); in main()
[all …]
/external/libcxx/test/std/utilities/time/time.duration/time.duration.comparisons/
Dop_equal.pass.cpp32 std::chrono::seconds s1(3); in main()
33 std::chrono::seconds s2(3); in main()
38 std::chrono::seconds s1(3); in main()
39 std::chrono::seconds s2(4); in main()
44 std::chrono::milliseconds s1(3); in main()
45 std::chrono::microseconds s2(3000); in main()
50 std::chrono::milliseconds s1(3); in main()
51 std::chrono::microseconds s2(4000); in main()
56 std::chrono::duration<int, std::ratio<2, 3> > s1(9); in main()
57 std::chrono::duration<int, std::ratio<3, 5> > s2(10); in main()
[all …]
/external/libcxx/test/std/utilities/time/time.duration/time.duration.nonmember/
Dop_-.pass.cpp27 std::chrono::seconds s1(3); in main()
28 std::chrono::seconds s2(5); in main()
29 std::chrono::seconds r = s1 - s2; in main()
33 std::chrono::seconds s1(3); in main()
34 std::chrono::microseconds s2(5); in main()
35 std::chrono::microseconds r = s1 - s2; in main()
39 std::chrono::duration<int, std::ratio<2, 3> > s1(3); in main()
40 std::chrono::duration<int, std::ratio<3, 5> > s2(5); in main()
41 std::chrono::duration<int, std::ratio<1, 15> > r = s1 - s2; in main()
45 std::chrono::duration<int, std::ratio<2, 3> > s1(3); in main()
[all …]
Dop_+.pass.cpp26 std::chrono::seconds s1(3); in main()
27 std::chrono::seconds s2(5); in main()
28 std::chrono::seconds r = s1 + s2; in main()
32 std::chrono::seconds s1(3); in main()
33 std::chrono::microseconds s2(5); in main()
34 std::chrono::microseconds r = s1 + s2; in main()
38 std::chrono::duration<int, std::ratio<2, 3> > s1(3); in main()
39 std::chrono::duration<int, std::ratio<3, 5> > s2(5); in main()
40 std::chrono::duration<int, std::ratio<1, 15> > r = s1 + s2; in main()
44 std::chrono::duration<int, std::ratio<2, 3> > s1(3); in main()
[all …]
/external/llvm-project/libcxx/test/std/utilities/time/time.duration/time.duration.nonmember/
Dop_-.pass.cpp26 std::chrono::seconds s1(3); in main()
27 std::chrono::seconds s2(5); in main()
28 std::chrono::seconds r = s1 - s2; in main()
32 std::chrono::seconds s1(3); in main()
33 std::chrono::microseconds s2(5); in main()
34 std::chrono::microseconds r = s1 - s2; in main()
38 std::chrono::duration<int, std::ratio<2, 3> > s1(3); in main()
39 std::chrono::duration<int, std::ratio<3, 5> > s2(5); in main()
40 std::chrono::duration<int, std::ratio<1, 15> > r = s1 - s2; in main()
44 std::chrono::duration<int, std::ratio<2, 3> > s1(3); in main()
[all …]
Dop_+.pass.cpp25 std::chrono::seconds s1(3); in main()
26 std::chrono::seconds s2(5); in main()
27 std::chrono::seconds r = s1 + s2; in main()
31 std::chrono::seconds s1(3); in main()
32 std::chrono::microseconds s2(5); in main()
33 std::chrono::microseconds r = s1 + s2; in main()
37 std::chrono::duration<int, std::ratio<2, 3> > s1(3); in main()
38 std::chrono::duration<int, std::ratio<3, 5> > s2(5); in main()
39 std::chrono::duration<int, std::ratio<1, 15> > r = s1 + s2; in main()
43 std::chrono::duration<int, std::ratio<2, 3> > s1(3); in main()
[all …]

12345678910>>...69