RE: [sv-bc] Function return values

From: Jonathan Bromley <jonathan.bromley_at_.....>
Date: Thu Mar 01 2007 - 02:32:48 PST
Arturo,

> The two mechanisms ought to be completely equivalent. Hence, a return
> statement must update the variable associated with the function name,
> just like the assignment form.

I completely agree with you, and so do all the simulators I've tried.  
However, I suggest that this should probably be explicit in the LRM.

Also, given this behaviour, there is surely no reason to forbid 
the form
  return;
in a value-returning function; it should provide early exit with
the return value being whatever is in the function-name variable
at that time.

Thanks
-- 
Jonathan Bromley, Consultant

DOULOS - Developing Design Know-how
VHDL * Verilog * SystemC * e * Perl * Tcl/Tk * Project Services

Doulos Ltd. Church Hatch, 22 Market Place, Ringwood, Hampshire, BH24 1AW, UK
Tel: +44 (0)1425 471223                   Email: jonathan.bromley@doulos.com
Fax: +44 (0)1425 471573                           Web: http://www.doulos.com

The contents of this message may contain personal views which 
are not the views of Doulos Ltd., unless specifically stated.

-- 
This message has been scanned for viruses and
dangerous content by MailScanner, and is
believed to be clean.
Received on Thu Mar 1 02:33:24 2007

This archive was generated by hypermail 2.1.8 : Thu Mar 01 2007 - 02:33:35 PST