Skip to content

Commit 47cd9c8

Browse files
authored
Merge pull request github#3038 from BekaValentine/python-objectapi-to-valueapi-deprecatedslicemethod
Python: ObjectAPI to ValueAPI: DeprecatedSliceMethod
2 parents f4e8f7a + b36214a commit 47cd9c8

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

python/ql/src/Functions/DeprecatedSliceMethod.ql

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,9 +15,9 @@ predicate slice_method_name(string name) {
1515
name = "__getslice__" or name = "__setslice__" or name = "__delslice__"
1616
}
1717

18-
from PyFunctionObject f, string meth
18+
from PythonFunctionValue f, string meth
1919

20-
where f.getFunction().isMethod() and not f.isOverridingMethod() and
20+
where f.getScope().isMethod() and not f.isOverridingMethod() and
2121
slice_method_name(meth) and f.getName() = meth
2222

2323

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
1-
| functions_test.py:99:5:99:40 | Function __getslice__ | __getslice__ method has been deprecated since Python 2.0 |
2-
| functions_test.py:102:5:102:47 | Function __setslice__ | __setslice__ method has been deprecated since Python 2.0 |
3-
| functions_test.py:105:5:105:40 | Function __delslice__ | __delslice__ method has been deprecated since Python 2.0 |
1+
| functions_test.py:99:5:99:40 | Function DeprecatedSliceMethods.__getslice__ | __getslice__ method has been deprecated since Python 2.0 |
2+
| functions_test.py:102:5:102:47 | Function DeprecatedSliceMethods.__setslice__ | __setslice__ method has been deprecated since Python 2.0 |
3+
| functions_test.py:105:5:105:40 | Function DeprecatedSliceMethods.__delslice__ | __delslice__ method has been deprecated since Python 2.0 |

0 commit comments

Comments
 (0)