Originally Posted by Old Pedant
Okay, I see it bumps lastIndex. But why does that matter, if you are doing a fresh call to test()???
Because it's still pointing to the end of the last match, so on the next call it doesn't search from the start of the string.