That's a very good point! I think this loophole would have to be closed by extending the following restriction (in section 13.5.5): > It shall be illegal to omit the parenthesis in a > directly recursive nonvoid class function method call that is not hierarchically qualified. It would have to say: A function which returns a class, enum, or other object which has defined methods cannot be used as a method_call_root if its argument parentheses are omitted; the method call syntax in that case will be read as a hierarchical reference to static local names in the function scope. Greg Rich, Dave wrote: > OK then, what is the result of this example? > > module top; > > typedef enum {A,B,C,D,E,F,G} letters; > > function letters funct; > letters next = C; > return E; > endfunction > > initial begin > $display("%p",funct.next ); > end > > endmodule > > > >> -----Original Message----- >> From: owner-sv-ec@server.eda.org [mailto:owner-sv-ec@server.eda.org] > On >> Behalf Of Brad Pierce >> Sent: Friday, April 25, 2008 8:57 AM >> To: sv-ec@server.eda.org; sv-bc@server.eda.org >> Subject: RE: [sv-bc] RE: [sv-ec] svlog enum function usage & maven > query >> Shalom, >> >> See the first bullet in >> >> http://www.eda-stds.org/sv-ec/hm/1519.html >> >> I think such a use of class methods was considered so obvious that a >> need for special additional text did not occur to anybody. >> >> -- Brad >> >> -----Original Message----- >> From: Bresticker, Shalom [mailto:shalom.bresticker@intel.com] >> Sent: Friday, April 25, 2008 7:26 AM >> To: Brad Pierce; sv-ec@eda.org; sv-bc@eda.org >> Subject: RE: [sv-bc] RE: [sv-ec] svlog enum function usage & maven > query >> Brad, >> >> This was discussed in the recent past by email, with no resolution. I >> don't think there is any strong evidence in the LRM that this was >> intended to be allowed. There is no statement to that effect, nor is >> there any such example. Such a feature would not be a corner case, but > a >> fundamental part of the method functionality, and it would have had to >> be stated explicitly. >> >> I opened Mantis 2272 on this. >> >> Shalom >> >>> -----Original Message----- >>> From: owner-sv-ec@server.eda.org >>> [mailto:owner-sv-ec@server.eda.org] On Behalf Of Brad Pierce >>> Sent: Thursday, April 24, 2008 9:14 PM >>> To: sv-ec@server.eda.org; sv-bc@server.eda.org; >>> sv-ac@server.eda-stds.org >>> Subject: RE: [sv-bc] RE: [sv-ec] svlog enum function usage & >>> maven query >>> >>> Greg, >>> >>> primary ::= function_subroutine_call >>> ::= subroutine_call >>> ::= method_call >>> >>> The LRM says "The next() method returns the Nth next >>> enumeration value (default is the next one) starting from the >>> current value of the given VARIABLE." >>> >>> However, this is probably a mistake and in fact, the method >>> can be used with any enumeration value, even an anonymous >>> one, and Kapil's example is actually legal. >> --------------------------------------------------------------------- >> Intel Israel (74) Limited >> >> This e-mail and any attachments may contain confidential material for >> the sole use of the intended recipient(s). Any review or distribution >> by others is strictly prohibited. If you are not the intended >> recipient, please contact the sender and delete all copies. >> >> >> -- >> This message has been scanned for viruses and >> dangerous content by 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 Fri Apr 25 15:05:49 2008
This archive was generated by hypermail 2.1.8 : Fri Apr 25 2008 - 15:06:24 PDT