This project is read-only.
1

Resolved

Rename OmittedArraySizeExpressionSyntax to OmittedArrayRankExpressionSyntax

description

I tried to use SyntaxFactory to create a TypeSyntax for an array type. When I got to SyntaxFactory.ArrayRankSpecifier, I tried to find something with the word "Rank" (Intellisense) in what SyntaxFactory provides. This did not bring up OmittedArraySizeExpression for obvious reasons.

OmittedArraySizeExpression[Syntax] really looks like the odd one out since everything else around is ArrayRank and should be named OmittedArrayRankExpression[Syntax].

comments

VSadov wrote Nov 15, 2014 at 12:47 AM

I believe the distinction is intentional. The rank specifier may specify multiple array sizes if array is multidimentsional. Like [1,2, , 4] . Note that the third dimension's size is omitted. In the syntax tree the sizes are represented as a separated list {size, separator, size, separator. . . } , so there must be a node to represent the absence of a particular size. That is where omitted size is used.