Skip to content

Commit 041eb08

Browse files
committed
Give the optimiser a helping hand by making some coroutine_ref members const.
1 parent 2f9188d commit 041eb08

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

asio/include/asio/coroutine.hpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -328,8 +328,8 @@ class coroutine_ref
328328
private:
329329
void operator=(const coroutine_ref&);
330330
int& value_;
331-
const asio::error_code* ec_;
332-
void** async_result_;
331+
const asio::error_code* const ec_;
332+
void** const async_result_;
333333
bool modified_;
334334
};
335335

asio/include/asio/go.hpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -172,8 +172,8 @@ class basic_stackless_context
172172
detail::shared_ptr<detail::stackless_impl_base<Handler> > stackless_impl_;
173173
Handler& handler_;
174174
coroutine* coroutine_;
175-
const asio::error_code* throw_ec_;
176-
void** async_result_;
175+
const asio::error_code* const throw_ec_;
176+
void** const async_result_;
177177
asio::error_code* ec_;
178178
};
179179

0 commit comments

Comments
 (0)