On Fri, Apr 29, 2016 at 02:01:08PM +0200, Ladislav Lhotka wrote:
> 
> > On 29 Apr 2016, at 13:56, Juergen Schoenwaelder 
> > <[email protected]> wrote:
> > 
> > On Fri, Apr 29, 2016 at 01:52:33PM +0200, Ladislav Lhotka wrote:
> >> Hi,
> >> 
> >> if we have
> >> 
> >> typedef foo {
> >>  type enumeration {
> >>    enum one;
> >>    enum two;
> >>  }
> >> }
> >> 
> >> typedef bar {
> >>  type foo;
> >> }
> >> 
> >> what is the set of values permitted for "bar"? Is it empty or the
> >> same as for "foo"?
> > 
> > The set is { one, two } - where is the hidden catch??
> 
> In sec. 9.6.4 of 6020bis:
> 
>    When an existing enumeration type is restricted, the set of assigned
>    names in the new type MUST be a subset of the base type's set of
>    assigned names.  The value of such an assigned name MUST NOT be
>    changed.
> 
> In our case there are no names assigned in the new type "bar", i.e. empty set 
> (which is a subset of the base type's set).
>

There is no type restriction hence there is no restriction of the
value space.

/js

-- 
Juergen Schoenwaelder           Jacobs University Bremen gGmbH
Phone: +49 421 200 3587         Campus Ring 1 | 28759 Bremen | Germany
Fax:   +49 421 200 3103         <http://www.jacobs-university.de/>

_______________________________________________
netmod mailing list
[email protected]
https://www.ietf.org/mailman/listinfo/netmod

Reply via email to