Files
codeql/javascript/ql/test/query-tests/RegExp/UnmatchableDollar
Max Schaefer a788bf87a0 JavaScript: Fix RegExpTerm.getPredecessor and getSuccessor.
These were originally meant to give you the term that is textually matched right before/right after the receiver. When I introduced support for lookbehinds, I changed the behaviour to give you the term that is _operationally_ matched before/after the receiver (remember that lookbehinds are implemented by reverse-matching).

However, I think that's rarely ever what you want, and is wrong for the only two uses of these predicates, where it's the textual matching order that we are after, not the operational order.

Consequently, I've changed the semantics back and updated the comments to hopefully clarify the intention.
2019-11-28 15:14:50 +00:00
..