[sv-ac] local variables and typed formal arguments

From: John Havlicek <john.havlicek_at_.....>
Date: Wed Aug 22 2007 - 04:48:06 PDT
Hi Folks:

There were some comments made in yesterday's meeting
about passing local variables to typed formal arguments
and whether it is legal or illegal.

I think we should be careful about saying, in general,
that passing a local variable as an entire actual argument
or as a subexpression of an actual argument is illegal if
the corresponding formal has a type.

I don't think there is any problem with passing a local
variable to a typed formal argument as long as the formal 
is not itself treated as a local variable, e.g. by assigning 
to the formal in a match item.

In 16.7.1, we have

  Exporting values of local variables through typed formal
  arguments is not supported.

I know this sentence has been rewritten in some of the 
proposals, but the scope of the restriction remains limited
to the exporting of values, i.e., passing _out_ the value
assigned within a sequence so that it is visible in the 
context of the instantiation of the sequence.

J.H.

-- 
This message has been scanned for viruses and
dangerous content by MailScanner, and is
believed to be clean.
Received on Wed Aug 22 04:48:23 2007

This archive was generated by hypermail 2.1.8 : Wed Aug 22 2007 - 04:48:31 PDT