diff options
author | Björn Gustavsson <[email protected]> | 2013-03-19 14:32:04 +0100 |
---|---|---|
committer | Björn Gustavsson <[email protected]> | 2013-05-31 14:52:21 +0200 |
commit | 6574e0f48d9ea6f18550d9a7a3bf3aec3d1790e3 (patch) | |
tree | f762acb763bebefa6d538a5d7dde1ac4d612c2c3 /lib/asn1 | |
parent | 2bc24f790938c8a67e38eb24ccf14fc8afeebe71 (diff) | |
download | otp-6574e0f48d9ea6f18550d9a7a3bf3aec3d1790e3.tar.gz otp-6574e0f48d9ea6f18550d9a7a3bf3aec3d1790e3.tar.bz2 otp-6574e0f48d9ea6f18550d9a7a3bf3aec3d1790e3.zip |
asn1ct_constructed_per: Remove dead code for handling of ENUMERATED
An ENUMERATED is always represented as a two-tuple, never as
three-tuple.
Diffstat (limited to 'lib/asn1')
-rw-r--r-- | lib/asn1/src/asn1ct_constructed_per.erl | 16 |
1 files changed, 2 insertions, 14 deletions
diff --git a/lib/asn1/src/asn1ct_constructed_per.erl b/lib/asn1/src/asn1ct_constructed_per.erl index cb5352a4bd..1edacd266a 100644 --- a/lib/asn1/src/asn1ct_constructed_per.erl +++ b/lib/asn1/src/asn1ct_constructed_per.erl @@ -515,13 +515,7 @@ gen_encode_sof(Erule,Typename,SeqOrSetOf,D) when is_record(D,type) -> emit({indent(3),"'enc_",asn1ct_gen:list2name(Typename), "_components'(Val",ObjFun,", [])"}), emit({nl,"].",nl}), - NewComponentType = - case ComponentType#type.def of - {'ENUMERATED',_,Component}-> - ComponentType#type{def={'ENUMERATED',Component}}; - _ -> ComponentType - end, - gen_encode_sof_components(Erule,Typename,SeqOrSetOf,NewComponentType). + gen_encode_sof_components(Erule, Typename, SeqOrSetOf, ComponentType). %% Logic copied from asn1_per_bin_rt2ct:encode_constrained_number @@ -583,13 +577,7 @@ gen_decode_sof(Erules,Typename,SeqOrSetOf,D) when is_record(D,type) -> emit([",",nl, "'dec_",asn1ct_gen:list2name(Typename), "_components'(",Num,", ",Buf,ObjFun,", []).",nl,nl]), - NewComponentType = - case ComponentType#type.def of - {'ENUMERATED',_,Component}-> - ComponentType#type{def={'ENUMERATED',Component}}; - _ -> ComponentType - end, - gen_decode_sof_components(Erules,Typename,SeqOrSetOf,NewComponentType). + gen_decode_sof_components(Erules, Typename, SeqOrSetOf, ComponentType). is_aligned(per) -> true; is_aligned(uper) -> false. |