Skip to content

Commit f2a0724

Browse files
committed
Rust: Use getReturnType
1 parent b822216 commit f2a0724

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

rust/ql/lib/codeql/rust/internal/typeinference/TypeInference.qll

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2974,7 +2974,7 @@ private module ConstructionMatchingInput implements MatchingInputSig {
29742974
exists(Declaration d, TypeParameter tp |
29752975
d = this.getTarget() and
29762976
pos.isReturn() and
2977-
tp = d.getDeclaredType(pos, path) and
2977+
tp = d.getReturnType(path) and
29782978
not exists(FunctionPosition pos2 | not pos2.isReturn() and tp = d.getDeclaredType(pos2, _)) and
29792979
// check that no explicit type arguments have been supplied for `tp`
29802980
not exists(TypeArgumentPosition tapos |

0 commit comments

Comments
 (0)