title: Same regex evaluated differently with sed than with grep
body: <p>Consider following commands</p>
  
  <p><pre><code>~ echo "f(ew)" > t
  ~ egrep "f\([^\)]*\)" t
  <b>f(yo)</b>
  </pre></code></p>
  
  <p>as expected <code>egrep</code> matches the whole line.</p>
  
  <p>But for the following commands the regex doesn't catch the last parenthese</p>
  
  <pre><code>~ echo "f(ew)" &gt; t
  ~ sed -i "s/f\([^\)]*\)/yo/" t
  ~ cat t
  yo)
  </code></pre>
  
  <p>why isn't the last parenthese catched?</p>