title: Javascript decodeURI(Component) malformed uri exception
body: <p>I entered the following in Chrome's console:</p>
  <pre><code>decodeURIComponent('a%AFc');
  </code></pre>
  <p>Instead of resulting to <code>a0xAFc</code>, it caused a URIError exception (malformed uri).</p>
  <p>I've heard several excuses why this may be possible, but what I don't understand is <strong>why</strong>?</p>
  <p>The <code>decodeURIComponent()</code> function in particular is supposed to decode data, not verify the URI.</p>
  <ul>
  <li><a href="http://en.wikipedia.org/wiki/Percent-encoding" rel="nofollow noreferrer">Wikipedia: Percent Encoding</a></li>
  <li><a href="https://www.rfc-editor.org/rfc/rfc3986#page-12" rel="nofollow noreferrer">RFC3986: URI Generic Syntax (2005)</a></li>
  </ul>