libtemporal: add operator<<() for ratio_t

This commit is contained in:
Paul Davis 2020-12-27 17:44:22 -07:00
parent 209908f700
commit 78233b343f
2 changed files with 10 additions and 0 deletions

View File

@ -72,3 +72,10 @@ void Temporal::init ()
libtemporal_initialized = true;
}
}
std::ostream&
operator<< (std::ostream& o, Temporal::ratio_t const & r)
{
return o << r.numerator() << '/' << r.denominator();
}

View File

@ -125,4 +125,7 @@ extern void setup_enum_writer ();
}
std::ostream& operator<< (std::ostream& o, Temporal::ratio_t const & r);
#endif /* __libpbd_position_types_h__ */