Function names with property lookups in JScript 5.8 / WSH
<p>I was looking at Windows Script Host code that runs in JScript 5.8 and I noticed this construct:</p>

<pre><code>function String.prototype.foo() { ... }
</code></pre>

<p>I can't find any documentation about it! I'm fairly sure this is not legal in EcmaScript, so it has to be a Microsoft-only extension. Does anyone have any links explaining its design and semantics?</p>