Skip to content

Commit fce91b5

Browse files
[channel] minor doc fixes
1 parent b57d518 commit fce91b5

File tree

2 files changed

+3
-1
lines changed

2 files changed

+3
-1
lines changed

doc/reference/channel.adoc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ generator<variant2::variant<int, double>> merge(
5454
channel<double> & c2)
5555
{
5656
while (c1 && c2)
57-
co_yield co_await race(c1, c2);
57+
co_yield co_await race(c1.read(), c2.read());
5858
}
5959
----
6060

include/boost/cobalt/channel.hpp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,7 @@ struct channel
3333
{
3434
// end::outline[]
3535
#if defined(BOOST_COBALT_NO_PMR)
36+
explicit
3637
channel(std::size_t limit = 0u,
3738
executor executor = this_thread::get_executor());
3839
#else
@@ -153,6 +154,7 @@ struct channel
153154
boost::intrusive::list<read_op, intrusive::constant_time_size<false> > read_queue_;
154155
boost::intrusive::list<write_op, intrusive::constant_time_size<false> > write_queue_;
155156
public:
157+
BOOST_COBALT_MSVC_NOINLINE
156158
read_op read(const boost::source_location & loc = BOOST_CURRENT_LOCATION) {return read_op{{}, this, loc}; }
157159

158160
BOOST_COBALT_MSVC_NOINLINE

0 commit comments

Comments
 (0)