From f2a93bc8583524ee4ac487f8dc8e9c4559597c62 Mon Sep 17 00:00:00 2001 From: Miles Ziemer <45497130+milesziemer@users.noreply.github.com> Date: Thu, 25 May 2023 11:43:03 -0400 Subject: [PATCH] Add EnumShapeMember, move TraitStatements grammar (#1792) Adds an EnumShapeMember production to the grammar for consistency with ShapeMember, and moves TraitStatements from EnumShapeMembers and ShapeMembers into EnumShapeMember and ShapeMember respectively. --- docs/source-2.0/spec/idl.rst | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/docs/source-2.0/spec/idl.rst b/docs/source-2.0/spec/idl.rst index 2e62567ddad..5c25c13d106 100644 --- a/docs/source-2.0/spec/idl.rst +++ b/docs/source-2.0/spec/idl.rst @@ -184,13 +184,14 @@ string support defined in :rfc:`7405`. Mixins :[`SP`] %s"with" [`WS`] "[" [`WS`] 1*(`ShapeId` [`WS`]) "]" EnumShape :`EnumTypeName` `SP` `Identifier` [`Mixins`] [`WS`] `EnumShapeMembers` EnumTypeName :%s"enum" / %s"intEnum" - EnumShapeMembers :"{" [`WS`] 1*(`TraitStatements` `Identifier` [`ValueAssignment`] [`WS`]) "}" + EnumShapeMembers :"{" [`WS`] 1*(`EnumShapeMember` [`WS`]) "}" + EnumShapeMember :`TraitStatements` `Identifier` [`ValueAssignment`] ValueAssignment :[`SP`] "=" [`SP`] `NodeValue` [`SP`] [`Comma`] `BR` AggregateShape :`AggregateTypeName` `SP` `Identifier` [`ForResource`] [`Mixins`] [`WS`] `ShapeMembers` AggregateTypeName :%s"list" / %s"map" / %s"union" / %s"structure" ForResource :`SP` %s"for" `SP` `ShapeId` - ShapeMembers :"{" [`WS`] *(`TraitStatements` `ShapeMember` [`WS`]) "}" - ShapeMember :(`ExplicitShapeMember` / `ElidedShapeMember`) [`ValueAssignment`] + ShapeMembers :"{" [`WS`] *(`ShapeMember` [`WS`]) "}" + ShapeMember :`TraitStatements` (`ExplicitShapeMember` / `ElidedShapeMember`) [`ValueAssignment`] ExplicitShapeMember :`Identifier` [`SP`] ":" [`SP`] `ShapeId` ElidedShapeMember :"$" `Identifier` EntityShape :`EntityTypeName` `SP` `Identifier` [`Mixins`] [`WS`] `NodeObject`