libycxx

constructor · 4 overloads

std::chrono::duration::duration

Header
<chrono>
Scope
std::chrono::duration

Constructors

Overloads

  1. constexpr duration() = default;
    (1)
  2. duration(const duration& other) = default;
    (2)
  3. template<class Rep2, class Period2>
      requires is_convertible_v<const Rep2&, rep> && ratio-divide-valid<typename Period2::type, period> &&
                 (treat_as_floating_point_v<rep> ||
                  (ratio_divide<typename Period2::type, period>::den == 1 && !treat_as_floating_point_v<Rep2>))
    constexpr duration(const duration<Rep2, Period2>& d);
    (3)
  4. template<class Rep2>
      requires is_convertible_v<const Rep2&, rep> &&
                 (treat_as_floating_point_v<rep> || !treat_as_floating_point_v<Rep2>)
    explicit constexpr duration(const Rep2& r);
    (4)