You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The section describing annotated types provides a set of rules for determining which extended attributes are associated with a type (which is then the inner type of an annotated type). From a grammar POV, I think the cases it looks at are:
Step 2: TypeWithExtendedAttributes
Step 3: TypeWithExtendedAttributes again, but where Type is UnionType Null
Step 4: Argument
Step 5: DictionaryMember
Step 6: TypeWithExtendedAttributes again, but via TypeDef reference
None of these cases appears to cover the first alternative of UnionMemberType:
ExtendedAttributeList DistinguishableType
That is, the grammar allows for ([Attr] Type1 or Type2) via that alternative, but I don’t think the “extended attributes associated with” set will actually end up including [Attr] for Type1 if these rules are followed as written. At a glance, it might look like step 3 touches on this case — but step 3 only seems to describe the propagation of the attr of [Attr] (union here) to each of the union’s members.
Logically, the ExtendedAttributeList DistinguishableType alternative is the same idea as TypeWithExtendedAttributes but with a narrower set of possible types, so it looks like handling of this case might have been lost inadvertently in a past refactor or something.
The text was updated successfully, but these errors were encountered:
Thanks. It does seem related insofar as they both pertain to extended attributes which are (or should be) associated with individual members of a union. AFAICT don’t think they overlap though — I’m pretty sure the issue I’ve described here is a straight-up omission of something that was meant to exist (because as written, the ExtendedAttributeList of ExtendedAttributeList DistinguishableType just disappears into the void, and is not actually associated with anything).
The section describing annotated types provides a set of rules for determining which extended attributes are associated with a type (which is then the inner type of an annotated type). From a grammar POV, I think the cases it looks at are:
TypeWithExtendedAttributes
TypeWithExtendedAttributes
again, but whereType
isUnionType Null
Argument
DictionaryMember
TypeWithExtendedAttributes
again, but viaTypeDef
referenceNone of these cases appears to cover the first alternative of
UnionMemberType
:ExtendedAttributeList DistinguishableType
That is, the grammar allows for
([Attr] Type1 or Type2)
via that alternative, but I don’t think the “extended attributes associated with” set will actually end up including [Attr] for Type1 if these rules are followed as written. At a glance, it might look like step 3 touches on this case — but step 3 only seems to describe the propagation of the attr of[Attr] (union here)
to each of the union’s members.Logically, the
ExtendedAttributeList DistinguishableType
alternative is the same idea asTypeWithExtendedAttributes
but with a narrower set of possible types, so it looks like handling of this case might have been lost inadvertently in a past refactor or something.The text was updated successfully, but these errors were encountered: