File tree Expand file tree Collapse file tree
cpp/ql/src/jsf/4.13 Functions Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -18,13 +18,17 @@ import cpp
1818 programmer, we can flag it anyway, since this is arguably a bug.) */
1919
2020predicate functionsMissingReturnStmt ( Function f , ControlFlowNode blame ) {
21- f .fromSource ( ) and
22- exists ( Type returnType |
23- returnType = f .getType ( ) .getUnderlyingType ( ) .getUnspecifiedType ( ) and
24- not returnType instanceof VoidType and
25- not returnType instanceof TemplateParameter
26- ) and
27- exists ( ReturnStmt s | f .getAPredecessor ( ) = s | blame = s .getAPredecessor ( ) ) }
21+ f .fromSource ( ) and
22+ exists ( Type returnType |
23+ returnType = f .getType ( ) .getUnderlyingType ( ) .getUnspecifiedType ( ) and
24+ not returnType instanceof VoidType and
25+ not returnType instanceof TemplateParameter
26+ ) and
27+ exists ( ReturnStmt s |
28+ f .getAPredecessor ( ) = s and
29+ blame = s .getAPredecessor ( )
30+ )
31+ }
2832
2933/* If a function has a value-carrying return statement, but the extractor hit a snag
3034 whilst parsing the value, then the control flow graph will not include the value.
You can’t perform that action at this time.
0 commit comments