754932a8a1ba9f0b0ad143e10d8db373c3c7c458
[pkg-perl] / deb-src / libperl-critic-perl / libperl-critic-perl-1.088 / t / BuiltinFunctions / RequireBlockMap.run
1 ## name Basic passing
2 ## failures 0
3 ## cut
4
5 map {$_++}   @list;
6 @foo = map {$_++}   @list;
7 map( {$_++}   @list );
8 @foo = map( {$_++}   @list );
9 map();
10 @foo = map();
11 {map}; # for Devel::Cover
12 malp $_++, @list; # deliberately misspell map
13
14 #-----------------------------------------------------------------------------
15
16 ## name Basic failure
17 ## failures 2
18 ## cut
19
20 map $_++, @list;
21 @foo = map $_++, @list;
22
23 #-----------------------------------------------------------------------------
24
25 ## name Things that may look like a map, but aren't
26 ## failures 0
27 ## cut
28
29 $hash1{map} = 1;
30 %hash2 = (map => 1);
31
32 #-----------------------------------------------------------------------------
33
34 ##############################################################################
35 #      $URL: http://perlcritic.tigris.org/svn/perlcritic/trunk/Perl-Critic/t/BuiltinFunctions/RequireBlockMap.run $
36 #     $Date: 2008-03-16 17:40:45 -0500 (Sun, 16 Mar 2008) $
37 #   $Author: clonezone $
38 # $Revision: 2187 $
39 ##############################################################################
40
41 # Local Variables:
42 #   mode: cperl
43 #   cperl-indent-level: 4
44 #   fill-column: 78
45 #   indent-tabs-mode: nil
46 #   c-indentation-style: bsd
47 # End:
48 # ex: set ts=8 sts=4 sw=4 tw=78 ft=perl expandtab shiftround :