MCPcopy Create free account
hub / github.com/catboost/catboost / AndThen

Method AndThen

util/generic/maybe.h:437–445  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

435
436 template <typename F>
437 constexpr auto AndThen(F&& func) & {
438 using ReturnType = TCallResult<F, T&>;
439
440 if (Defined()) {
441 return std::forward<F>(CheckReturnsMaybe<T&>(func))(*Data());
442 }
443
444 return ReturnType{};
445 }
446
447 template <typename F>
448 constexpr auto AndThen(F&& func) const& {

Callers 1

Y_UNIT_TESTFunction · 0.80

Calls 2

DataClass · 0.70
moveFunction · 0.50

Tested by

no test coverage detected