🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.protocols.iso
Article #435

Re:

#435
From: Mark Smith
Date: Fri, 04 Sep 1992 23:13
61 lines
2300 bytes
Thanks to Bancroft Scott who sent me the following reply. I posted it
in case anyone else was interested.

Mark smith


>I'm trying to understand section 24.6 of ISO/IEC 8824:1990 regarding
>distinct identifiers.
>
>Given the following definitions:
>
>T1 ::= SEQUENCE {   X1,
>		  b BOOLEAN
>		}
>
>X1 ::= CHOICE { y INTEGER, z REAL }
>
>Would the identifiers for T1 be: y, z, b ??

No.  The only identifier for T1 is b, but y and z are visible to
T1 because X1 does not have an identifier.  In effect, this means
that when creating a value reference, you will not be able to
distinguish whether y and z were defined in T1 or in X1.  If you
were to define a component within X1 that has an identifier b, you
would get a complaint from a decent ASN.1 compiler to let you know
that you have duplicately defined identifiers.

What section 24.6 is saying can be rephrased to state that if a CHOICE
enclosed in a SET, SEQUENCE or CHOICE, does not have an identifier, its 
components must have identifiers different from those found in the enclosing
SET, SEQUENCE or CHOICE, and different from those found in any other CHOICE 
that has no identifier and lies within the enclosing SET, SEQUENCE or CHOICE.

I think you have the right interpretation of section 24.6, but your
question is not stated well.

>I'm assuming the same would be true if the actual CHOICE definition replaced
>the DefinedType X1.

Right.

>And to clarify, given the following variation on the definition:
>
>T2 ::= SEQUENCE { a X1, 
>                  b BOOLEAN
>                }
>
>Would the identifiers for T2 be: a, b ??

Yes.

>My assumption is that, if an identifier is specified for a reference to a
>CHOICE type, then 8824 24.6 does not apply.

Correct.


Bancroft Scott

ps: Note that effective with the 1993 issue of ASN.1, identifiers become
    mandatory on all components of SET, SEQUENCE and CHOICE.
Technical Details
Message-ID: <86010003@hpcndaw.CND.HP.COM>
Path: arc1-ca.pugleaf.net!sparky!uunet!wupost!sdd.hp.com!scd.hp.com!hplextra!hpfcso!hpcndaw!mds
References: <86010002@hpcndaw.CND.HP.COM>

Show Full Headers
Complete Article Headers
From: mds@hpcndaw.CND.HP.COM (Mark Smith)
Date: Fri, 4 Sep 1992 23:13:31 GMT
Subject: Re:
Message-ID: <86010003@hpcndaw.CND.HP.COM>
Organization: HP Network and System Management Division
Path: arc1-ca.pugleaf.net!sparky!uunet!wupost!sdd.hp.com!scd.hp.com!hplextra!hpfcso!hpcndaw!mds
Newsgroups: comp.protocols.iso
References: <86010002@hpcndaw.CND.HP.COM>
Lines: 61