diff --git a/python/ql/lib/semmle/python/controlflow/internal/AstNodeImpl.qll b/python/ql/lib/semmle/python/controlflow/internal/AstNodeImpl.qll index d027e518475..c57cd697373 100644 --- a/python/ql/lib/semmle/python/controlflow/internal/AstNodeImpl.qll +++ b/python/ql/lib/semmle/python/controlflow/internal/AstNodeImpl.qll @@ -760,6 +760,8 @@ module AstSigImpl implements AstSig { index = 0 and result = t.getBody() or result = t.getHandler(index - 1) and index >= 1 + or + index = -1 and result = t.getFinalbody() ) or // MatchStmt: subject (0), cases (1..n)