Re: [sv-ec] Re: [sv-bc] Forward typedef of parameterized class

From: Gordon Vreugdenhil <gordonv_at_.....>
Date: Thu Jan 31 2008 - 07:18:48 PST
Mantis 2211 deals with this issue directly.  Please take
a look at it.

Gord.

Surya Pratik Saha wrote:
> Hi,
> Continuing on Shweta's query, is the following forward typedef usage of 
> class allowed:
> module top;
>    typedef C;
>    typedef C::p mydef;
>    class C;
>        typedef int p;
>    endclass
> endmodule
> 
> Most of the simulators fail. But some pass too. I think LRM should be 
> clear enough how much flexibility to be provided for forward typedef 
> reference of class.
> 
> Regards
> Surya
> 
> 
> 
> -------- Original Message  --------
> Subject: Re:[sv-bc] Forward typedef of parameterized class
> From: shweta@mirafra.com
> To: Surya Pratik Saha <spsaha@cal.interrasystems.com>
> Cc: sv-bc@eda.org
> Date: Thursday, January 31, 2008 4:22:26 PM
>> Hi Surya,
>>
>> My question is specific about forward typedef of parameterized class.
>> The LRM says nothing about it.
>>
>> Regards,
>> Shweta.
>>
>>  
>>> Hi Shweta,
>>> I already asked it (the mail is attached). But I did not get any reply
>>> on that.
>>>
>>> Regards
>>> Surya
>>>
>>>
>>>
>>> -------- Original Message  --------
>>> Subject: [sv-bc] Forward typedef of parameterized class
>>> From: shweta@mirafra.com
>>> To: sv-bc@eda.org
>>> Date: Thursday, January 31, 2008 3:39:25 PM
>>>    
>>>> Hi All,
>>>>
>>>> Is foward typedef of parameterized class allowed?
>>>>
>>>> For the following testcase :
>>>>
>>>> package pkg;
>>>>     typedef B;
>>>>     class A #(parameter int p1 = 1);
>>>>         B b1;
>>>>     endclass
>>>>     class B #(parameter int p1 = 1);
>>>>             A #(p1) a1;
>>>>     endclass
>>>> endpackage
>>>>
>>>> MTI gives following error :
>>>> ** Error: test1.sv(2): Forward typedef for parameterized class 'B' not
>>>> allowed
>>>>
>>>> Regards,
>>>> Shweta.
>>>>
>>>>
>>>>       
>>>
>>>
>>>     
>>
>>
>>
>>
>>
>>   
> 
> 
> 
> 
> 

-- 
--------------------------------------------------------------------
Gordon Vreugdenhil                                503-685-0808
Model Technology (Mentor Graphics)                gordonv@model.com


-- 
This message has been scanned for viruses and
dangerous content by MailScanner, and is
believed to be clean.
Received on Thu Jan 31 07:19:40 2008

This archive was generated by hypermail 2.1.8 : Thu Jan 31 2008 - 07:20:04 PST