Skip to content

Commit 59c78b0

Browse files
committed
JS: brought back isGlobal predicate in RegExpCreationNode marked as depricated.
1 parent 5b7f498 commit 59c78b0

File tree

1 file changed

+3
-0
lines changed
  • javascript/ql/lib/semmle/javascript/dataflow

1 file changed

+3
-0
lines changed

javascript/ql/lib/semmle/javascript/dataflow/Nodes.qll

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1682,6 +1682,9 @@ class RegExpCreationNode extends DataFlow::SourceNode {
16821682
result = this.(RegExpLiteralNode).getFlags()
16831683
}
16841684

1685+
/** Holds if the constructed predicate has the `g` flag. */
1686+
deprecated predicate isGlobal() { RegExp::isGlobal(this.getFlags()) }
1687+
16851688
/** Gets a data flow node referring to this regular expression. */
16861689
private DataFlow::SourceNode getAReference(DataFlow::TypeTracker t) {
16871690
t.start() and

0 commit comments

Comments
 (0)