Closed
Bug 303554
Opened 19 years ago
Closed 19 years ago
Regexp.test confusing behavior with global flag
Categories
(Core :: JavaScript Engine, defect)
Tracking
()
VERIFIED
DUPLICATE
of bug 237111
People
(Reporter: nkuzminski, Unassigned)
Details
Attachments
(1 file)
|
221 bytes,
text/html
|
Details |
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.7.10) Gecko/20050716 Firefox/1.0.6 Build Identifier: Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.7.10) Gecko/20050716 Firefox/1.0.6 regexp.test alternates true and false return values on a matching string when using the global flag. I think for this method the g flag should be ignored. See the testcase. Reproducible: Always Steps to Reproduce: 1.Define a regexp with global flag 2.Do a regexp.test with a string that matches the pattern so it returns true 3.Do the test again and see it returning false Actual Results: true false true false ... Expected Results: true true true true ...
| Reporter | ||
Comment 1•19 years ago
|
||
Comment 2•19 years ago
|
||
*** This bug has been marked as a duplicate of 237111 ***
Status: UNCONFIRMED → RESOLVED
Closed: 19 years ago
Resolution: --- → DUPLICATE
Updated•19 years ago
|
Status: RESOLVED → VERIFIED
You need to log in
before you can comment on or make changes to this bug.
Description
•