We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 96ba1d5 commit c7776f3Copy full SHA for c7776f3
notes/techreport.pdf
4 Bytes
notes/techreport.tex
@@ -330,18 +330,18 @@ \subsection{ Programming Techniques based on dynamic channels }
330
// private part
331
case class Message(next:Channel[Message],value:T)
332
333
- select.afold(makeChannel[Message]) { (bus, s) =>
+ select.afold(makeChannel[Message](1)) { (bus, s) =>
334
s match {
335
case v: message.read =>
336
- val newBus = makeChannel[Message]
+ val newBus = makeChannel[Message](1)
337
current.write(Message(newBus,v))
338
newBus
339
case ch: listener.read =>
340
select.afold(bus) { (current,s) =>
341
342
case msg:current.read =>
343
ch.awrite(msg.value)
344
- current.awrite(msg)
+ current.write(msg)
345
msg.next
346
}
347
0 commit comments