Add ConditionalExpr.getBranchExpr(boolean)

This commit is contained in:
Marcono1234
2021-02-12 03:56:29 +01:00
parent 02578cfff2
commit 905648e452
13 changed files with 35 additions and 65 deletions

View File

@@ -16,10 +16,7 @@ class CharType extends PrimitiveType {
CharType() { this.hasName("char") }
}
private Type getABranchType(ConditionalExpr ce) {
result = ce.getTrueExpr().getType() or
result = ce.getFalseExpr().getType()
}
private Type getABranchType(ConditionalExpr ce) { result = ce.getBranchExpr(_).getType() }
from ConditionalExpr ce
where