mirror of
https://github.com/github/codeql.git
synced 2026-05-01 19:55:15 +02:00
Python: Fix ExceptStmt::getType
We were not supporting `except` statements handling multiple exception types (specified as a tuple) correctly, instead just returning the tuple itself as the "type" (which makes little sense). To fix this, we explicitly extract the elements of this node, in the case where it _is_ a tuple. This is a change that can potentially affect many queries (as `getType` is used in quite a few places), so some care should be taken to ensure that this does not adversely affect performance.
This commit is contained in:
@@ -1,3 +1,2 @@
|
||||
| test.py:5:15:5:22 | ControlFlowNode for next() | Call to next() in a generator |
|
||||
| test.py:10:20:10:27 | ControlFlowNode for next() | Call to next() in a generator |
|
||||
| test.py:62:19:62:28 | ControlFlowNode for next() | Call to next() in a generator |
|
||||
|
||||
Reference in New Issue
Block a user