cpp/chrono/duration/duration cast

Converts a std to a duration of different type.

The function does not participate in overload resolution unless is a specialization of std.

No implicit conversions are used. Multiplications and divisions are avoided where possible, if it is known at compile time that one or more parameters are. Computations are done in the widest type available and converted, as if by, to the result type only when finished.

Return value
converted to a duration of type.