aboutsummaryrefslogtreecommitdiffstats
path: root/lib/asn1/src/asn1ct_gen_per.erl
diff options
context:
space:
mode:
Diffstat (limited to 'lib/asn1/src/asn1ct_gen_per.erl')
-rw-r--r--lib/asn1/src/asn1ct_gen_per.erl6
1 files changed, 4 insertions, 2 deletions
diff --git a/lib/asn1/src/asn1ct_gen_per.erl b/lib/asn1/src/asn1ct_gen_per.erl
index 69d9d51bf1..a3c1f01961 100644
--- a/lib/asn1/src/asn1ct_gen_per.erl
+++ b/lib/asn1/src/asn1ct_gen_per.erl
@@ -215,9 +215,11 @@ emit_enc_real(Erules, Real) ->
asn1ct_name:new(tmpval),
asn1ct_name:new(tmplen),
emit(["begin",nl,
- "{",{curr,tmpval},com,{curr,tmplen},"} = ",
+ {curr,tmpval}," = ",
{call,real_common,encode_real,[Real]},com,nl,
- "[",{call,Erules,encode_length,[{curr,tmplen}]},",",
+ {curr,tmplen}," = ",
+ {call,erlang,byte_size,[{curr,tmpval}]},com,nl,
+ "[",{call,Erules,encode_length,[{curr,tmplen}]},com,nl,
{curr,tmpval},"]",nl,
"end"]).