In 126.96.36.199 "String.prototype.search (regexp)",
step 7 says:
Search the value string from its beginning for an occurrence of the
regular expression pattern rx. ...
This seems vague. Compare to String.prototype.match, which (at a point roughly analogous to search's step 7) calls RegExpExec, which goes into great detail about how to apply a regexp to a string.
I understand that 'search' can't call RegExpExec, because RegExpExec *doesn't* ignore the regexp's 'lastIndex' and 'global' properties. But it seems like there should be something of comparable detail.
String.prototype.search now delegates to RegExp.prototype.search but it has the same vague language that used to be in the String method. However, there is already a margin TODO comment that says better spec. language is needed.
Changed the title of this bug so it relates to RegExp search
fixed in rev23 editor's draft
fixed in rev23 draft