This commit is contained in:
aozhiwei 2023-05-18 22:51:09 +08:00
parent a3c22feb24
commit 2ddbc831ec
2 changed files with 2 additions and 2 deletions

View File

@ -24,7 +24,7 @@ void CoMgr::Update()
} }
} }
std::weak_ptr<Coroutine> CoMgr::CreateCoroutine(std::function<void(Coroutine*)> cb) std::weak_ptr<Coroutine> CoMgr::CreateCo(std::function<void(Coroutine*)> cb)
{ {
auto co = std::make_shared<Coroutine>(cb); auto co = std::make_shared<Coroutine>(cb);
co->hold_self_ = co; co->hold_self_ = co;

View File

@ -16,7 +16,7 @@ class CoMgr : public a8::Singleton<CoMgr>
void UnInit(); void UnInit();
void Update(); void Update();
std::weak_ptr<Coroutine> CreateCoroutine(std::function<void(Coroutine*)> cb); std::weak_ptr<Coroutine> CreateCo(std::function<void(Coroutine*)> cb);
private: private: