| Next | Tricks of the Wizards | 131 |
local confines a change to a block
We saw:
{ local *F = \&VeryLongName::SomeFunction;
F(...);
}
{ local $| = 1;
$rc = print $self "";
}
{ local $/; $code = <$fh> }
Wouldn't it be nice to be able to do this:
{ local chdir $DIR;
...
}
# Old directory is restored here
| Next | ![]() |
Copyright © 2003 M. J. Dominus |