mirror of
https://github.com/github/codeql.git
synced 2025-12-24 04:36:35 +01:00
Merge pull request #9388 from MathiasVP/cfg-for-yield
Swift: CFG for `yield`
This commit is contained in:
@@ -203,6 +203,14 @@ module Stmts {
|
||||
}
|
||||
}
|
||||
|
||||
private class YieldStmtTree extends AstStandardPostOrderTree {
|
||||
override YieldStmt ast;
|
||||
|
||||
final override ControlFlowElement getChildElement(int i) {
|
||||
result.asAstNode() = ast.getResult(i).getFullyConverted()
|
||||
}
|
||||
}
|
||||
|
||||
private class FailTree extends AstLeafTree {
|
||||
override FailStmt ast;
|
||||
}
|
||||
|
||||
@@ -5032,6 +5032,11 @@ cfg.swift:
|
||||
# 394| enter set
|
||||
#-----| -> set
|
||||
|
||||
# 394| exit (unnamed function decl)
|
||||
|
||||
# 394| exit (unnamed function decl) (normal)
|
||||
#-----| -> exit (unnamed function decl)
|
||||
|
||||
# 394| exit get
|
||||
|
||||
# 394| exit get (normal)
|
||||
@@ -5049,6 +5054,9 @@ cfg.swift:
|
||||
|
||||
# 394| value
|
||||
|
||||
# 394| yield ...
|
||||
#-----| -> exit (unnamed function decl) (normal)
|
||||
|
||||
# 395| deinit
|
||||
#-----| -> self
|
||||
|
||||
|
||||
Reference in New Issue
Block a user