aboutsummaryrefslogtreecommitdiffstats
path: root/lib/compiler/src/v3_kernel.erl
diff options
context:
space:
mode:
authorBjörn Gustavsson <[email protected]>2016-08-23 09:33:16 +0200
committerBjörn Gustavsson <[email protected]>2016-09-21 14:07:53 +0200
commit87d051421ed813801c1f7fdeb7d6aaffefd31572 (patch)
treeec7f585f042924662bfa86191a592e13fcdc7a2d /lib/compiler/src/v3_kernel.erl
parent1d43ca9f9a236b29cb9f22917bbcfa84d1e0fa6f (diff)
downloadotp-87d051421ed813801c1f7fdeb7d6aaffefd31572.tar.gz
otp-87d051421ed813801c1f7fdeb7d6aaffefd31572.tar.bz2
otp-87d051421ed813801c1f7fdeb7d6aaffefd31572.zip
Simplify handling of internal BIFs
Do a simpler translation of internal BIFs. While we are it, also remove the dummy values of Index and Uniq from the make_fun internal operation.
Diffstat (limited to 'lib/compiler/src/v3_kernel.erl')
-rw-r--r--lib/compiler/src/v3_kernel.erl8
1 files changed, 2 insertions, 6 deletions
diff --git a/lib/compiler/src/v3_kernel.erl b/lib/compiler/src/v3_kernel.erl
index e3103e040e..859f110a53 100644
--- a/lib/compiler/src/v3_kernel.erl
+++ b/lib/compiler/src/v3_kernel.erl
@@ -1791,13 +1791,9 @@ uexpr(#ifun{anno=A,vars=Vs,body=B0}, {break,Rs}, St0) ->
end,
Fun = #k_fdef{anno=#k{us=[],ns=[],a=A},func=Fname,arity=Arity,
vars=Vs ++ Fvs,body=B1},
- %% Set dummy values for Index and Uniq -- the real values will
- %% be assigned by beam_asm.
- Index = Uniq = 0,
{#k_bif{anno=#k{us=Free,ns=lit_list_vars(Rs),a=A},
- op=#k_internal{name=make_fun,arity=length(Free)+3},
- args=[#k_atom{val=Fname},#k_int{val=Arity},
- #k_int{val=Index},#k_int{val=Uniq}|Fvs],
+ op=#k_internal{name=make_fun,arity=length(Free)+2},
+ args=[#k_atom{val=Fname},#k_int{val=Arity}|Fvs],
ret=Rs},
Free,add_local_function(Fun, St)};
uexpr(Lit, {break,Rs0}, St0) ->