Commit 4b5dae3d authored by Lev Walkin's avatar Lev Walkin

diffs

parent 725883b2
...@@ -41,7 +41,7 @@ static int expr_break_recursion(arg_t *arg, asn1p_expr_t *expr); ...@@ -41,7 +41,7 @@ static int expr_break_recursion(arg_t *arg, asn1p_expr_t *expr);
static int expr_as_xmlvaluelist(arg_t *arg, asn1p_expr_t *expr); static int expr_as_xmlvaluelist(arg_t *arg, asn1p_expr_t *expr);
static int expr_elements_count(arg_t *arg, asn1p_expr_t *expr); static int expr_elements_count(arg_t *arg, asn1p_expr_t *expr);
static int emit_single_member_PER_constraint(arg_t *arg, asn1cnst_range_t *range, int juscountvalues, char *type); static int emit_single_member_PER_constraint(arg_t *arg, asn1cnst_range_t *range, int juscountvalues, char *type);
static int emit_member_PER_constraints(arg_t *arg, asn1p_expr_t *expr); static int emit_member_PER_constraints(arg_t *arg, asn1p_expr_t *expr, const char *pfx);
static int emit_member_table(arg_t *arg, asn1p_expr_t *expr); static int emit_member_table(arg_t *arg, asn1p_expr_t *expr);
static int emit_tag2member_map(arg_t *arg, tag2el_t *tag2el, int tag2el_count, const char *opt_modifier); static int emit_tag2member_map(arg_t *arg, tag2el_t *tag2el, int tag2el_count, const char *opt_modifier);
static int emit_include_dependencies(arg_t *arg); static int emit_include_dependencies(arg_t *arg);
...@@ -1888,7 +1888,7 @@ emit_single_member_PER_constraint(arg_t *arg, asn1cnst_range_t *range, int alpha ...@@ -1888,7 +1888,7 @@ emit_single_member_PER_constraint(arg_t *arg, asn1cnst_range_t *range, int alpha
} }
static int static int
emit_member_PER_constraints(arg_t *arg, asn1p_expr_t *expr) { emit_member_PER_constraints(arg_t *arg, asn1p_expr_t *expr, const char *pfx) {
int save_target = arg->target->target; int save_target = arg->target->target;
asn1cnst_range_t *range; asn1cnst_range_t *range;
asn1p_expr_type_e etype; asn1p_expr_type_e etype;
...@@ -1906,8 +1906,8 @@ emit_member_PER_constraints(arg_t *arg, asn1p_expr_t *expr) { ...@@ -1906,8 +1906,8 @@ emit_member_PER_constraints(arg_t *arg, asn1p_expr_t *expr) {
REDIR(OT_CTDEFS); REDIR(OT_CTDEFS);
OUT("static asn_per_constraints_t " OUT("static asn_per_constraints_t "
"asn_PER_%s_constr_%d = {\n", "asn_PER_%s_%s_constr_%d = {\n",
MKID(expr), expr->_type_unique_index); pfx, MKID(expr), expr->_type_unique_index);
etype = expr_get_type(arg, expr); etype = expr_get_type(arg, expr);
...@@ -2196,7 +2196,7 @@ emit_member_table(arg_t *arg, asn1p_expr_t *expr) { ...@@ -2196,7 +2196,7 @@ emit_member_table(arg_t *arg, asn1p_expr_t *expr) {
if(expr->constraints if(expr->constraints
|| expr->expr_type == ASN_BASIC_ENUMERATED || expr->expr_type == ASN_BASIC_ENUMERATED
|| expr->expr_type == ASN_CONSTR_CHOICE) { || expr->expr_type == ASN_CONSTR_CHOICE) {
OUT("&asn_PER_%s_constr_%d,\n", OUT("&asn_PER_memb_%s_constr_%d,\n",
MKID(expr), MKID(expr),
expr->_type_unique_index); expr->_type_unique_index);
} else { } else {
...@@ -2249,7 +2249,7 @@ emit_member_table(arg_t *arg, asn1p_expr_t *expr) { ...@@ -2249,7 +2249,7 @@ emit_member_table(arg_t *arg, asn1p_expr_t *expr) {
OUT("}\n"); OUT("}\n");
OUT("\n"); OUT("\n");
if(emit_member_PER_constraints(arg, expr)) if(emit_member_PER_constraints(arg, expr, "memb"))
return -1; return -1;
REDIR(save_target); REDIR(save_target);
...@@ -2268,7 +2268,7 @@ emit_type_DEF(arg_t *arg, asn1p_expr_t *expr, enum tvm_compat tv_mode, int tags_ ...@@ -2268,7 +2268,7 @@ emit_type_DEF(arg_t *arg, asn1p_expr_t *expr, enum tvm_compat tv_mode, int tags_
terminal = asn1f_find_terminal_type_ex(arg->asn, expr); terminal = asn1f_find_terminal_type_ex(arg->asn, expr);
if(emit_member_PER_constraints(arg, expr)) if(emit_member_PER_constraints(arg, expr, "type"))
return -1; return -1;
if(HIDE_INNER_DEFS) if(HIDE_INNER_DEFS)
...@@ -2365,7 +2365,7 @@ emit_type_DEF(arg_t *arg, asn1p_expr_t *expr, enum tvm_compat tv_mode, int tags_ ...@@ -2365,7 +2365,7 @@ emit_type_DEF(arg_t *arg, asn1p_expr_t *expr, enum tvm_compat tv_mode, int tags_
if(expr->constraints if(expr->constraints
|| expr->expr_type == ASN_BASIC_ENUMERATED || expr->expr_type == ASN_BASIC_ENUMERATED
|| expr->expr_type == ASN_CONSTR_CHOICE) { || expr->expr_type == ASN_CONSTR_CHOICE) {
OUT("&asn_PER_%s_constr_%d,\n", OUT("&asn_PER_type_%s_constr_%d,\n",
p, expr->_type_unique_index); p, expr->_type_unique_index);
} else { } else {
OUT("0,\t/* No PER visible constraints */\n"); OUT("0,\t/* No PER visible constraints */\n");
......
This diff is collapsed.
This diff is collapsed.
...@@ -58,12 +58,12 @@ extern asn_TYPE_descriptor_t asn_DEF_Choice; ...@@ -58,12 +58,12 @@ extern asn_TYPE_descriptor_t asn_DEF_Choice;
/*** <<< CTDEFS [Choice] >>> ***/ /*** <<< CTDEFS [Choice] >>> ***/
static asn_per_constraints_t asn_PER_ch_constr_4 = { static asn_per_constraints_t asn_PER_type_ch_constr_4 = {
{ APC_CONSTRAINED, 1, 1, 0, 1 } /* (0..1) */, { APC_CONSTRAINED, 1, 1, 0, 1 } /* (0..1) */,
{ APC_UNCONSTRAINED, -1, -1, 0, 0 }, { APC_UNCONSTRAINED, -1, -1, 0, 0 },
0, 0 /* No PER value map */ 0, 0 /* No PER value map */
}; };
static asn_per_constraints_t asn_PER_Choice_constr_1 = { static asn_per_constraints_t asn_PER_type_Choice_constr_1 = {
{ APC_CONSTRAINED | APC_EXTENSIBLE, 2, 2, 0, 2 } /* (0..2,...) */, { APC_CONSTRAINED | APC_EXTENSIBLE, 2, 2, 0, 2 } /* (0..2,...) */,
{ APC_UNCONSTRAINED, -1, -1, 0, 0 }, { APC_UNCONSTRAINED, -1, -1, 0, 0 },
0, 0 /* No PER value map */ 0, 0 /* No PER value map */
...@@ -124,7 +124,7 @@ asn_TYPE_descriptor_t asn_DEF_ch_4 = { ...@@ -124,7 +124,7 @@ asn_TYPE_descriptor_t asn_DEF_ch_4 = {
0, /* No effective tags (count) */ 0, /* No effective tags (count) */
0, /* No tags (pointer) */ 0, /* No tags (pointer) */
0, /* No tags (count) */ 0, /* No tags (count) */
&asn_PER_ch_constr_4, &asn_PER_type_ch_constr_4,
asn_MBR_ch_4, asn_MBR_ch_4,
2, /* Elements count */ 2, /* Elements count */
&asn_SPC_ch_specs_4 /* Additional specs */ &asn_SPC_ch_specs_4 /* Additional specs */
...@@ -154,7 +154,7 @@ static asn_TYPE_member_t asn_MBR_Choice_1[] = { ...@@ -154,7 +154,7 @@ static asn_TYPE_member_t asn_MBR_Choice_1[] = {
.tag_mode = 0, .tag_mode = 0,
.type = &asn_DEF_ch_4, .type = &asn_DEF_ch_4,
.memb_constraints = 0, /* Defer constraints checking to the member type */ .memb_constraints = 0, /* Defer constraints checking to the member type */
.per_constraints = &asn_PER_ch_constr_4, .per_constraints = &asn_PER_memb_ch_constr_4,
.default_value = 0, .default_value = 0,
.name = "ch" .name = "ch"
}, },
...@@ -203,7 +203,7 @@ asn_TYPE_descriptor_t asn_DEF_Choice = { ...@@ -203,7 +203,7 @@ asn_TYPE_descriptor_t asn_DEF_Choice = {
0, /* No effective tags (count) */ 0, /* No effective tags (count) */
0, /* No tags (pointer) */ 0, /* No tags (pointer) */
0, /* No tags (count) */ 0, /* No tags (count) */
&asn_PER_Choice_constr_1, &asn_PER_type_Choice_constr_1,
asn_MBR_Choice_1, asn_MBR_Choice_1,
4, /* Elements count */ 4, /* Elements count */
&asn_SPC_Choice_specs_1 /* Additional specs */ &asn_SPC_Choice_specs_1 /* Additional specs */
...@@ -243,7 +243,7 @@ extern asn_TYPE_descriptor_t asn_DEF_Choice2; ...@@ -243,7 +243,7 @@ extern asn_TYPE_descriptor_t asn_DEF_Choice2;
/*** <<< CTDEFS [Choice2] >>> ***/ /*** <<< CTDEFS [Choice2] >>> ***/
static asn_per_constraints_t asn_PER_Choice2_constr_1 = { static asn_per_constraints_t asn_PER_type_Choice2_constr_1 = {
{ APC_CONSTRAINED, 1, 1, 0, 1 } /* (0..1) */, { APC_CONSTRAINED, 1, 1, 0, 1 } /* (0..1) */,
{ APC_UNCONSTRAINED, -1, -1, 0, 0 }, { APC_UNCONSTRAINED, -1, -1, 0, 0 },
0, 0 /* No PER value map */ 0, 0 /* No PER value map */
...@@ -302,7 +302,7 @@ asn_TYPE_descriptor_t asn_DEF_Choice2 = { ...@@ -302,7 +302,7 @@ asn_TYPE_descriptor_t asn_DEF_Choice2 = {
0, /* No effective tags (count) */ 0, /* No effective tags (count) */
0, /* No tags (pointer) */ 0, /* No tags (pointer) */
0, /* No tags (count) */ 0, /* No tags (count) */
&asn_PER_Choice2_constr_1, &asn_PER_type_Choice2_constr_1,
asn_MBR_Choice2_1, asn_MBR_Choice2_1,
2, /* Elements count */ 2, /* Elements count */
&asn_SPC_Choice2_specs_1 /* Additional specs */ &asn_SPC_Choice2_specs_1 /* Additional specs */
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment