Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
A
asn1c
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Libraries
asn1c
Commits
18660d26
Commit
18660d26
authored
Aug 12, 2017
by
Lev Walkin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
regenerated with new ioc code
parent
91ca2732
Changes
7
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
305 additions
and
43 deletions
+305
-43
tests/tests-asn1c-compiler/126-per-extensions-OK.asn1.-Pgen-PER
...tests-asn1c-compiler/126-per-extensions-OK.asn1.-Pgen-PER
+1
-1
tests/tests-asn1c-compiler/139-component-relation-OK.asn1.-P
tests/tests-asn1c-compiler/139-component-relation-OK.asn1.-P
+97
-10
tests/tests-asn1c-compiler/140-component-relation-OK.asn1.-P
tests/tests-asn1c-compiler/140-component-relation-OK.asn1.-P
+97
-10
tests/tests-asn1c-compiler/141-component-relation-OK.asn1.-EFprint-class-matrix
...iler/141-component-relation-OK.asn1.-EFprint-class-matrix
+3
-3
tests/tests-asn1c-compiler/141-component-relation-OK.asn1.-P
tests/tests-asn1c-compiler/141-component-relation-OK.asn1.-P
+104
-16
tests/tests-asn1c-compiler/95-choice-per-order-OK.asn1.-Pgen-PER
...ests-asn1c-compiler/95-choice-per-order-OK.asn1.-Pgen-PER
+2
-2
tests/tests-asn1c-compiler/98-attribute-class-OK.asn1.-P
tests/tests-asn1c-compiler/98-attribute-class-OK.asn1.-P
+1
-1
No files found.
tests/tests-asn1c-compiler/126-per-extensions-OK.asn1.-Pgen-PER
View file @
18660d26
...
...
@@ -323,7 +323,7 @@ asn_TYPE_member_t asn_MBR_PDU_2_1[] = {
.name = "ext0"
},
};
static const
int
asn_MAP_PDU_2_cmap_1[] = { 0, 2, 1 };
static const
unsigned
asn_MAP_PDU_2_cmap_1[] = { 0, 2, 1 };
static const asn_TYPE_tag2member_t asn_MAP_PDU_2_tag2el_1[] = {
{ (ASN_TAG_CLASS_CONTEXT | (0 << 2)), 2, 0, 0 }, /* ext0 */
{ (ASN_TAG_CLASS_CONTEXT | (1 << 2)), 1, 0, 0 }, /* ext1 */
...
...
tests/tests-asn1c-compiler/139-component-relation-OK.asn1.-P
View file @
18660d26
...
...
@@ -6,13 +6,32 @@
#include <asn_ioc.h>
#include "PrimitiveMessage.h"
#include "ComplexMessage.h"
#include <OPEN_TYPE.h>
#include <constr_CHOICE.h>
#include <constr_SEQUENCE.h>
/*** <<< DEPS [Frame] >>> ***/
typedef enum value_PR {
value_PR_NOTHING, /* No components present */
value_PR_PrimitiveMessage,
value_PR_ComplexMessage
} value_PR;
/*** <<< TYPE-DECLS [Frame] >>> ***/
typedef struct Frame {
long ident;
ANY_t value;
struct value {
value_PR present;
union value_u {
PrimitiveMessage_t PrimitiveMessage;
ComplexMessage_t ComplexMessage;
} choice;
/* Context for parsing across buffer boundaries */
asn_struct_ctx_t _asn_ctx;
} value;
/*
* This type is extensible,
* possible extensions are below.
...
...
@@ -36,7 +55,7 @@ static const asn_ioc_cell_t asn_IOS_FrameTypes_1_rows[] = {
{ "&id", aioc__value, &asn_DEF_NativeInteger, &asn_VAL_2_2 },
{ "&Type", aioc__type, &asn_DEF_ComplexMessage }
};
static asn_ioc_set_t asn_IOS_FrameTypes_1[] = {
static
const
asn_ioc_set_t asn_IOS_FrameTypes_1[] = {
2, 2, asn_IOS_FrameTypes_1_rows
};
...
...
@@ -61,23 +80,27 @@ memb_ident_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr,
return td->check_constraints(td, sptr, ctfailcb, app_key);
}
static asn_
TYPE_descriptor_t *
static asn_
type_selector_result_t
select_value_type(const asn_TYPE_descriptor_t *parent_type, const void *parent_sptr) {
asn_ioc_set_t *itable = asn_IOS_FrameTypes_1;
asn_type_selector_result_t result = {0, 0};
const asn_ioc_set_t *itable = asn_IOS_FrameTypes_1;
size_t constraining_column = 0; /* &id */
size_t for_column = 1; /* &Type */
size_t row;
const long *constraining_value = (const long *)((const char *)parent_sptr + offsetof(struct Frame, ident));
for(row=0; row < itable->rows_count; row++) {
asn_ioc_cell_s *constraining_cell = itable->rows[row * itable->columns_count + constraining_column];
asn_ioc_cell_s *type_cell = itable->rows[row * itable->columns_count + for_column];
if(constraining_cell->type_descriptor->struct_compare(constraining_cell->type_descriptor, constraining_value, constraining_cell->value_sptr) == 0) {
return type_cell->type_descriptor;
const asn_ioc_cell_t *constraining_cell = &itable->rows[row * itable->columns_count + constraining_column];
const asn_ioc_cell_t *type_cell = &itable->rows[row * itable->columns_count + for_column];
if(constraining_cell->type_descriptor->compare_struct(constraining_cell->type_descriptor, constraining_value, constraining_cell->value_sptr) == 0) {
result.type_descriptor = type_cell->type_descriptor;
result.presence_index = row + 1;
break;
}
}
return
NULL
;
return
result
;
}
static int
...
...
@@ -102,6 +125,70 @@ memb_value_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr,
/*** <<< STAT-DEFS [Frame] >>> ***/
static asn_TYPE_member_t asn_MBR_value_3[] = {
{ ATF_NOFLAGS, 0, offsetof(struct value, choice.PrimitiveMessage),
.tag = (ASN_TAG_CLASS_UNIVERSAL | (16 << 2)),
.tag_mode = 0,
.type = &asn_DEF_PrimitiveMessage,
.type_selector = 0,
.memb_constraints = 0, /* Defer constraints checking to the member type */
.oer_constraints = 0, /* OER is not compiled, use -gen-OER */
.per_constraints = 0, /* PER is not compiled, use -gen-PER */
.default_value = 0,
.name = "PrimitiveMessage"
},
{ ATF_NOFLAGS, 0, offsetof(struct value, choice.ComplexMessage),
.tag = (ASN_TAG_CLASS_UNIVERSAL | (16 << 2)),
.tag_mode = 0,
.type = &asn_DEF_ComplexMessage,
.type_selector = 0,
.memb_constraints = 0, /* Defer constraints checking to the member type */
.oer_constraints = 0, /* OER is not compiled, use -gen-OER */
.per_constraints = 0, /* PER is not compiled, use -gen-PER */
.default_value = 0,
.name = "ComplexMessage"
},
};
static const asn_TYPE_tag2member_t asn_MAP_value_tag2el_3[] = {
{ (ASN_TAG_CLASS_UNIVERSAL | (16 << 2)), 0, 0, 1 }, /* PrimitiveMessage */
{ (ASN_TAG_CLASS_UNIVERSAL | (16 << 2)), 1, -1, 0 } /* ComplexMessage */
};
static asn_CHOICE_specifics_t asn_SPC_value_specs_3 = {
sizeof(struct value),
offsetof(struct value, _asn_ctx),
offsetof(struct value, present),
sizeof(((struct value *)0)->present),
asn_MAP_value_tag2el_3,
2, /* Count of tags in the map */
.canonical_order = 0,
.ext_start = -1 /* Extensions start */
};
static /* Use -fall-defs-global to expose */
asn_TYPE_descriptor_t asn_DEF_value_3 = {
"value",
"value",
OPEN_TYPE_free,
OPEN_TYPE_print,
OPEN_TYPE_compare,
OPEN_TYPE_constraint,
OPEN_TYPE_decode_ber,
OPEN_TYPE_encode_der,
OPEN_TYPE_decode_xer,
OPEN_TYPE_encode_xer,
0, 0, /* No OER support, use "-gen-OER" to enable */
0, 0, /* No PER support, use "-gen-PER" to enable */
0, /* Use generic outmost tag fetcher */
0, /* No effective tags (pointer) */
0, /* No effective tags (count) */
0, /* No tags (pointer) */
0, /* No tags (count) */
0, /* No OER visible constraints */
0, /* No PER visible constraints */
asn_MBR_value_3,
2, /* Elements count */
&asn_SPC_value_specs_3 /* Additional specs */
};
static asn_TYPE_member_t asn_MBR_Frame_1[] = {
{ ATF_NOFLAGS, 0, offsetof(struct Frame, ident),
.tag = (ASN_TAG_CLASS_UNIVERSAL | (2 << 2)),
...
...
@@ -117,7 +204,7 @@ static asn_TYPE_member_t asn_MBR_Frame_1[] = {
{ ATF_OPEN_TYPE | ATF_NOFLAGS, 0, offsetof(struct Frame, value),
.tag = -1 /* Ambiguous tag (ANY?) */,
.tag_mode = 0,
.type = &asn_DEF_
ANY
,
.type = &asn_DEF_
value_3
,
.type_selector = select_value_type,
.memb_constraints = memb_value_constraint_1,
.oer_constraints = 0, /* OER is not compiled, use -gen-OER */
...
...
tests/tests-asn1c-compiler/140-component-relation-OK.asn1.-P
View file @
18660d26
...
...
@@ -6,13 +6,32 @@
#include <asn_ioc.h>
#include "PrimitiveMessage.h"
#include "ComplexMessage.h"
#include <OPEN_TYPE.h>
#include <constr_CHOICE.h>
#include <constr_SEQUENCE.h>
/*** <<< DEPS [Frame] >>> ***/
typedef enum value_PR {
value_PR_NOTHING, /* No components present */
value_PR_PrimitiveMessage,
value_PR_ComplexMessage
} value_PR;
/*** <<< TYPE-DECLS [Frame] >>> ***/
typedef struct Frame {
long ident;
ANY_t value;
struct value {
value_PR present;
union value_u {
PrimitiveMessage_t PrimitiveMessage;
ComplexMessage_t ComplexMessage;
} choice;
/* Context for parsing across buffer boundaries */
asn_struct_ctx_t _asn_ctx;
} value;
/*
* This type is extensible,
* possible extensions are below.
...
...
@@ -36,7 +55,7 @@ static const asn_ioc_cell_t asn_IOS_FrameTypes_1_rows[] = {
{ "&id", aioc__value, &asn_DEF_NativeInteger, &asn_VAL_2_2 },
{ "&Type", aioc__type, &asn_DEF_ComplexMessage }
};
static asn_ioc_set_t asn_IOS_FrameTypes_1[] = {
static
const
asn_ioc_set_t asn_IOS_FrameTypes_1[] = {
2, 2, asn_IOS_FrameTypes_1_rows
};
...
...
@@ -61,23 +80,27 @@ memb_ident_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr,
return td->check_constraints(td, sptr, ctfailcb, app_key);
}
static asn_
TYPE_descriptor_t *
static asn_
type_selector_result_t
select_value_type(const asn_TYPE_descriptor_t *parent_type, const void *parent_sptr) {
asn_ioc_set_t *itable = asn_IOS_FrameTypes_1;
asn_type_selector_result_t result = {0, 0};
const asn_ioc_set_t *itable = asn_IOS_FrameTypes_1;
size_t constraining_column = 0; /* &id */
size_t for_column = 1; /* &Type */
size_t row;
const long *constraining_value = (const long *)((const char *)parent_sptr + offsetof(struct Frame, ident));
for(row=0; row < itable->rows_count; row++) {
asn_ioc_cell_s *constraining_cell = itable->rows[row * itable->columns_count + constraining_column];
asn_ioc_cell_s *type_cell = itable->rows[row * itable->columns_count + for_column];
if(constraining_cell->type_descriptor->struct_compare(constraining_cell->type_descriptor, constraining_value, constraining_cell->value_sptr) == 0) {
return type_cell->type_descriptor;
const asn_ioc_cell_t *constraining_cell = &itable->rows[row * itable->columns_count + constraining_column];
const asn_ioc_cell_t *type_cell = &itable->rows[row * itable->columns_count + for_column];
if(constraining_cell->type_descriptor->compare_struct(constraining_cell->type_descriptor, constraining_value, constraining_cell->value_sptr) == 0) {
result.type_descriptor = type_cell->type_descriptor;
result.presence_index = row + 1;
break;
}
}
return
NULL
;
return
result
;
}
static int
...
...
@@ -102,6 +125,70 @@ memb_value_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr,
/*** <<< STAT-DEFS [Frame] >>> ***/
static asn_TYPE_member_t asn_MBR_value_3[] = {
{ ATF_NOFLAGS, 0, offsetof(struct value, choice.PrimitiveMessage),
.tag = (ASN_TAG_CLASS_UNIVERSAL | (16 << 2)),
.tag_mode = 0,
.type = &asn_DEF_PrimitiveMessage,
.type_selector = 0,
.memb_constraints = 0, /* Defer constraints checking to the member type */
.oer_constraints = 0, /* OER is not compiled, use -gen-OER */
.per_constraints = 0, /* PER is not compiled, use -gen-PER */
.default_value = 0,
.name = "PrimitiveMessage"
},
{ ATF_NOFLAGS, 0, offsetof(struct value, choice.ComplexMessage),
.tag = (ASN_TAG_CLASS_UNIVERSAL | (16 << 2)),
.tag_mode = 0,
.type = &asn_DEF_ComplexMessage,
.type_selector = 0,
.memb_constraints = 0, /* Defer constraints checking to the member type */
.oer_constraints = 0, /* OER is not compiled, use -gen-OER */
.per_constraints = 0, /* PER is not compiled, use -gen-PER */
.default_value = 0,
.name = "ComplexMessage"
},
};
static const asn_TYPE_tag2member_t asn_MAP_value_tag2el_3[] = {
{ (ASN_TAG_CLASS_UNIVERSAL | (16 << 2)), 0, 0, 1 }, /* PrimitiveMessage */
{ (ASN_TAG_CLASS_UNIVERSAL | (16 << 2)), 1, -1, 0 } /* ComplexMessage */
};
static asn_CHOICE_specifics_t asn_SPC_value_specs_3 = {
sizeof(struct value),
offsetof(struct value, _asn_ctx),
offsetof(struct value, present),
sizeof(((struct value *)0)->present),
asn_MAP_value_tag2el_3,
2, /* Count of tags in the map */
.canonical_order = 0,
.ext_start = -1 /* Extensions start */
};
static /* Use -fall-defs-global to expose */
asn_TYPE_descriptor_t asn_DEF_value_3 = {
"value",
"value",
OPEN_TYPE_free,
OPEN_TYPE_print,
OPEN_TYPE_compare,
OPEN_TYPE_constraint,
OPEN_TYPE_decode_ber,
OPEN_TYPE_encode_der,
OPEN_TYPE_decode_xer,
OPEN_TYPE_encode_xer,
0, 0, /* No OER support, use "-gen-OER" to enable */
0, 0, /* No PER support, use "-gen-PER" to enable */
0, /* Use generic outmost tag fetcher */
0, /* No effective tags (pointer) */
0, /* No effective tags (count) */
0, /* No tags (pointer) */
0, /* No tags (count) */
0, /* No OER visible constraints */
0, /* No PER visible constraints */
asn_MBR_value_3,
2, /* Elements count */
&asn_SPC_value_specs_3 /* Additional specs */
};
static asn_TYPE_member_t asn_MBR_Frame_1[] = {
{ ATF_NOFLAGS, 0, offsetof(struct Frame, ident),
.tag = (ASN_TAG_CLASS_UNIVERSAL | (2 << 2)),
...
...
@@ -117,7 +204,7 @@ static asn_TYPE_member_t asn_MBR_Frame_1[] = {
{ ATF_OPEN_TYPE | ATF_NOFLAGS, 0, offsetof(struct Frame, value),
.tag = -1 /* Ambiguous tag (ANY?) */,
.tag_mode = 0,
.type = &asn_DEF_
ANY
,
.type = &asn_DEF_
value_3
,
.type_selector = select_value_type,
.memb_constraints = memb_value_constraint_1,
.oer_constraints = 0, /* OER is not compiled, use -gen-OER */
...
...
tests/tests-asn1c-compiler/141-component-relation-OK.asn1.-EFprint-class-matrix
View file @
18660d26
ModuleComponentRelationConstraint { iso org(3) dod(6) internet(1) private(4)
enterprise(1) spelio(9363) software(1) asn1c(5) test(1) 141 }
DEFINITIONS ::=
DEFINITIONS
AUTOMATIC TAGS
::=
BEGIN
Frame ::= SEQUENCE {
ident FRAME-STRUCTURE.&id ({FrameTypes}),
value FRAME-STRUCTURE.&Type ({FrameTypes}{@.ident}),
ident
[0] IMPLICIT
FRAME-STRUCTURE.&id ({FrameTypes}),
value
[1] EXPLICIT
FRAME-STRUCTURE.&Type ({FrameTypes}{@.ident}),
...
}
...
...
tests/tests-asn1c-compiler/141-component-relation-OK.asn1.-P
View file @
18660d26
...
...
@@ -6,13 +6,32 @@
#include <asn_ioc.h>
#include "PrimitiveMessage.h"
#include "ComplexMessage.h"
#include <OPEN_TYPE.h>
#include <constr_CHOICE.h>
#include <constr_SEQUENCE.h>
/*** <<< DEPS [Frame] >>> ***/
typedef enum value_PR {
value_PR_NOTHING, /* No components present */
value_PR_PrimitiveMessage,
value_PR_ComplexMessage
} value_PR;
/*** <<< TYPE-DECLS [Frame] >>> ***/
typedef struct Frame {
ConstrainedInteger_t ident;
ANY_t value;
struct value {
value_PR present;
union value_u {
PrimitiveMessage_t PrimitiveMessage;
ComplexMessage_t ComplexMessage;
} choice;
/* Context for parsing across buffer boundaries */
asn_struct_ctx_t _asn_ctx;
} value;
/*
* This type is extensible,
* possible extensions are below.
...
...
@@ -36,7 +55,7 @@ static const asn_ioc_cell_t asn_IOS_FrameTypes_1_rows[] = {
{ "&id", aioc__value, &asn_DEF_ConstrainedInteger, &asn_VAL_2_cplxMessage },
{ "&Type", aioc__type, &asn_DEF_ComplexMessage }
};
static asn_ioc_set_t asn_IOS_FrameTypes_1[] = {
static
const
asn_ioc_set_t asn_IOS_FrameTypes_1[] = {
2, 2, asn_IOS_FrameTypes_1_rows
};
...
...
@@ -67,23 +86,27 @@ memb_ident_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr,
}
}
static asn_
TYPE_descriptor_t *
static asn_
type_selector_result_t
select_value_type(const asn_TYPE_descriptor_t *parent_type, const void *parent_sptr) {
asn_ioc_set_t *itable = asn_IOS_FrameTypes_1;
asn_type_selector_result_t result = {0, 0};
const asn_ioc_set_t *itable = asn_IOS_FrameTypes_1;
size_t constraining_column = 0; /* &id */
size_t for_column = 1; /* &Type */
size_t row;
const long *constraining_value = (const long *)((const char *)parent_sptr + offsetof(struct Frame, ident));
for(row=0; row < itable->rows_count; row++) {
asn_ioc_cell_s *constraining_cell = itable->rows[row * itable->columns_count + constraining_column];
asn_ioc_cell_s *type_cell = itable->rows[row * itable->columns_count + for_column];
if(constraining_cell->type_descriptor->struct_compare(constraining_cell->type_descriptor, constraining_value, constraining_cell->value_sptr) == 0) {
return type_cell->type_descriptor;
const asn_ioc_cell_t *constraining_cell = &itable->rows[row * itable->columns_count + constraining_column];
const asn_ioc_cell_t *type_cell = &itable->rows[row * itable->columns_count + for_column];
if(constraining_cell->type_descriptor->compare_struct(constraining_cell->type_descriptor, constraining_value, constraining_cell->value_sptr) == 0) {
result.type_descriptor = type_cell->type_descriptor;
result.presence_index = row + 1;
break;
}
}
return
NULL
;
return
result
;
}
static int
...
...
@@ -108,10 +131,74 @@ memb_value_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr,
/*** <<< STAT-DEFS [Frame] >>> ***/
static asn_TYPE_member_t asn_MBR_value_3[] = {
{ ATF_NOFLAGS, 0, offsetof(struct value, choice.PrimitiveMessage),
.tag = (ASN_TAG_CLASS_UNIVERSAL | (16 << 2)),
.tag_mode = 0,
.type = &asn_DEF_PrimitiveMessage,
.type_selector = 0,
.memb_constraints = 0, /* Defer constraints checking to the member type */
.oer_constraints = 0, /* OER is not compiled, use -gen-OER */
.per_constraints = 0, /* PER is not compiled, use -gen-PER */
.default_value = 0,
.name = "PrimitiveMessage"
},
{ ATF_NOFLAGS, 0, offsetof(struct value, choice.ComplexMessage),
.tag = (ASN_TAG_CLASS_UNIVERSAL | (16 << 2)),
.tag_mode = 0,
.type = &asn_DEF_ComplexMessage,
.type_selector = 0,
.memb_constraints = 0, /* Defer constraints checking to the member type */
.oer_constraints = 0, /* OER is not compiled, use -gen-OER */
.per_constraints = 0, /* PER is not compiled, use -gen-PER */
.default_value = 0,
.name = "ComplexMessage"
},
};
static const asn_TYPE_tag2member_t asn_MAP_value_tag2el_3[] = {
{ (ASN_TAG_CLASS_UNIVERSAL | (16 << 2)), 0, 0, 1 }, /* PrimitiveMessage */
{ (ASN_TAG_CLASS_UNIVERSAL | (16 << 2)), 1, -1, 0 } /* ComplexMessage */
};
static asn_CHOICE_specifics_t asn_SPC_value_specs_3 = {
sizeof(struct value),
offsetof(struct value, _asn_ctx),
offsetof(struct value, present),
sizeof(((struct value *)0)->present),
asn_MAP_value_tag2el_3,
2, /* Count of tags in the map */
.canonical_order = 0,
.ext_start = -1 /* Extensions start */
};
static /* Use -fall-defs-global to expose */
asn_TYPE_descriptor_t asn_DEF_value_3 = {
"value",
"value",
OPEN_TYPE_free,
OPEN_TYPE_print,
OPEN_TYPE_compare,
OPEN_TYPE_constraint,
OPEN_TYPE_decode_ber,
OPEN_TYPE_encode_der,
OPEN_TYPE_decode_xer,
OPEN_TYPE_encode_xer,
0, 0, /* No OER support, use "-gen-OER" to enable */
0, 0, /* No PER support, use "-gen-PER" to enable */
0, /* Use generic outmost tag fetcher */
0, /* No effective tags (pointer) */
0, /* No effective tags (count) */
0, /* No tags (pointer) */
0, /* No tags (count) */
0, /* No OER visible constraints */
0, /* No PER visible constraints */
asn_MBR_value_3,
2, /* Elements count */
&asn_SPC_value_specs_3 /* Additional specs */
};
static asn_TYPE_member_t asn_MBR_Frame_1[] = {
{ ATF_NOFLAGS, 0, offsetof(struct Frame, ident),
.tag = (ASN_TAG_CLASS_
UNIVERSAL | (2
<< 2)),
.tag_mode =
0,
.tag = (ASN_TAG_CLASS_
CONTEXT | (0
<< 2)),
.tag_mode =
-1, /* IMPLICIT tag at current level */
.type = &asn_DEF_ConstrainedInteger,
.type_selector = 0,
.memb_constraints = memb_ident_constraint_1,
...
...
@@ -121,9 +208,9 @@ static asn_TYPE_member_t asn_MBR_Frame_1[] = {
.name = "ident"
},
{ ATF_OPEN_TYPE | ATF_NOFLAGS, 0, offsetof(struct Frame, value),
.tag =
-1 /* Ambiguous tag (ANY?) */
,
.tag_mode =
0,
.type = &asn_DEF_
ANY
,
.tag =
(ASN_TAG_CLASS_CONTEXT | (1 << 2))
,
.tag_mode =
+1, /* EXPLICIT tag at current level */
.type = &asn_DEF_
value_3
,
.type_selector = select_value_type,
.memb_constraints = memb_value_constraint_1,
.oer_constraints = 0, /* OER is not compiled, use -gen-OER */
...
...
@@ -136,13 +223,14 @@ static const ber_tlv_tag_t asn_DEF_Frame_tags_1[] = {
(ASN_TAG_CLASS_UNIVERSAL | (16 << 2))
};
static const asn_TYPE_tag2member_t asn_MAP_Frame_tag2el_1[] = {
{ (ASN_TAG_CLASS_UNIVERSAL | (2 << 2)), 0, 0, 0 } /* ident */
{ (ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, 0 }, /* ident */
{ (ASN_TAG_CLASS_CONTEXT | (1 << 2)), 1, 0, 0 } /* value */
};
static asn_SEQUENCE_specifics_t asn_SPC_Frame_specs_1 = {
sizeof(struct Frame),
offsetof(struct Frame, _asn_ctx),
asn_MAP_Frame_tag2el_1,
1
, /* Count of tags in the map */
2
, /* Count of tags in the map */
0, 0, 0, /* Optional elements (not needed) */
1, /* Start extensions */
3 /* Stop extensions */
...
...
tests/tests-asn1c-compiler/95-choice-per-order-OK.asn1.-Pgen-PER
View file @
18660d26
...
...
@@ -95,7 +95,7 @@ static asn_TYPE_member_t asn_MBR_ch_4[] = {
.name = "int"
},
};
static const
int
asn_MAP_ch_cmap_4[] = { 1, 0 };
static const
unsigned
asn_MAP_ch_cmap_4[] = { 1, 0 };
static const asn_TYPE_tag2member_t asn_MAP_ch_tag2el_4[] = {
{ (ASN_TAG_CLASS_UNIVERSAL | (2 << 2)), 1, 0, 0 }, /* int */
{ (ASN_TAG_CLASS_UNIVERSAL | (5 << 2)), 0, 0, 0 } /* null */
...
...
@@ -183,7 +183,7 @@ static asn_TYPE_member_t asn_MBR_Choice_1[] = {
.name = "bool"
},
};
static const
int
asn_MAP_Choice_cmap_1[] = { 2, 1, 0, 3 };
static const
unsigned
asn_MAP_Choice_cmap_1[] = { 2, 1, 0, 3 };
static const asn_TYPE_tag2member_t asn_MAP_Choice_tag2el_1[] = {
{ (ASN_TAG_CLASS_UNIVERSAL | (1 << 2)), 3, 0, 0 }, /* bool */
{ (ASN_TAG_CLASS_UNIVERSAL | (2 << 2)), 2, 0, 0 }, /* int */
...
...
tests/tests-asn1c-compiler/98-attribute-class-OK.asn1.-P
View file @
18660d26
...
...
@@ -28,7 +28,7 @@ static const asn_ioc_cell_t asn_IOS_Attributes_1_rows[] = {
{ "&id", aioc__value, &asn_DEF_RELATIVE_OID, &asn_VAL_1_raf },
{ "&id", aioc__value, &asn_DEF_RELATIVE_OID, &asn_VAL_2_rcf }
};
static asn_ioc_set_t asn_IOS_Attributes_1[] = {
static
const
asn_ioc_set_t asn_IOS_Attributes_1[] = {
2, 1, asn_IOS_Attributes_1_rows
};
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment