mirror of https://gerrit.osmocom.org/asn1c
removed orthohonality
git-svn-id: https://asn1c.svn.sourceforge.net/svnroot/asn1c/trunk@376 59561ff5-6e30-0410-9f3c-9617f08c8826
This commit is contained in:
parent
dcd32fe424
commit
74ce239f62
|
@ -448,8 +448,8 @@ maintainer-clean-generic:
|
|||
@echo "This command is intended for maintainers to use"
|
||||
@echo "it deletes files that may require special tools to rebuild."
|
||||
-rm -f asn1p_y.c
|
||||
-rm -f asn1p_y.h
|
||||
-rm -f asn1p_l.c
|
||||
-rm -f asn1p_y.h
|
||||
clean: clean-am
|
||||
|
||||
clean-am: clean-generic clean-libtool clean-noinstLTLIBRARIES \
|
||||
|
|
|
@ -37,37 +37,52 @@ static int expr_type2uclass_value[ASN_EXPR_TYPE_MAX]
|
|||
[ ASN_STRING_BMPString ] = 30,
|
||||
};
|
||||
|
||||
static char *expr_uclass2str[32] __attribute__ ((unused)) = {
|
||||
static enum asn1p_expr_type expr_utag2type[32] __attribute__ ((unused)) = {
|
||||
[ 0 ] = 0, /* If zero length, end-of-content */
|
||||
[ 1 ] = "BOOLEAN",
|
||||
[ 2 ] = "INTEGER",
|
||||
[ 3 ] = "BIT STRING",
|
||||
[ 4 ] = "OCTET STRING",
|
||||
[ 5 ] = "NULL",
|
||||
[ 6 ] = "OBJECT IDENTIFIER",
|
||||
[ 7 ] = "ObjectDescriptor",
|
||||
[ 8 ] = "EXTERNAL",
|
||||
[ 9 ] = "REAL",
|
||||
[ 10 ] = "ENUMERATED",
|
||||
[ 11 ] = "EMBEDDED-PDV",
|
||||
[ 12 ] = "UTF8String",
|
||||
[ 13 ] = "RELATIVE-OID",
|
||||
[ 1 ] = ASN_BASIC_BOOLEAN,
|
||||
[ 2 ] = ASN_BASIC_INTEGER,
|
||||
[ 3 ] = ASN_BASIC_BIT_STRING,
|
||||
[ 4 ] = ASN_BASIC_OCTET_STRING,
|
||||
[ 5 ] = ASN_BASIC_NULL,
|
||||
[ 6 ] = ASN_BASIC_OBJECT_IDENTIFIER,
|
||||
[ 7 ] = ASN_STRING_ObjectDescriptor,
|
||||
[ 8 ] = ASN_BASIC_EXTERNAL,
|
||||
[ 9 ] = ASN_BASIC_REAL,
|
||||
[ 10 ] = ASN_BASIC_ENUMERATED,
|
||||
[ 11 ] = ASN_BASIC_EMBEDDED_PDV,
|
||||
[ 12 ] = ASN_STRING_UTF8String,
|
||||
[ 13 ] = ASN_BASIC_RELATIVE_OID,
|
||||
[ 14 ] = 0,
|
||||
[ 16 ] = "SEQUENCE", /* Or "SEQUENCE OF" */
|
||||
[ 17 ] = "SET", /* Or "SET OF" */
|
||||
[ 18 ] = "NumericString", /* " "|"0".."9" */
|
||||
[ 19 ] = "PrintableString",
|
||||
[ 20 ] = "TeletexString",
|
||||
[ 21 ] = "VideotexString",
|
||||
[ 22 ] = "IA5String",
|
||||
[ 23 ] = "UTCTime",
|
||||
[ 24 ] = "GeneralizedTime",
|
||||
[ 25 ] = "GraphicString",
|
||||
[ 26 ] = "VisibleString",
|
||||
[ 27 ] = "GeneralString",
|
||||
[ 28 ] = "UniversalString", /* 32-bit UCS-4 */
|
||||
[ 29 ] = "CharacterString",
|
||||
[ 30 ] = "BMPString", /* 16-bit UCS-2 */
|
||||
[ 15 ] = 0,
|
||||
[ 16 ] = ASN_CONSTR_SEQUENCE, /* Or SEQUENCE OF */
|
||||
[ 17 ] = ASN_CONSTR_SET, /* Or SET OF */
|
||||
[ 18 ] = ASN_STRING_NumericString, /* " "|"0".."9" */
|
||||
[ 19 ] = ASN_STRING_PrintableString,
|
||||
[ 20 ] = ASN_STRING_TeletexString,
|
||||
[ 21 ] = ASN_STRING_VideotexString,
|
||||
[ 22 ] = ASN_STRING_IA5String,
|
||||
[ 23 ] = ASN_BASIC_UTCTime,
|
||||
[ 24 ] = ASN_BASIC_GeneralizedTime,
|
||||
[ 25 ] = ASN_STRING_GraphicString,
|
||||
[ 26 ] = ASN_STRING_VisibleString,
|
||||
[ 27 ] = ASN_STRING_GeneralString,
|
||||
[ 28 ] = ASN_STRING_UniversalString, /* 32-bit UCS-4 */
|
||||
[ 29 ] = ASN_BASIC_CHARACTER_STRING,
|
||||
[ 30 ] = ASN_STRING_BMPString, /* 16-bit UCS-2 */
|
||||
};
|
||||
|
||||
/*
|
||||
* Convert the [UNIVERSAL value] into the internal type or a string.
|
||||
*/
|
||||
#define ASN_UNIVERSAL_TAG2TYPE(utag) \
|
||||
( \
|
||||
(((int)(utag)) < 0 \
|
||||
|| ((int)(utag)) >= (int)(sizeof(expr_utag2type) \
|
||||
/ sizeof(expr_utag2type[0]))) \
|
||||
? 0 \
|
||||
: expr_utag2type[(int)(utag)] \
|
||||
)
|
||||
#define ASN_UNIVERSAL_TAG2STR(utag) \
|
||||
ASN_EXPR_TYPE2STR(ASN_UNIVERSAL_TAG2TYPE(utag))
|
||||
|
||||
#endif /* ASN1_PARSER_EXPR2UCLASS_H */
|
||||
|
|
|
@ -51,7 +51,7 @@ static char *asn1p_expr_type2str[] __attribute__ ((unused)) = {
|
|||
|| ((size_t)(type)) >= sizeof(asn1p_expr_type2str) \
|
||||
/ sizeof(asn1p_expr_type2str[0])) \
|
||||
? (char *)0 \
|
||||
: asn1p_expr_type2str[(type)] \
|
||||
: asn1p_expr_type2str[(int)(type)] \
|
||||
)
|
||||
|
||||
#endif /* ASN1_PARSER_EXPR_STR_H */
|
||||
|
|
|
@ -42,7 +42,7 @@ print<<EOM;
|
|||
|| ((size_t)(type)) >= sizeof(asn1p_expr_type2str) \\
|
||||
/ sizeof(asn1p_expr_type2str[0])) \\
|
||||
? (char *)0 \\
|
||||
: asn1p_expr_type2str[(type)] \\
|
||||
: asn1p_expr_type2str[(int)(type)] \\
|
||||
)
|
||||
|
||||
#endif /* ASN1_PARSER_EXPR_STR_H */
|
||||
|
|
Loading…
Reference in New Issue