]> git.apps.os.sepia.ceph.com Git - ceph.git/commit
common/ceph_time: add operator<< for signedspan
authorKefu Chai <kchai@redhat.com>
Thu, 7 Jan 2021 03:56:25 +0000 (11:56 +0800)
committerKefu Chai <kchai@redhat.com>
Fri, 8 Jan 2021 05:57:18 +0000 (13:57 +0800)
commita64b96dba14df1e61ee6eb449535a6ff4a9d64b3
tree5e1992603d1f014e7951024f6b73f791cc5ba914
parent75aafcba888a5753d2a4a8378637b4bb9fad5dd0
common/ceph_time: add operator<< for signedspan

* templatize operator<<(ostream&, duration<>), so it works for more
  duration<> classes with minimal efforts -- we just need to explicitly
  instantiate these template operators
* explicitly instantiate operator<< for timespan, signedspan, seconds
  and milliseconds. they are most likely to be used in Ceph. we can add
  more of them when necessary.

Signed-off-by: Kefu Chai <kchai@redhat.com>
src/common/ceph_time.cc
src/common/ceph_time.h