RE: [sv-ec] out-of-scope definition of typedef, nested class.

From: Mirek Forczek <mirekf_at_.....>
Date: Thu Mar 27 2008 - 02:32:01 PDT
Semantically the A::B class is defined in A scope anyway, only the
definition text would be placed out-of-block.
 
What is the point behind restriction for the typedef to completely defined
before the end of enclosing scope ?
 
The "completely defined" requirement seems to be too restrictive for a such
complex type as class, and possibly could be relaxed a little (?).
 
The out-of-block declaration style supports incremental compilation.
 
Language already allows ouf-of-block declarations for class methods.
 
It would be convenient (and consistent with already existing language
capabilities) to allow the same for nested classes definitions.
 
 
Regards,
Mirek

  _____  

From: owner-sv-ec@server.eda.org [mailto:owner-sv-ec@server.eda.org] On
Behalf Of Arturo Salz
Sent: 26 marca 2008 18:28
To: danielm; sv-ec@server.eda.org
Subject: RE: [sv-ec] out-of-scope definition of typedef, nested class.



This is not a just a syntactical limitation. It is a conscious restriction
that requires the class to be defined in the same hierarchical scope.

 

            Arturo

 

From: owner-sv-ec@eda.org [mailto:owner-sv-ec@eda.org] On Behalf Of Rich,
Dave
Sent: Wednesday, March 26, 2008 7:10 AM
To: danielm; sv-ec@eda.org
Subject: RE: [sv-ec] out-of-scope definition of typedef, nested class.

 

There is no syntax to do this that I know of. Also, a forward typedef must
be completely defined before the end the enclosing scope that it appears in.

 

  _____  

From: owner-sv-ec@server.eda.org [mailto:owner-sv-ec@server.eda.org] On
Behalf Of danielm
Sent: Wednesday, March 26, 2008 6:22 AM
To: sv-ec@server.eda.org
Subject: [sv-ec] out-of-scope definition of typedef, nested class.

 

Is there a way for defining nested class out-of-scope - similarly to extern
methods?

 

Is below legal?

 

-------- classA.h -----

 

class A;

 

    typedef class B;

 

endclass

 

-----------------------------

 

 

------ classA.sv ----------

 

`include "classA.h"

 

class A::B

 

endclass

 

--------------------------------

 

DANiel


-- 
This message has been scanned for viruses and 
dangerous content by  <http://www.mailscanner.info/> MailScanner, and is 
believed to be clean. 
-- 
This message has been scanned for viruses and 
dangerous content by  <http://www.mailscanner.info/> MailScanner, and is 
believed to be clean. 


-- 
This message has been scanned for viruses and 
dangerous content by  <http://www.mailscanner.info/> MailScanner, and is 
believed to be clean. 

-- 
This message has been scanned for viruses and
dangerous content by MailScanner, and is
believed to be clean.
Received on Thu Mar 27 02:36:42 2008

This archive was generated by hypermail 2.1.8 : Thu Mar 27 2008 - 02:37:33 PDT