1Perl::Critic::Policy::CUosPdeeerrLlaC:yo:onCutrtri:it:biPucrt:oe:hdPiobPlieitrcHlya:rD:doCTcoaudbmeseL(na3typaomtu)ito:n:ProhibitHardTabs(3pm)
2
3
4
6 Perl::Critic::Policy::CodeLayout::ProhibitHardTabs - Use spaces instead
7 of tabs.
8
10 This Policy is part of the core Perl::Critic distribution.
11
13 Putting hard tabs in your source code (or POD) is one of the worst
14 things you can do to your co-workers and colleagues, especially if
15 those tabs are anywhere other than a leading position. Because various
16 applications and devices represent tabs differently, they can cause you
17 code to look vastly different to other people. Any decent editor can
18 be configured to expand tabs into spaces. Perl::Tidy also does this
19 for you.
20
21 This Policy catches all tabs in your source code, including POD,
22 quotes, and HEREDOCs. The contents of the "__DATA__" section are not
23 examined.
24
26 Hard tabs in a string are always forbidden (use "\t" instead). But
27 hard tabs in a leading position are allowed when they are used to
28 indent code statements, qw() word lists, and regular expressions with
29 the "/x" modifier. However, if you want to forbid all tabs everywhere,
30 then add this to your .perlcriticrc file:
31
32 [CodeLayout::ProhibitHardTabs]
33 allow_leading_tabs = 0
34
36 Beware that Perl::Critic may report the location of the string that
37 contains the tab, not the actual location of the tab, so you may need
38 to do some hunting. I'll try and fix this in the future.
39
41 Jeffrey Ryan Thalhammer <jeff@imaginative-software.com>
42
44 Copyright (c) 2005-2023 Imaginative Software Systems
45
46 This program is free software; you can redistribute it and/or modify it
47 under the same terms as Perl itself. The full text of this license can
48 be found in the LICENSE file included with this module.
49
50
51
52perl v5.38.0 Perl::Criti2c0:2:3P-o0l9i-c2y5::CodeLayout::ProhibitHardTabs(3pm)