1Regexp::Common::whitespUasceer(3C)ontributed Perl DocumeRnetgaetxipo:n:Common::whitespace(3)
2
3
4

NAME

6       Regexp::Common::whitespace -- provides a regex for leading or trailing
7       whitescape
8

SYNOPSIS

10           use Regexp::Common qw /whitespace/;
11
12           while (<>) {
13               s/$RE{ws}{crop}//g;           # Delete surrounding whitespace
14           }
15

DESCRIPTION

17       Please consult the manual of Regexp::Common for a general description
18       of the works of this interface.
19
20       Do not use this module directly, but load it via Regexp::Common.
21
22       $RE{ws}{crop}
23
24       Returns a pattern that identifies leading or trailing whitespace.
25
26       For example:
27
28               $str =~ s/$RE{ws}{crop}//g;     # Delete surrounding whitespace
29
30       The call:
31
32               $RE{ws}{crop}->subs($str);
33
34       is optimized (but probably still slower than doing the s///g explic‐
35       itly).
36
37       This pattern does not capture under "-keep".
38

HISTORY

40        $Log: whitespace.pm,v $
41        Revision 2.103  2003/07/04 13:34:05  abigail
42        Fixed assignment to
43
44        Revision 2.102  2003/02/11 09:48:54  abigail
45        Added
46
47        Revision 2.101  2003/02/01 22:55:31  abigail
48        Changed Copyright years
49
50        Revision 2.100  2003/01/21 23:19:40  abigail
51        The whole world understands RCS/CVS version numbers, that 1.9 is an
52        older version than 1.10. Except CPAN. Curse the idiot(s) who think
53        that version numbers are floats (in which universe do floats have
54        more than one decimal dot?).
55        Everything is bumped to version 2.100 because CPAN couldn't deal
56        with the fact one file had version 1.10.
57
58        Revision 1.2  2002/08/27 16:59:39  abigail
59        Fix POD
60
61        Revision 1.1  2002/08/27 16:58:59  abigail
62        Initial checkin.
63

SEE ALSO

65       Regexp::Common for a general description of how to use this interface.
66

AUTHOR

68       Damian Conway (damian@conway.org)
69

MAINTAINANCE

71       This package is maintained by Abigail (regexp-common@abigail.nl).
72

BUGS AND IRRITATIONS

74       Bound to be plenty.
75
76       For a start, there are many common regexes missing.  Send them in to
77       regexp-common@abigail.nl.
78
80            Copyright (c) 2001 - 2003, Damian Conway. All Rights Reserved.
81              This module is free software. It may be used, redistributed
82             and/or modified under the terms of the Perl Artistic License
83                   (see http://www.perl.com/perl/misc/Artistic.html)
84
85
86
87perl v5.8.8                       2003-03-23     Regexp::Common::whitespace(3)
Impressum