aboutsummaryrefslogtreecommitdiffstats
path: root/lib/compiler
diff options
context:
space:
mode:
authorBjörn Gustavsson <[email protected]>2014-03-12 15:25:12 +0100
committerBjörn Gustavsson <[email protected]>2014-03-12 15:30:17 +0100
commitd1ecc2003b8807d9622b6c1a8fccfe50e5c60a42 (patch)
tree4c06e4ab8346e507d4d564eff4519285a6f2cf9c /lib/compiler
parent965d5185d61ce33a8a136b1df42e764e7c95896d (diff)
downloadotp-d1ecc2003b8807d9622b6c1a8fccfe50e5c60a42.tar.gz
otp-d1ecc2003b8807d9622b6c1a8fccfe50e5c60a42.tar.bz2
otp-d1ecc2003b8807d9622b6c1a8fccfe50e5c60a42.zip
cerl_inline: Fix type error
b08ffc15e1d9ad105dd6385bbac41c97c09b48bc corrected a bug, but violated the types by passing a c_apply() when a c_let() was expected. That happened to work, but Dialyzer was not amused.
Diffstat (limited to 'lib/compiler')
-rw-r--r--lib/compiler/src/cerl_inline.erl5
1 files changed, 3 insertions, 2 deletions
diff --git a/lib/compiler/src/cerl_inline.erl b/lib/compiler/src/cerl_inline.erl
index bc9bdc67a4..fa1d34cc9b 100644
--- a/lib/compiler/src/cerl_inline.erl
+++ b/lib/compiler/src/cerl_inline.erl
@@ -42,7 +42,7 @@
bitstr_flags/1, binary_segments/1, update_c_alias/3,
update_c_apply/3, update_c_binary/2, update_c_bitstr/6,
update_c_call/4, update_c_case/3, update_c_catch/2,
- update_c_clause/4, c_fun/2, c_int/1, c_let/3,
+ update_c_clause/4, c_fun/2, c_int/1, c_let/3, ann_c_let/4,
update_c_let/4, update_c_letrec/3, update_c_module/5,
update_c_primop/3, update_c_receive/4, update_c_seq/3,
c_seq/2, update_c_try/6, c_tuple/1, update_c_values/2,
@@ -1034,7 +1034,8 @@ i_apply(E, Ctxt, Ren, Env, S) ->
E2 = case is_c_fname(E1) andalso length(Es) =/= fname_arity(E1) of
true ->
V = new_var(Env),
- update_c_let(E, [V], E1, update_c_apply(E, V, Es));
+ ann_c_let(get_ann(E), [V], E1,
+ update_c_apply(E, V, Es));
false ->
update_c_apply(E, E1, Es)
end,