In Section 4.14 ADD (existing text in purple)

 

Queues are declared using the same syntax as unpacked arrays, but specifying $ as the array size. The maxi­mum size of a queue can be limited by specifying its optional right bound (last index).

 

variable_dimension ::=                                                                                                           // from Annex A.2.4

 { sized_or_unsized_dimension }

| associative_dimension

| queue_dimension

 

queue_dimension ::= [ $ [ : constant_expression ] ]                                                        // from Annex A.2.5

Syntax 4-8 — Declaration of queue dimension

 

For example:

 

byte q1[$];                        // A queue of bytes

string names[$] = { "Bob" };       // A queue of strings with one element

integer Q[$] = { 3, 2, 7 };        // An initialized queue of integers

bit q2[$:255];                     // A queue whose maximum size is 256 bits

 

The empty array literal {} is used to denote an empty queue. If an initial value is not provided in the decla­ration, the queue variable is initialized to the empty queue.

 

ADD the following item to the end of the bulleted item list in section 4.14.1

 

Ύ      A queue declared with a right bound [$:N] shall be limited to the indexes 0 through N (its maximum size will be N+1). An index that lies outside these limits shall be invalid, therefore, a write operation past the end of the queue shall be ignored and issue a warning. The warning can be issued at either compile time or run time, as soon as it is possible to determine that the index lies outside the queue limit.

 

 

 

Section A.2.4, A.2.5, A.2.11, A.8.1, A.8.3, A.8.4, A.8.5, A.8.7, Syntax 3-6, Syntax 20-4
Queues

Make the following changes to the above sections.

In A.2.4, REPLACE

            variable_dimension ::=

 { sized_or_unsized_dimension }

            |           associative_dimension

WITH

            variable_dimension ::=

 { sized_or_unsized_dimension }

            |           associative_dimension

            |           queue_dimension

 

In A.2.5, ADD

            queue_dimension ::= [ $ [ : constant_expression ] ]

 

In A.2.11 and Syntax 20-4, REPLACE

            open_value_range ::=

                        value_range

            |           [ expression : $ ]

            |           [ $ : expression ]

WITH

            open_value_range ::= value_range

and ADD the following footnote

            It shall be legal to use the $ primary in an open_value_range of the form [ expression : $ ]  or [ $ : expression ].

 

In A.8.1, ADD

            empty_queue ::= { }

and ADD the following footnote

            { }  shall only be legal in the context of  a queue.

 

In  A.8.3, REPLACE

            range_expression ::=

                        expression

            |           msb_constant_expression : lsb_constant_expression

            |           base_expression +: width_constant_expression

            |           base_expression –: width_constant_expression

WITH

            range_expression ::= expression | range_or_indexed_range

            range_or_indexed_range ::= range | indexed_range

            indexed_range ::=

                        base_expression +: width_constant_expression

            |           base_expression –: width_constant_expression

 

In  A.8.3, REPLACE

            constant_range_expression ::=

                        constant_expression

            |           msb_constant_expression : lsb_constant_expression

            |           constant_base_expression +: width_constant_expression

            |           constant_base_expression –: width_constant_expression

WITH

            constant_range_expression ::= constant_expression | constant_range_or_indexed_range

            constant_range_or_indexed_range ::= range | constant_indexed_range

            constant_indexed_range ::=

                        constant_base_expression +: width_constant_expression

            |           constant_base_expression –: width_constant_expression

 

In A.8.4, ADD

            select ::= { [ expression ] }  [ [ range_or_indexed_range ] ]

            constant_select ::=  { [ expression ] }  [ [ range_or_indexed_range ] ]

 

In A.8.4, ADD

            primary_literal ::= number | time_literal | unbased_unsized_literal

 

In A.8.4, ADD

constant_cast 13 ::=

            casting_type ‘ ( constant_expression )

|           casting_type ‘ constant_concatenation

|           casting_type ‘ constant_multiple_concatentation

 

In A.8.4, ADD

cast 13 ::=

            casting_type ‘ ( expression )

|           casting_type ‘ concatenation

|           casting_type ‘ multiple_concatentation

 

In Syntax 3-6, REPLACE the excerpts from constant_primary and primary WITH the definitions of constant_cast and cast.

           

In A.8.4, REPLACE

            constant_primary ::=

                        constant_concatentation

            |           constant_function_call

            |           ( constant_mintypmax_expression )

            |           constant_multiple_concatenation

            |           genvar_identifier

            |           number

            |           enum_identifier

            |           parameter_identifier

            |           specparam_identifier

            |           casting_type ‘ ( constant_expression )

            |           casting_type ‘ constant_concatenation

            |           casting_type ‘ constant_multiple_concatenation

            |           time_literal

            |           ‘0 | ‘1 | ‘z | ‘Z | ‘x | ‘X 13

WITH

            constant_primary ::=

                        primary_literal

            |           parameter_identifier

            |           specparam_identifier

            |           genvar_identifier

            |           enum_identifier

            |           constant_concatentation

            |           constant_multiple_concatenation

            |           constant_function_call

            |           ( constant_mintypmax_expression )

            |           constant_cast

 

 

In A.8.4, REPLACE

            primary ::=

                        number

            |           [ implicit_class_handle . ] hierarchical_identifier

 { [ expression ] }  [ [ range_expression ] ]

            |           concatenation

            |           multiple_concatenation

            |           function_call

            |           system_function_call

            |           class_scope :: identifier

 { [ expression ] } [ [ range_expression ] ]

            |           ( mintypmax_expression )

            |           casting_type ‘ ( expression )

            |           casting_type ‘ concatenation

            |           casting_type ‘ multiple_concatenation

            |           streaming_expression

            |           time_literal

            |           ‘0 | ‘1 | ‘z | ‘Z | ‘x | ‘X 13

            |           null

WITH

            primary ::=

                        primary_literal

            |           [ implicit_class_handle . ] hierarchical_identifier select

|           class_scope :: identifier select

            |           empty_queue

            |           concatenation

            |           multiple_concatenation

            |           function_call

            |           system_function_call

            |           ( mintypmax_expression )

            |           cast

            |           streaming_expression

            |           $

            |           null

and ADD the following footnote to the $ option

            The $ primary shall be legal only in a select for a queue variable or in an open_value_range.

 

In A.8.5, REPLACE

            net_lvalue :=

                        hierarchical_net_identifer

{ [ constant_expression ] }  [ [ constant_range_expression ] ]

            |           { net_lvalue { , net_lvalue } }

WITH

            net_lvalue :=

                        hierarchical_net_identifer constant_select

            |           { net_lvalue { , net_lvalue } }

 

In A.8.5, REPLACE

            variable_lvalue :=

                        hierarchical_variable_identifer

{ [ expression ] }  [ [ range_expression ] ]

            |           { variable_lvalue { , variable_lvalue } }

WITH

            variable_lvalue :=

                        hierarchical_variable_identifer select

            |           { variable_lvalue { , variable_lvalue } }

 

In A.8.7, ADD

unbased_unsized_literal ::= ‘0 | ‘1 | ‘z_or_x  13

and in footnote 13 REPLACE

            “constant_primary or primary”

WITH

            “unbased_unsized_literal”