Skip to content

Commit 958fddb

Browse files
cleanup order and remove duplicates for arithmetic methods
1 parent d7b855c commit 958fddb

File tree

1 file changed

+7
-6
lines changed

1 file changed

+7
-6
lines changed

python/ql/src/Functions/IncorrectRaiseInSpecialMethod.ql

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -29,12 +29,13 @@ private predicate indexingMethod(string name) {
2929
private predicate arithmeticMethod(string name) {
3030
name =
3131
[
32-
"__add__", "__sub__", "__or__", "__xor__", "__rshift__", "__pow__", "__mul__", "__neg__",
33-
"__radd__", "__rsub__", "__rdiv__", "__rfloordiv__", "__rlshift__", "__rand__", "__ror__",
34-
"__rxor__", "__rrshift__", "__rpow__", "__rmul__", "__truediv__", "__rtruediv__", "__pos__",
35-
"__iadd__", "__isub__", "__idiv__", "__ifloordiv__", "__idiv__", "__ilshift__", "__iand__",
36-
"__ior__", "__ixor__", "__irshift__", "__abs__", "__ipow__", "__imul__", "__itruediv__",
37-
"__floordiv__", "__div__", "__divmod__", "__lshift__", "__and__"
32+
"__add__", "__sub__", "__and__", "__or__", "__xor__", "__lshift__", "__rshift__", "__pow__",
33+
"__mul__", "__div__", "__divmod__", "__truediv__", "__floordiv__", "__matmul__", "__radd__",
34+
"__rsub__", "__rand__", "__ror__", "__rxor__", "__rlshift__", "__rrshift__", "__rpow__",
35+
"__rmul__", "__rdiv__", "__rdivmod__", "__rtruediv__", "__rfloordiv__", "__rmatmul__",
36+
"__iadd__", "__isub__", "__iand__", "__ior__", "__ixor__", "__ilshift__", "__irshift__",
37+
"__ipow__", "__imul__", "__idiv__", "__idivmod__", "__itruediv__", "__ifloordiv__",
38+
"__imatmul__", "__pos__", "__neg__", "__abs__", "__invert__",
3839
]
3940
}
4041

0 commit comments

Comments
 (0)