Perl Compatible Regular Expressions
Sign in to saveAlso known as PCRE, libpare, PCRE383, PCRE386, libpcre386, [^: space:]
software library for interpreting regular expressions
In the Vinony graph
Vinony's link graph records 36 inbound references to Perl Compatible Regular Expressions, and connects out to Unicode, operating system and C.
It sits within the topics C (programming language) libraries, Pattern matching and Perl.
Vinony links it to 13 Wikipedia language editions.
Source code
The PCRE2 library is free and open-source (BSD licence), and permitted in proprietary software. It supports Unicode matching and a very wide range of regular expression features. It accepts input in various character encodings, and optionally includes a highly performant JIT matching engine . PCRE2 is mature and highly-trusted : bundled in dozens or hundreds of open-source and commercial products, such as Excel, Safari, Apache, and Git, and used as the basis for regular expressions in several programming languages including PHP and R. 4. Finally, PCRE2 is also bundled by various downstream package managers (such as Linux distributions, or vcpkg). These are provided by third parties, not the PCRE2 project. The PCRE2 API supports strings in 8-bit, 16-bit, and 32-bit encodings, with or without UTF encoding. There is also EBCDIC support. The default regular expression dialect closely matches the syntax and behaviour of Perl 5, with PCRE2-specific extensions. A wide variety of granular flags can be passed to the PCRE2 API to customise this to more closely follow other dialects such as JavaScript or Python. PCRE2 has a third matching engine, using a DFA engine which is generally slower, but has worst-case polynomial matching time and is able to find the POSIX-style "leftmost-longest" match. As well as the PCRE2 API, the library also offers a POSIX-compatible header and regexec() function. However, this does not provide the ability to pass PCRE2 flags, so we recommend users consume the PCRE2 API if possible. For third-party documentation, see further: A curated summary of changes for each PCRE release, and some excellent tutorials on PCRE2 on the RexEgg website. Jan Goyvaerts' popular Regular-Expressions.info site includes information about PCRE2 as well as tutorials and highly detailed comparisons of PCRE2 to other regular expression dialects. Jeffrey Friedl's book Mastering Regular Expressions includes chapters on Perl and PCRE, and is available in print and online via O'Reilly Media. Our continuous integration tests on Linux (GCC and Clang, glibc and musl), Windows (MSVC and MinGW-x64), and macOS (Clang), as well as FreeBSD , OpenBSD , Solaris (Oracle Studio cc ), and z/OS ( xlc and ibm-clang ). Other systems are likely to work (including mobile, embedded platforms, and commercial UNIX systems), but these are not tested continuously by the PCRE2 maintainers. Users are encouraged to run the full PCRE2 test suite when compiling for any new platform. We are aware of working ports to VMS and z/OS (PCRE2 supports EBCDIC). PCRE2 releases support CMake for building, and for UNIX platforms include a ./configure script built by Autoconf. Build files for the Bazel build system and zig build are also included. Integrating PCRE2 with other systems can be done by including the .c files in an existing project. Please see the files README and NON-AUTOTOOLS-BUILD for full build documentation, as well as the man pages, including man pcre2/doc/pcre2build.3 . PCRE2 is released under the BSD 3-clause licence with a PCRE2 Exception. It is open-source and also corporate-friendly. See LICENCE for legal text. See AUTHORS for details of the current maintainers of PCRE2 and acknowledgements of its contributors, including Philip Hazel, the original author. Join the community by reporting issues or asking questions via GitHub issues. We welcome feedback and proposals. Contributions ranging from bug fixes to feature requests are welcome, and can be made via GitHub pull requests. Release announcements will be made via the [email protected] mailing list, where you can also start discussions about PCRE2 issues and development. You can browse the list archives.
Excerpt from the source-code README · 12,783 chars · not written by Vinony
Wikidata facts
- Instance of
- software library
- Official website
- pcre.org
- Has use
- pattern matching
Show 9 more facts
- Stack Exchange tag
- stackoverflow.com/tags/pcre
- copyright license
- 3-clause BSD License
- programmed in
- C
- software version identifier
- 10.47
- source code repository URL
- vcs.pcre.org/pcre2
- operating system
- Microsoft Windows
- issue tracker URL
- github.com/PCRE2Project/pcre2/issues
- user manual URL
- pcre.org/original/doc/html/index.html
via Wikidata · CC0