Macro question

2003-08-02 Thread Abhijit A. Mahabal
This is a rather silly question: The code: macro foo() { return {my $x = 7} } foo; print $x; is equivalent to which of the following? {my $x = 7} print $x; or my $x = 7; print $x; Thanx, abhi.

Re: Macro question

2003-08-02 Thread Larry Wall
On Sat, Aug 02, 2003 at 10:29:05PM -0500, Abhijit A. Mahabal wrote: : This is a rather silly question: : : The code: : macro foo() { return {my $x = 7} } : foo; : print $x; : : is equivalent to which of the following? : : {my $x = 7} : print $x; : : or : :