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

Method AddAndOwn

util/thread/pool.cpp:686–693  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

684}
685
686bool IThreadPool::AddAndOwn(THolder<IObjectInQueue> obj) {
687 auto owner = MakeHolder<TOwnedObjectInQueue>(std::move(obj));
688 bool added = Add(owner.Get());
689 if (added) {
690 Y_UNUSED(owner.Release());
691 }
692 return added;
693}
694
695using IThread = IThreadFactory::IThread;
696using IThreadAble = IThreadFactory::IThreadAble;

Callers

nothing calls this directly

Calls 5

Y_UNUSEDFunction · 0.85
moveFunction · 0.50
AddFunction · 0.50
GetMethod · 0.45
ReleaseMethod · 0.45

Tested by

no test coverage detected