Next: , Previous: , Up: srfi regexps   [Index]


2.39.4 Types and naming conventions

We introduce two new types, regexp and regexp-match, which are disjoint from all other types. We also introduce the concept of an “SRE”, which is not a disjoint type but is a Scheme object following the specification described below.

SRFI-14 defines the char-set type, which can be used as part of an SRE.

In the prototypes below the following naming conventions imply type restrictions:

char-set

A SRFI-14 character set.

cset-sre

An SRE which corresponds to matching a single character out of a set of characters.

end

An exact, non–negative integer, defaulting to the (string-length str).

finish

A procedure ‘(lambda (i regexp-match str obj) ...)’.

obj

Any object.

knil

Any object.

kons

A procedure ‘(lambda (i regexp-match str obj) ...)’.

re

An SRE or pre–compiled regexp object.

regexp-match

A regexp-match object from a successful match.

sre

An SRE as described below.

start

An exact, non–negative integer, defaulting to ‘0’.

str

A string.

subst

A symbolic expression describing a substitution template.

X-or-false

Either an object of type ‘X’ or the #f value.