 assert_eq!(rx.recv().unwrap(), 10);
    
}</span><pre class='rust rust-example-rendered'>
<span class='kw'>use</span> <span class='ident'>std</span>::<span class='ident'>thread</span>;
<span class='kw'>use</span> <span class='ident'>std</span>::<span class='ident'>sync</span>::<span class='ident'>mpsc</span>::<span class='ident'>channel</span>;

<span class='comment'>// Create a simple streaming channel</span>
<span class='kw'>let</span> (<span class='ident'>tx</span>, <span class='ident'>rx</span>) <span 