title: How can I intentionally discard a [[nodiscard]] return value?
body: <p>Say I have</p>
  
  <pre><code>[[nodiscard]] int foo ()
  {
      return 0;
  }
  
  int main ()
  {
      foo ();
  }
  </code></pre>
  
  <p>then</p>
  
  <pre><code>error: ignoring return value of ‘int foo()’, declared with attribute nodiscard [-Werror=unused-result]
  </code></pre>
  
  <p>but if</p>
  
  <pre><code>int x = foo ();
  </code></pre>
  
  <p>then</p>
  
  <pre><code>error: unused variable ‘x’ [-Werror=unused-variable]
  </code></pre>
  
  <p>Is there a clean way of telling the compiler "I want to discard this <code>[[nodiscard]]</code> value"?</p>