<p dir="auto">There are three impls in int-template.rs and uint-template.rs that apply to all numeric types. Until recently, if you tried to do this:</p>
<div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="import int::num;
import i8::num;"><pre class="notranslate"><code class="notranslate">import int::num;
import i8::num;
</code></pre></div>
<p dir="auto">you'd receive "error: duplicate definition of type num". <a class="commit-link" data-hovercard-type="commit" data-hovercard-url="https://github.com/rust-lang/rust/commit/d14d4155dead7a18b2d5b8dcac1dd7311a26900a/hovercard" href="https://github.com/rust-lang/rust/commit/d14d4155dead7a18b2d5b8dcac1dd7311a26900a"><tt>d14d415</tt></a> fixed this for the particular case of the <code class="notranslate">num</code> impl, but trying to duplicate the process for the <code class="notranslate">eq</code> and <code class="notranslate">ord</code> impls gives weird errors in libstd/sort.rs that I'm hoping the resolve rewrite will, er, resolve. It won't be possible to automatically export the <code class="notranslate">eq</code> and <code class="notranslate">ord</code> impls on numeric types until this is fixed.</p>
<p dir="auto">I attempted to compile this code:</p>
<div class="highlight highlight-source-rust notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="pub fn set_game_state&lt;T: GameState&gt;(&amp;mut self, state: ~T) {
  self.state = state;
}"><pre class="notranslate"><span class="pl-k">pub</span> <span class="pl-k">fn</span> <span class="pl-en">set_game_state</span><span class="pl-kos">&lt;</span><span class="pl-smi">T</span><span class="pl-kos">:</span> <span class="pl-smi">GameState</span><span class="pl-kos">&gt;</span><span class="pl-kos">(</span><span class="pl-c1">&amp;</span><span class="pl-k">mut</span> <span class="pl-smi">self</span><span class="pl-kos">,</span> <span class="pl-s1">state</span><span class="pl-kos">:</span> ~<span class="pl-smi">T</span><span class="pl-kos">)</span> <span class="pl-kos">{</span>
  <span class="pl-smi">self</span><span class="pl-kos">.</span><span class="pl-c1">state</span> = state<span class="pl-kos">;</span>
<span class="pl-kos">}</span></pre></div>
<p dir="auto">It gave me the error:</p>
<div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="src/game_window.rs:37:18: 37:23 error: mismatched types: expected `~game_state::GameState:Send` but found `~T` (expected trait game_state::GameState but found ~-ptr)
src/game_window.rs:37     self.state = state;"><pre class="notranslate"><code class="notranslate">src/game_window.rs:37:18: 37:23 error: mismatched types: expected `~game_state::GameState:Send` but found `~T` (expected trait game_state::GameState but found ~-ptr)
src/game_window.rs:37     self.state = state;
</code></pre></div>
<p dir="auto">The following code did compile:</p>
<div class="highlight highlight-source-rust notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="pub fn set_game_state(&amp;mut self, state: ~GameState) {
  self.state = state;
}"><pre class="notranslate"><span class="pl-k">pub</span> <span class="pl-k">fn</span> <span class="pl-en">set_game_state</span><span class="pl-kos">(</span><span class="pl-c1">&amp;</span><span class="pl-k">mut</span> <span class="pl-smi">self</span><span class="pl-kos">,</span> <span class="pl-s1">state</span><span class="pl-kos">:</span> ~<span class="pl-smi">GameState</span><span class="pl-kos">)</span> <span class="pl-kos">{</span>
  <span class="pl-smi">self</span><span class="pl-kos">.</span><span class="pl-c1">state</span> = state<span class="pl-kos">;</span>
<span class="pl-kos">}</span></pre></div>
<p dir="auto">I was made aware on the IRC Chat that both of these snippets of code should have worked.</p>
<p dir="auto">Rust Version: master (0.10-pre)<br>
OS: Mac OSX 10.9<br>
Architecture: x86_64</p>