Skip to content


Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Fetching contributors…

Cannot retrieve contributors at this time

127 lines (88 sloc) 3.846 kb
Release of version 2011041702 of Regexp::Common
The main reason for version 2.122 is a change in the license. You now
have the option to use this software under either the original Artistic
License, the Artistic License 2.0, the MIT license, or the BSD license.
INCOMPATIBLE CHANGE in version 2.119:
The $N settings for the -keep option of US postal codes
($RE {zip} {US} {-keep}) have been changed. See the
Regexp::Common::zip for details.
INCOMPATIBLE CHANGE in version 2.113:
Regexp::Common used to set $; to '='. This no longer happens,
because setting $; breaks Filter::Simple. This means that regexps
of the form $RE{foo}{"-flag=value"} no longer work! They need
to be written as $RE{foo}{"-flag$;value"} or as
$RE{foo}{-flag => "value"}.
When defining patterns using the pattern function, a = still
needs to be used to separate the flag from its default value.
This has not been changed.
We are very sorry for the inconvenience.
Regexp::Common - Provide commonly requested regular expressions
use Regexp::Common;
while (<>) {
and print q{a number\n};
and print q{a ['"`] quoted string\n};
and print q{a /.../ sequence\n};
and print q{balanced parentheses\n};
and print q{a #*@%-ing word\n};
By default, this module exports a single hash (`%RE') that stores or
generates commonly needed regular expressions. Patterns currently
provided include:
* balanced parentheses and brackets
* delimited text (with escapes)
* integers and floating-point numbers in any base (up to 36)
* comments in 44 languages
* offensive language
* lists of any pattern
* IPv4 addresses
* URIs.
* Zip codes.
Future releases of the module will also provide patterns for the
* email addresses
* HTML/XML tags
* mail headers (including multiline ones),
* more URIs
* telephone numbers of various countries
* currency (universal 3 letter format, Latin-1, currency names)
* dates
* binary formats (e.g. UUencoded, MIMEd)
* Credit card numbers.
It's all pure Perl, so just put the .pm files in their appropriate
local Perl subdirectory.
Alternatively, use the common approach:
- untar the archive
- run: perl Makefile.PL
- run: make
- run: make test
- run: make install
Damian Conway ( and Abigail
Abigail (
This software is Copyright (c) 2001 - 2009, Damian Conway and Abigail.
This module is free software, and maybe used under any of the following
1) The Perl Artistic License. See the file COPYRIGHT.AL.
2) The Perl Artistic License 2.0. See the file COPYRIGHT.AL2.
3) The BSD Licence. See the file COPYRIGHT.BSD.
4) The MIT Licence. See the file COPYRIGHT.MIT.
Regexp::Common has been uploaded to the CPAN and is also available from:
Jump to Line
Something went wrong with that request. Please try again.