title: Rust mpsc::Sender cannot be shared between threads?
body: <p>I thought the whole purpose of a channel was to share data between threads.  I have this code, <a href="http://rustbyexample.com/std_misc/channels.html" rel="noreferrer">based on this example</a>:</p>
  
  <pre><code>let tx_thread = tx.clone();
  let ctx = self;
  thread::spawn(|| {
      ...
      let result = ctx.method()
      tx_thread.send((String::from(result), someOtherString)).unwrap();
  })
  </code></pre>
  
  <p>Where <code>tx</code> is a <code>mpsc::Sender&lt;(String, String)&gt;</code></p>
  
  <pre class="lang-none prettyprint-override"><code>error[E0277]: the trait bound `std::sync::mpsc::Sender&lt;(std::string::String, std::string::String)&gt;: std::marker::Sync` is not satisfied
     --&gt; src/my_module/my_file.rs:137:9
      |
  137 |         thread::spawn(|| {
      |         ^^^^^^^^^^^^^
      |
      = note: `std::sync::mpsc::Sender&lt;(std::string::String, std::string::String)&gt;` cannot be shared between threads safely
      = note: required because of the requirements on the impl of `std::marker::Send` for `&amp;std::sync::mpsc::Sender&lt;(std::string::String, std::string::String)&gt;`
      = note: required because it appears within the type `[closure@src/my_module/my_file.rs:137:23: 153:10 res:&amp;&amp;str, ctx:&amp;&amp;my_module::my_submodule::Reader, tx_thread:&amp;std::sync::mpsc::Sender&lt;(std::string::String, std::string::String)&gt;]`
      = note: required by `std::thread::spawn`
  </code></pre>
  
  <p>I'm confused where I went wrong.  Unless I'm looking in the wrong place and my issue is actually my use of <code>let ctx = self;</code>?</p>