[sv-bc] Query regarding pattern matching

From: Moumita <moumita_at_.....>
Date: Tue Sep 04 2007 - 01:56:49 PDT
Hi,
The tagged expression is present in two places of BNF in the 1800 SV LRM.

LRM sec(10.4.1) specifies -

pattern ::= . variable_identifier
| .*
| constant_expression
| tagged member_identifier [ pattern ]
| '{ pattern { , pattern } }
| '{ member_identifier : pattern { , member_identifier : pattern } }

Also LRM(sec 8.14) specifies -
expression ::= ...
 | tagged_union_expression

tagged_union_expression ::= tagged member_identifier [ expression ]

Since 'constant_expression' is derived from 'expression', so it tagged 
expression can be represented in two forms from LRM, which is confusing. 
For the small snippet:

out1 = t12 matches (tagged t1 8'b11001101) ? 1 :  0 ;

will "tagged t1 8'b11001101" be considered as  
'pattern-constant_expression' or 'pattern-tagged member_identifier [ 
pattern ]'?


Thanks,

Moumita




-- 
This message has been scanned for viruses and
dangerous content by MailScanner, and is
believed to be clean.
Received on Tue Sep 4 02:01:32 2007

This archive was generated by hypermail 2.1.8 : Tue Sep 04 2007 - 02:03:15 PDT