README
1NAME
2
3 bareword::filehandles - disables bareword filehandles
4
5VERSION
6
7 version 0.007
8
9SYNOPSIS
10
11 no bareword::filehandles;
12
13 open FH, $file # dies
14 open my $fh, $file; # doesn't die
15
16 print FH $string # dies
17 print STDERR $string # doesn't die
18
19DESCRIPTION
20
21 This module lexically disables the use of bareword filehandles with
22 builtin functions, except for the special builtin filehandles STDIN,
23 STDOUT, STDERR, ARGV, ARGVOUT and DATA.
24
25METHODS
26
27 unimport
28
29 Disables bareword filehandles for the remainder of the scope being
30 compiled.
31
32 import
33
34 Enables bareword filehandles for the remainder of the scope being
35 compiled.
36
37LIMITATIONS
38
39 Filetest operators (-X) can not be checked on Perl versions before
40 5.32, because hooking the op check function for these breaks stacked
41 tests, e.g. -f -w -x $file.
42
43SEE ALSO
44
45 perlfunc, B::Hooks::OP::Check.
46
47AUTHOR
48
49 Dagfinn Ilmari Mannsåker <ilmari@ilmari.org>
50
51COPYRIGHT AND LICENSE
52
53 This software is copyright (c) 2011 - 2016 by Dagfinn Ilmari Mannsåker.
54
55 This is free software; you can redistribute it and/or modify it under
56 the same terms as the Perl 5 programming language system itself.
57
58