[sv-ec] question about the bnf for function new

From: Francoise Martinolle <fm_at_.....>
Date: Thu Dec 07 2006 - 11:00:13 PST
This is a minor comment about the bnf for the declaration of the class
constructor.
 
The BNF for the constructor new makes the following example illegal:
 
        function new(input string name,input urm_named_object parent);
            begin
                super.new(name, parent);
                begin
                    
                end
            end
        endfunction

If the enclosing begin/end block is deleted, the example is legal.
As far as I can tell, super.new is in both examples the first statement
executed. So was it really intended to make that example illegal?
 
 
The bnf is:
 
class_constructor_declaration ::=

function [ class_scope ] new [ ( [ tf_port_list ] ) ] ;

{ block_item_declaration }

[ super . new [ ( list_of_arguments ) ] ; ]

{ function_statement_or_null }

endfunction [ : new ]
Received on Thu Dec 7 12:45:53 2006

This archive was generated by hypermail 2.1.8 : Thu Dec 07 2006 - 12:46:10 PST