aboutsummaryrefslogtreecommitdiffstats
path: root/lib/asn1/src/asn1ct_gen_per_rt2ct.erl
diff options
context:
space:
mode:
authorBjörn Gustavsson <[email protected]>2013-03-15 15:07:07 +0100
committerBjörn Gustavsson <[email protected]>2013-05-31 14:52:20 +0200
commit2bc24f790938c8a67e38eb24ccf14fc8afeebe71 (patch)
tree7455a434347829d5a9422b483758c524e516fb3b /lib/asn1/src/asn1ct_gen_per_rt2ct.erl
parentc7bfb442de270d8d1e37cb5e521f678f0176d241 (diff)
downloadotp-2bc24f790938c8a67e38eb24ccf14fc8afeebe71.tar.gz
otp-2bc24f790938c8a67e38eb24ccf14fc8afeebe71.tar.bz2
otp-2bc24f790938c8a67e38eb24ccf14fc8afeebe71.zip
PER/UPER: Eliminate gen_encode_prim_wrapper() and DoTag argument
asn1ct_constructed_per:gen_encode_prim_wrapper() no longer serves any useful purpose, as it is easier to call asn1ct_per:gen_encode_prim() directly. Also, the DoTag argument for asn1ct_per:gen_encode_prim() is never actually used, so it can be eliminated at the same time.
Diffstat (limited to 'lib/asn1/src/asn1ct_gen_per_rt2ct.erl')
-rw-r--r--lib/asn1/src/asn1ct_gen_per_rt2ct.erl8
1 files changed, 4 insertions, 4 deletions
diff --git a/lib/asn1/src/asn1ct_gen_per_rt2ct.erl b/lib/asn1/src/asn1ct_gen_per_rt2ct.erl
index 9fc6cea59a..c9e5f52e38 100644
--- a/lib/asn1/src/asn1ct_gen_per_rt2ct.erl
+++ b/lib/asn1/src/asn1ct_gen_per_rt2ct.erl
@@ -23,12 +23,12 @@
-include("asn1_records.hrl").
--export([gen_encode_prim/4]).
+-export([gen_encode_prim/3]).
-import(asn1ct_gen, [emit/1,demit/1]).
-import(asn1ct_func, [call/3]).
-gen_encode_prim(Erules,D,DoTag,Value) when is_record(D,type) ->
+gen_encode_prim(Erules, #type{}=D, Value) ->
Constraint = D#type.constraint,
case D#type.def of
'INTEGER' ->
@@ -119,9 +119,9 @@ gen_encode_prim(Erules,D,DoTag,Value) when is_record(D,type) ->
#'ObjectClassFieldType'{} ->
case asn1ct_gen:get_inner(D#type.def) of
{fixedtypevaluefield,_,InnerType} ->
- gen_encode_prim(Erules,InnerType,DoTag,Value);
+ gen_encode_prim(Erules, InnerType, Value);
T -> %% 'ASN1_OPEN_TYPE'
- gen_encode_prim(Erules,D#type{def=T},DoTag,Value)
+ gen_encode_prim(Erules, D#type{def=T}, Value)
end;
XX ->
exit({asn1_error,nyi,XX})