mirror of
https://github.com/github/codeql.git
synced 2025-12-24 20:56:33 +01:00
Initial commit of Python queries and QL libraries.
This commit is contained in:
committed by
Mark Shannon
parent
90c75cd362
commit
5f58824d1b
11
python/ql/src/Exceptions/NotImplemented.qll
Normal file
11
python/ql/src/Exceptions/NotImplemented.qll
Normal file
@@ -0,0 +1,11 @@
|
||||
|
||||
import python
|
||||
|
||||
/** Holds if `notimpl` refers to `NotImplemented` or `NotImplemented()` in the `raise` statement */
|
||||
predicate use_of_not_implemented_in_raise(Raise raise, Expr notimpl) {
|
||||
notimpl.refersTo(theNotImplementedObject()) and
|
||||
(
|
||||
notimpl = raise.getException() or
|
||||
notimpl = raise.getException().(Call).getFunc()
|
||||
)
|
||||
}
|
||||
Reference in New Issue
Block a user