Re: [sv-bc] Serious issue with default expressions for task and function arguments

From: Paul Graham <pgraham_at_.....>
Date: Thu Mar 03 2005 - 11:18:47 PST
> Gord mentions that binding different default values to different calls 
> of the same function depending on the context of the call may be 
> unreasonable and not in the context of separate compilation. However,
> that is precisely the situation in C++. Consider the example below, which

Your example still illustrates lexical binding.  The meaning of the
default value is fixed at the point of the compilation.  In your
example, the function is compiled twice, with a different default
value each time.

The original LRM language suggested that the meaning of the default
value depended on the run-time call environment ("evaluated in the
context of the caller").  This would be dynamic binding.  A cool
feature, but not very much in the spirit of verilog.

Paul
Received on Thu Mar 3 11:18:52 2005

This archive was generated by hypermail 2.1.8 : Thu Mar 03 2005 - 11:19:01 PST