Skip to content

Commit 576dc0c

Browse files
Eric Holkbrson
authored andcommitted
---
yaml --- r: 2785 b: refs/heads/master c: d72d504 h: refs/heads/master i: 2783: fcf0626 v: v3
1 parent 51977d0 commit 576dc0c

File tree

2 files changed

+4
-2
lines changed

2 files changed

+4
-2
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
---
2-
refs/heads/master: 4c4a4aee91309d359b50ffb7bbd1fc20b9fcf633
2+
refs/heads/master: d72d50473ff320e72045cfea513eb43f0f214e21

trunk/src/comp/middle/typeck.rs

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2387,7 +2387,9 @@ fn check_expr(&@stmt_ctxt scx, &@ast::expr expr) {
23872387
check_call(scx, f, args);
23882388

23892389
auto fty = expr_ty(scx.fcx.ccx.tcx, f);
2390-
demand::simple(scx, f.span, ty::mk_nil(scx.fcx.ccx.tcx), fty);
2390+
auto ret_ty = ty::ret_ty_of_fn_ty(scx.fcx.ccx.tcx, fty);
2391+
2392+
demand::simple(scx, f.span, ty::mk_nil(scx.fcx.ccx.tcx), ret_ty);
23912393

23922394
// FIXME: Other typechecks needed
23932395

0 commit comments

Comments
 (0)