mirror of
https://github.com/github/codeql.git
synced 2026-05-02 04:05:14 +02:00
delete old deprecations
This commit is contained in:
@@ -1,5 +1,4 @@
|
||||
import python
|
||||
deprecated import semmle.python.objects.ObjectInternal as OI
|
||||
private import semmle.python.ApiGraphs
|
||||
// Need to import since frameworks can extend the abstract `RegexString`
|
||||
private import semmle.python.Frameworks
|
||||
@@ -98,19 +97,6 @@ private DataFlow::Node re_flag_tracker(string flag_name) {
|
||||
/** Gets a regular expression mode flag associated with the given data flow node. */
|
||||
string mode_from_node(DataFlow::Node node) { node = re_flag_tracker(result) }
|
||||
|
||||
/**
|
||||
* DEPRECATED 2021-02-24 -- use `mode_from_node` instead.
|
||||
*
|
||||
* Gets a regular expression mode flag associated with the given value.
|
||||
*/
|
||||
deprecated string mode_from_mode_object(Value obj) {
|
||||
result in ["DEBUG", "IGNORECASE", "LOCALE", "MULTILINE", "DOTALL", "UNICODE", "VERBOSE"] and
|
||||
exists(int flag |
|
||||
flag = Value::named("sre_constants.SRE_FLAG_" + result).(OI::ObjectInternal).intValue() and
|
||||
obj.(OI::ObjectInternal).intValue().bitAnd(flag) = flag
|
||||
)
|
||||
}
|
||||
|
||||
/** A StrConst used as a regular expression */
|
||||
abstract class RegexString extends Expr {
|
||||
RegexString() { (this instanceof Bytes or this instanceof Unicode) }
|
||||
|
||||
Reference in New Issue
Block a user