title: Compiler forces me to implement trait method but the `Self` trait bound on method is never satisfied for my type
body: <p>I have a trait <code>Foo</code>. I want to force implementors to define a method, <em>if</em> those implementors implement another trait (<code>Clone</code> in this example). My idea (<a href="https://play.rust-lang.org/?version=nightly&amp;mode=debug&amp;edition=2018&amp;gist=99ec9089e9c43287149292e22bce0647" rel="noreferrer">Playground</a>):</p>
  
  <pre class="lang-rust prettyprint-override"><code>trait Foo {
      // Note: in my real application, the trait has other methods as well,
      // so I can't simply add `Clone` as super trait
      fn foo(&amp;self) 
      where 
          Self: Clone;
  }
  
  struct NoClone;
  impl Foo for NoClone {}
  </code></pre>
  
  <p>Sadly, this leads to:</p>
  
  <pre class="lang-none prettyprint-override"><code>error[E0046]: not all trait items implemented, missing: `foo`
   --&gt; src/lib.rs:8:1
    |
  2 | /     fn foo(&amp;self) 
  3 | |     where 
  4 | |         Self: Clone;
    | |____________________- `foo` from trait
  ...
  8 |   impl Foo for NoClone {}
    |   ^^^^^^^^^^^^^^^^^^^^ missing `foo` in implementation
  </code></pre>
  
  <p>I don't understand this error: the compiler clearly knows that <code>NoClone</code> does not implement <code>Clone</code>, so why am I required to provide a definitoin for <code>foo</code>? In particular, if I attempt to provide a definition (<a href="https://play.rust-lang.org/?version=nightly&amp;mode=debug&amp;edition=2018&amp;gist=471330ebd72db60fec0cb25ad3337310" rel="noreferrer">Playground</a>):</p>
  
  <pre class="lang-rust prettyprint-override"><code>impl Foo for NoClone {
      fn foo(&amp;self) 
      where 
          Self: Clone
      {
          unreachable!()
      }
  }
  </code></pre>
  
  <p>I get the error:</p>
  
  <pre class="lang-none prettyprint-override"><code>error[E0277]: the trait bound `NoClone: std::clone::Clone` is not satisfied
    --&gt; src/lib.rs:9:5
     |
  9  | /     fn foo(&amp;self) 
  10 | |     where 
  11 | |         Self: Clone
  12 | |     {
  13 | |         unreachable!()
  14 | |     }
     | |_____^ the trait `std::clone::Clone` is not implemented for `NoClone`
     |
     = help: see issue #48214
     = help: add #![feature(trivial_bounds)] to the crate attributes to enable
  </code></pre>
  
  <p>So the compiler knows for sure. (FYI: with <code>#![feature(trivial_bounds)]</code> it compiles, but I don't want to define a bunch of methods with <code>unreachable!()</code> as body.)</p>
  
  <p><strong>Why does the compiler force me to provide the method definition? Can I work around this problem somehow?</strong></p>