Merge pull request #2468 from max-schaefer/js/regexp-predecessor

Approved by asgerf
This commit is contained in:
semmle-qlci
2019-11-28 16:57:31 +00:00
committed by GitHub
5 changed files with 14 additions and 12 deletions

View File

@@ -26,4 +26,7 @@
/^(^y|^z)(u$|v$)$/;
// OK
/x*^y/;
/x*^y/;
// OK
/(?<=(^|\/)(\.|\.\.))$/;

View File

@@ -1,3 +1,4 @@
| tst.js:2:10:2:10 | $ | This assertion can never match. |
| tst.js:11:3:11:3 | $ | This assertion can never match. |
| tst.js:20:3:20:3 | $ | This assertion can never match. |
| tst.js:38:6:38:6 | $ | This assertion can never match. |

View File

@@ -32,4 +32,7 @@
/x(?!y+$).*y.*/;
// OK
/x(?=[yz]+$).*yz.*/;
/x(?=[yz]+$).*yz.*/;
// NOT OK
/(?<=$x)yz/;