diff options
author | Nat Goodspeed <nat@lindenlab.com> | 2009-06-04 16:01:40 +0000 |
---|---|---|
committer | Nat Goodspeed <nat@lindenlab.com> | 2009-06-04 16:01:40 +0000 |
commit | 820d4a20d1b9c9a3e562b925ba59a6addcffa558 (patch) | |
tree | 5eb6e1cfb95d408cfabfafd6cd5ddb1e6d4a507e /indra/viewer_components | |
parent | a3d54c48c6366a8a38e20a5aacd90bbc39018512 (diff) |
DEV-32777: Use a canonical boost::coroutines::coroutine signature, relying on
boost::bind() to pass any other coroutine arguments. This allows us to remove
the LLCoroBase and LLCoro constructs, directly storing a coroutine object in
our ptr_map. It also allows us to remove the multiple launch() overloads for
multiple arguments. Finally, it lets us move most launch() functionality into
a non-template method.
Diffstat (limited to 'indra/viewer_components')
-rw-r--r-- | indra/viewer_components/login/lllogin.cpp | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/indra/viewer_components/login/lllogin.cpp b/indra/viewer_components/login/lllogin.cpp index 92384a1c5b..c0d35f31d3 100644 --- a/indra/viewer_components/login/lllogin.cpp +++ b/indra/viewer_components/login/lllogin.cpp @@ -105,12 +105,10 @@ private: return response; } - typedef boost::coroutines::coroutine<void(std::string, LLSD)> coroutine_type; - // In a coroutine's top-level function args, do NOT NOT NOT accept // references (const or otherwise) to anything but the self argument! Pass // by value only! - void login_(coroutine_type::self& self, std::string uri, LLSD credentials); + void login_(LLCoros::self& self, std::string uri, LLSD credentials); LLEventStream mPump; LLSD mAuthResponse, mValidAuthResponse; @@ -121,11 +119,11 @@ void LLLogin::Impl::connect(const std::string& uri, const LLSD& credentials) // Launch a coroutine with our login_() method. Run the coroutine until // its first wait; at that point, return here. std::string coroname = - LLCoros::instance().launch<coroutine_type>("LLLogin::Impl::login_", - boost::bind(&Impl::login_, this, _1, uri, credentials)); + LLCoros::instance().launch("LLLogin::Impl::login_", + boost::bind(&Impl::login_, this, _1, uri, credentials)); } -void LLLogin::Impl::login_(coroutine_type::self& self, std::string uri, LLSD credentials) +void LLLogin::Impl::login_(LLCoros::self& self, std::string uri, LLSD credentials) { LL_INFOS("LLLogin") << "Entering coroutine " << LLCoros::instance().getName(self) << " with uri '" << uri << "', credentials " << credentials << LL_ENDL; |