Why does this code raise: `Uncaught SyntaxError: Unexpected token catch`
<p>The following JavaScript snippet raises <code>SyntaxError: Unexpected token catch</code> immediately upon loading the script:</p>

<pre><code>try {
    // Client error (e.g., form validation)
    if ((jqXHR.status === 400) &amp;&amp; data.errors) {
      // do something
    }
    // Server error (e.g., can't send email)
    else if ((jqXHR.status === 500) &amp;&amp; data.errors) {
      // do something else
    }
    // Unknown error
    else {
      throw;
    }
} catch(e) {
  // Handle error
}
</code></pre>

<p>Unlike the other <code>SyntaxError: Unexpected token</code> questions on SO, this problem is not caused by malformed JSON or simply forgetting a brace. There's something wrong with the syntax, but it's not immediately clear what it is.</p>
