The perlre Reference Manual

Table of Contents

Next: , Previous: , Up: (dir)   [Contents][Index]

The perlre Reference Manual

This is the perlre Reference Manual, version 0.4, generated automatically by Declt version 2.4 "Will Decker" on Wed Jun 20 12:23:11 2018 GMT+0.


Next: , Previous: , Up: Top   [Contents][Index]

1 Introduction

perlre

Regular expression API using CL-PPCRE and CL-INTERPOL with operators known from sed or perl, m// and s/// plus a similar one, d// for split.

Can be useful for code brevity in regex heavy programs.

idea and code from Doug Hoyte's book Let Over Lambda and quicklisp-package let-over-lambda

Synopsis:

(#~s/regex/substitution/imsxge string)
(#~m/regex/[modifier] string)
(#~d/regex/[modifier] string) 


  (let ((stg "hanna")
        (reg "(A)")
        (sub "*\\1*"))

   ; output of both is "h*a*nn*a*" 

   ; perlre
   (#~s/reg/sub/ig stg)

   ; cl-ppcre
   (ppcre:regex-replace-all (ppcre:create-scanner reg :case-insensitive-mode t) stg sub))

See test.lisp for other examples.


Next: , Previous: , Up: Top   [Contents][Index]

2 Systems

The main system appears first, followed by any subsystem dependency.


Previous: , Up: Systems   [Contents][Index]

2.1 perlre

Author

<schatzer.johann@gmail>

License

BSD Simplified — the same as let-over-lambda

Description

s///, m//, d// - regular expression API for CL-PPCRE and CL-INTERPOL

Version

0.4

Dependencies
Source

perlre.asd (file)

Components

Next: , Previous: , Up: Top   [Contents][Index]

3 Files

Files are sorted by type and then listed depth-first from the systems components trees.


Previous: , Up: Files   [Contents][Index]

3.1 Lisp


Next: , Previous: , Up: Lisp files   [Contents][Index]

3.1.1 perlre.asd

Location

perlre.asd

Systems

perlre (system)


Next: , Previous: , Up: Lisp files   [Contents][Index]

3.1.2 perlre/package.lisp

Parent

perlre (system)

Location

package.lisp

Packages

perlre


Previous: , Up: Lisp files   [Contents][Index]

3.1.3 perlre/perlre.lisp

Dependency

package.lisp (file)

Parent

perlre (system)

Location

perlre.lisp

Exported Definitions
Internal Definitions

Next: , Previous: , Up: Top   [Contents][Index]

4 Packages

Packages are listed by definition order.


Previous: , Up: Packages   [Contents][Index]

4.1 perlre

Source

package.lisp (file)

Nickname

pre

Use List

common-lisp

Exported Definitions
Internal Definitions

Next: , Previous: , Up: Top   [Contents][Index]

5 Definitions

Definitions are sorted by export status, category, package, and then by lexicographic order.


Next: , Previous: , Up: Definitions   [Contents][Index]

5.1 Exported definitions


Previous: , Up: Exported definitions   [Contents][Index]

5.1.1 Macros

Macro: ifmatch (TEST O!S) CONSEQ &optional ALTERN
Package

perlre

Source

perlre.lisp (file)

Macro: whenmatch (TEST S) &rest CONSEQ
Package

perlre

Source

perlre.lisp (file)


Previous: , Up: Definitions   [Contents][Index]

5.2 Internal definitions


Next: , Previous: , Up: Internal definitions   [Contents][Index]

5.2.1 Special variables

Special Variable: e-d

evaluating-delimiter

Package

perlre

Source

perlre.lisp (file)


Next: , Previous: , Up: Internal definitions   [Contents][Index]

5.2.2 Macros

Macro: div O!A O!M
Package

perlre

Source

perlre.lisp (file)

Macro: mat O!A O!M
Package

perlre

Source

perlre.lisp (file)

Macro: sub O!A O!M
Package

perlre

Source

perlre.lisp (file)


Previous: , Up: Internal definitions   [Contents][Index]

5.2.3 Functions

Function: mods S

imsxger{d} modifiers, d for digits

Package

perlre

Source

perlre.lisp (file)

Function: segment-reader S C N

to supress string interpolation use single-quote delimiters, #~s”’, #~m”, as in perl, see camelbook page 192, or use an alternate quoting-delimiter doing e.g. (setf perlre::qd #!)

Package

perlre

Source

perlre.lisp (file)

Function: xxx S C N
Package

perlre

Source

perlre.lisp (file)


Previous: , Up: Top   [Contents][Index]

Appendix A Indexes


Next: , Previous: , Up: Indexes   [Contents][Index]

A.1 Concepts

Jump to:   F   L   P  
Index Entry  Section

F
File, Lisp, perlre.asd: The perlre<dot>asd file
File, Lisp, perlre/package.lisp: The perlre/package<dot>lisp file
File, Lisp, perlre/perlre.lisp: The perlre/perlre<dot>lisp file

L
Lisp File, perlre.asd: The perlre<dot>asd file
Lisp File, perlre/package.lisp: The perlre/package<dot>lisp file
Lisp File, perlre/perlre.lisp: The perlre/perlre<dot>lisp file

P
perlre.asd: The perlre<dot>asd file
perlre/package.lisp: The perlre/package<dot>lisp file
perlre/perlre.lisp: The perlre/perlre<dot>lisp file

Jump to:   F   L   P  

Next: , Previous: , Up: Indexes   [Contents][Index]

A.2 Functions

Jump to:   D   F   I   M   S   W   X  
Index Entry  Section

D
div: Internal macros

F
Function, mods: Internal functions
Function, segment-reader: Internal functions
Function, xxx: Internal functions

I
ifmatch: Exported macros

M
Macro, div: Internal macros
Macro, ifmatch: Exported macros
Macro, mat: Internal macros
Macro, sub: Internal macros
Macro, whenmatch: Exported macros
mat: Internal macros
mods: Internal functions

S
segment-reader: Internal functions
sub: Internal macros

W
whenmatch: Exported macros

X
xxx: Internal functions

Jump to:   D   F   I   M   S   W   X  

Next: , Previous: , Up: Indexes   [Contents][Index]

A.3 Variables

Jump to:   E   S  
Index Entry  Section

E
e-d: Internal special variables

S
Special Variable, e-d: Internal special variables

Jump to:   E   S  

Previous: , Up: Indexes   [Contents][Index]

A.4 Data types

Jump to:   P   S  
Index Entry  Section

P
Package, perlre: The perlre package
perlre: The perlre system
perlre: The perlre package

S
System, perlre: The perlre system

Jump to:   P   S