8.166 vars (Perl in a Nutshell)

Perl in a Nutshell

Perl in a NutshellSearch this book
Previous: 8.165 User::pwentChapter 8
Standard Modules
Next: 8.167 vmsish
 

8.166 vars

Pragma that, given a list of variable names, predeclares all variables in the list, making sure they are available to routines whose loading is delayed (e.g., routines that are loaded by the AutoLoader or SelfLoader). This allows you to use the variables under use strict. The vars pragma also disables warnings about typographical errors.

use vars qw($var1 @var2 %var3);


Previous: 8.165 User::pwentPerl in a NutshellNext: 8.167 vmsish
8.165 User::pwentBook Index8.167 vmsish

Library Navigation Links

Copyright © 2001 O'Reilly & Associates. All rights reserved.