Closed baardsen closed 8 years ago
Same here https://jsfiddle.net/Xotic750/ocmsxhjs/
I'm not entirely sure what's causing this, since String#search
isn't being shimmed directly - it probably calls into something else that is being shimmed (which is a native bug in and of itself).
oops, nvm, this is a bug in RegExp.prototype[Symbol.search]
. Fixing!
In version 0.34.0
'a'.search(/a/)
returns -1 instead of the expected 0. If given a string (i.e.'a'.search('a')
) then search successfully returns 0. Error is not present in version 0.33.13.Tested that the error is reproducible in Chrome 49.0.2593.0 dev-m, Firefox 43.0.2 and MS Edge 25.10586.0.0. Curiously it is not reproducible in IE 11.20.10586.0.