MCPcopy Create free account
hub / github.com/catboost/catboost / operator-

Function operator-

util/datetime/base.h:691–693  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

689} // namespace NDateTimeHelpers
690
691constexpr TDuration operator-(const TInstant& l, const TInstant& r) noexcept {
692 return TDuration::FromValue(::NDateTimeHelpers::DiffWithSaturation(l.GetValue(), r.GetValue()));
693}
694
695constexpr TInstant operator+(const TInstant& i, const TDuration& d) noexcept {
696 return TInstant::FromValue(::NDateTimeHelpers::SumWithSaturation(i.GetValue(), d.GetValue()));

Callers

nothing calls this directly

Calls 3

DiffWithSaturationFunction · 0.85
TDurationClass · 0.70
GetValueMethod · 0.45

Tested by

no test coverage detected