in reply to Re: Back compatibility from v5.6.1 to v5.004_02
in thread Back compatibility from v5.6.1 to v5.004_02

use vars , not  use var. Example: use vars '$varname', '@varname'; instead of our $varname; our @varname;

Update: single-quote vars instead of double quote.

Replies are listed 'Best First'.
Re: Re: Re: Back compatibility from v5.6.1 to v5.004_02
by Anonymous Monk on Mar 03, 2004 at 04:38 UTC
    Watch yourself :)
    use strict; use warnings; use vars "$varname", "@varname"; __END__ Possible unintended interpolation of @varname in string at - line 3. Global symbol "$varname" requires explicit package name at - line 3. Global symbol "@varname" requires explicit package name at - line 3. BEGIN not safe after errors--compilation aborted at - line 3.