The esrap-peg Reference Manual

This is the esrap-peg Reference Manual, generated automatically by Declt version 4.0 beta 2 "William Riker" on Mon Feb 26 16:22:10 2024 GMT+0.

Table of Contents


1 Introduction


2 Systems

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


2.1 esrap-peg

A wrapper around Esrap to allow generating Esrap grammars from PEG definitions

Author

Michael Raskin

License

MIT

Dependencies
  • esrap (system).
  • iterate (system).
  • cl-unification (system).
  • alexandria (system).
Source

esrap-peg.asd.

Child Components

3 Files

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


3.1 Lisp


3.1.1 esrap-peg/esrap-peg.asd

Source

esrap-peg.asd.

Parent Component

esrap-peg (system).

ASDF Systems

esrap-peg.


3.1.2 esrap-peg/package.lisp

Source

esrap-peg.asd.

Parent Component

esrap-peg (system).

Packages

esrap-peg.


3.1.3 esrap-peg/util.lisp

Dependency

package.lisp (file).

Source

esrap-peg.asd.

Parent Component

esrap-peg (system).

Internals

3.1.4 esrap-peg/peg.lisp

Dependency

package.lisp (file).

Source

esrap-peg.asd.

Parent Component

esrap-peg (system).

Internals

3.1.5 esrap-peg/peg-functions.lisp

Dependencies
Source

esrap-peg.asd.

Parent Component

esrap-peg (system).

Public Interface

3.1.6 esrap-peg/peg-on-the-fly.lisp

Dependency

package.lisp (file).

Source

esrap-peg.asd.

Parent Component

esrap-peg (system).

Public Interface
Internals

3.1.7 esrap-peg/peg-compile.lisp

Dependencies
Source

esrap-peg.asd.

Parent Component

esrap-peg (system).

Public Interface

3.1.8 esrap-peg/pattern-processing.lisp

Dependency

package.lisp (file).

Source

esrap-peg.asd.

Parent Component

esrap-peg (system).

Public Interface
Internals

4 Packages

Packages are listed by definition order.


4.1 esrap-peg

Source

package.lisp.

Use List
  • common-lisp.
  • esrap.
  • iterate.
Public Interface
Internals

5 Definitions

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


5.1 Public Interface


5.1.1 Special variables

Special Variable: *esrap-peg-matcher-default-abbreviations*
Package

esrap-peg.

Source

pattern-processing.lisp.

Special Variable: *esrap-peg-pattern-package*
Package

esrap-peg.

Source

pattern-processing.lisp.


5.1.2 Macros

Macro: def-peg-fun (name (arg) &rest code)
Package

esrap-peg.

Source

peg-on-the-fly.lisp.

Macro: def-peg-matchers (clauses &key abbreviations package arg)
Package

esrap-peg.

Source

pattern-processing.lisp.

Macro: peg-compile (g)
Package

esrap-peg.

Source

peg-compile.lisp.


5.1.3 Ordinary functions

Function: add-peg-order-rule (node before after)
Package

esrap-peg.

Source

pattern-processing.lisp.

Function: ast-eval (x)
Package

esrap-peg.

Source

peg-on-the-fly.lisp.

Function: basic-parse-peg (g)
Package

esrap-peg.

Source

peg-functions.lisp.

Function: delete-peg-order-rule (node before after)
Package

esrap-peg.

Source

pattern-processing.lisp.

Function: parse-peg-file (f)
Package

esrap-peg.

Source

peg-functions.lisp.

Function: peg-code (g)
Package

esrap-peg.

Source

peg-compile.lisp.


5.2 Internals


5.2.1 Special variables

Special Variable: *character-class-storage*
Package

esrap-peg.

Source

peg.lisp.

Special Variable: *range-list*
Package

esrap-peg.

Source

peg.lisp.

Special Variable: character-range-definer
Package

esrap-peg.

Source

peg-on-the-fly.lisp.

Special Variable: rule-creator
Package

esrap-peg.

Source

peg-on-the-fly.lisp.


5.2.2 Macros

Macro: character-class-rule (&rest clauses)
Package

esrap-peg.

Source

peg.lisp.

Macro: def-ast-rule (name &rest params)
Package

esrap-peg.

Source

peg.lisp.

Macro: define-character-classes ()
Package

esrap-peg.

Source

peg.lisp.


5.2.3 Ordinary functions

Function: abbreviations-into-package (l &optional package)
Package

esrap-peg.

Source

pattern-processing.lisp.

Function: esrap-peg-symbol (x)
Package

esrap-peg.

Source

pattern-processing.lisp.

Function: file-contents (fn)
Package

esrap-peg.

Source

util.lisp.

Function: semantic-checker⎵for⎵character⎵class⎵with⎵clauses⎵(#\n⎵#\r⎵#\t⎵#\'⎵#\"⎵#\[⎵#\]↵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵#\\)⎵ (x)
Package

esrap-peg.

Source

peg.lisp.

Function: semantic-checker⎵for⎵character⎵class⎵with⎵clauses⎵((#\0⎵#\3))⎵ (x)
Package

esrap-peg.

Source

peg.lisp.

Function: semantic-checker⎵for⎵character⎵class⎵with⎵clauses⎵((#\0⎵#\7))⎵ (x)
Package

esrap-peg.

Source

peg.lisp.

Function: semantic-checker⎵for⎵character⎵class⎵with⎵clauses⎵((#\0⎵#\9)⎵(#\a⎵#\f)↵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵(#\a⎵#\f))⎵ (x)
Package

esrap-peg.

Source

peg.lisp.

Function: semantic-checker⎵for⎵character⎵class⎵with⎵clauses⎵((#\0⎵#\9))⎵ (x)
Package

esrap-peg.

Source

peg.lisp.

Function: semantic-checker⎵for⎵character⎵class⎵with⎵clauses⎵((#\a⎵#\z)⎵(#\a⎵#\z)⎵#\_)⎵ (x)
Package

esrap-peg.

Source

peg.lisp.

Function: stream-contents (f)
Package

esrap-peg.

Source

util.lisp.

Function: temporary⎵function⎵to⎵add⎵symbol⎵and⎵into⎵ast (x &rest pos)
Package

esrap-peg.

Source

peg.lisp.

Function: temporary⎵function⎵to⎵add⎵symbol⎵char⎵into⎵ast (x &rest pos)
Package

esrap-peg.

Source

peg.lisp.

Function: temporary⎵function⎵to⎵add⎵symbol⎵class⎵into⎵ast (x &rest pos)
Package

esrap-peg.

Source

peg.lisp.

Function: temporary⎵function⎵to⎵add⎵symbol⎵close⎵into⎵ast (x &rest pos)
Package

esrap-peg.

Source

peg.lisp.

Function: temporary⎵function⎵to⎵add⎵symbol⎵comment⎵into⎵ast (x &rest pos)
Package

esrap-peg.

Source

peg.lisp.

Function: temporary⎵function⎵to⎵add⎵symbol⎵definition⎵into⎵ast (x &rest pos)
Package

esrap-peg.

Source

peg.lisp.

Function: temporary⎵function⎵to⎵add⎵symbol⎵dot⎵into⎵ast (x &rest pos)
Package

esrap-peg.

Source

peg.lisp.

Function: temporary⎵function⎵to⎵add⎵symbol⎵endoffile⎵into⎵ast (x &rest pos)
Package

esrap-peg.

Source

peg.lisp.

Function: temporary⎵function⎵to⎵add⎵symbol⎵endofline⎵into⎵ast (x &rest pos)
Package

esrap-peg.

Source

peg.lisp.

Function: temporary⎵function⎵to⎵add⎵symbol⎵expression⎵into⎵ast (x &rest pos)
Package

esrap-peg.

Source

peg.lisp.

Function: temporary⎵function⎵to⎵add⎵symbol⎵grammar⎵into⎵ast (x &rest pos)
Package

esrap-peg.

Source

peg.lisp.

Function: temporary⎵function⎵to⎵add⎵symbol⎵identcont⎵into⎵ast (x &rest pos)
Package

esrap-peg.

Source

peg.lisp.

Function: temporary⎵function⎵to⎵add⎵symbol⎵identifier⎵into⎵ast (x &rest pos)
Package

esrap-peg.

Source

peg.lisp.

Function: temporary⎵function⎵to⎵add⎵symbol⎵identstart⎵into⎵ast (x &rest pos)
Package

esrap-peg.

Source

peg.lisp.

Function: temporary⎵function⎵to⎵add⎵symbol⎵leftarrow⎵into⎵ast (x &rest pos)
Package

esrap-peg.

Source

peg.lisp.

Function: temporary⎵function⎵to⎵add⎵symbol⎵literal⎵into⎵ast (x &rest pos)
Package

esrap-peg.

Source

peg.lisp.

Function: temporary⎵function⎵to⎵add⎵symbol⎵not⎵into⎵ast (x &rest pos)
Package

esrap-peg.

Source

peg.lisp.

Function: temporary⎵function⎵to⎵add⎵symbol⎵open⎵into⎵ast (x &rest pos)
Package

esrap-peg.

Source

peg.lisp.

Function: temporary⎵function⎵to⎵add⎵symbol⎵plus⎵into⎵ast (x &rest pos)
Package

esrap-peg.

Source

peg.lisp.

Function: temporary⎵function⎵to⎵add⎵symbol⎵prefix⎵into⎵ast (x &rest pos)
Package

esrap-peg.

Source

peg.lisp.

Function: temporary⎵function⎵to⎵add⎵symbol⎵primary⎵into⎵ast (x &rest pos)
Package

esrap-peg.

Source

peg.lisp.

Function: temporary⎵function⎵to⎵add⎵symbol⎵question⎵into⎵ast (x &rest pos)
Package

esrap-peg.

Source

peg.lisp.

Function: temporary⎵function⎵to⎵add⎵symbol⎵range⎵into⎵ast (x &rest pos)
Package

esrap-peg.

Source

peg.lisp.

Function: temporary⎵function⎵to⎵add⎵symbol⎵sequence⎵into⎵ast (x &rest pos)
Package

esrap-peg.

Source

peg.lisp.

Function: temporary⎵function⎵to⎵add⎵symbol⎵slash⎵into⎵ast (x &rest pos)
Package

esrap-peg.

Source

peg.lisp.

Function: temporary⎵function⎵to⎵add⎵symbol⎵space⎵into⎵ast (x &rest pos)
Package

esrap-peg.

Source

peg.lisp.

Function: temporary⎵function⎵to⎵add⎵symbol⎵spacing⎵into⎵ast (x &rest pos)
Package

esrap-peg.

Source

peg.lisp.

Function: temporary⎵function⎵to⎵add⎵symbol⎵star⎵into⎵ast (x &rest pos)
Package

esrap-peg.

Source

peg.lisp.

Function: temporary⎵function⎵to⎵add⎵symbol⎵suffix⎵into⎵ast (x &rest pos)
Package

esrap-peg.

Source

peg.lisp.

Function: to-text (str start end)
Package

esrap-peg.

Source

peg.lisp.


Appendix A Indexes


A.1 Concepts


A.2 Functions

Jump to:   A   B   C   D   E   F   M   P   S   T  
Index Entry  Section

A
abbreviations-into-package: Private ordinary functions
add-peg-order-rule: Public ordinary functions
ast-eval: Public ordinary functions

B
basic-parse-peg: Public ordinary functions

C
character-class-rule: Private macros

D
def-ast-rule: Private macros
def-peg-fun: Public macros
def-peg-matchers: Public macros
define-character-classes: Private macros
delete-peg-order-rule: Public ordinary functions

E
esrap-peg-symbol: Private ordinary functions

F
file-contents: Private ordinary functions
Function, abbreviations-into-package: Private ordinary functions
Function, add-peg-order-rule: Public ordinary functions
Function, ast-eval: Public ordinary functions
Function, basic-parse-peg: Public ordinary functions
Function, delete-peg-order-rule: Public ordinary functions
Function, esrap-peg-symbol: Private ordinary functions
Function, file-contents: Private ordinary functions
Function, parse-peg-file: Public ordinary functions
Function, peg-code: Public ordinary functions
Function, semantic-checker⎵for⎵character⎵class⎵with⎵clauses⎵(#\n⎵#\r⎵#\t⎵#\'⎵#\"⎵#\[⎵#\]↵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵#\\)⎵: Private ordinary functions
Function, semantic-checker⎵for⎵character⎵class⎵with⎵clauses⎵((#\0⎵#\3))⎵: Private ordinary functions
Function, semantic-checker⎵for⎵character⎵class⎵with⎵clauses⎵((#\0⎵#\7))⎵: Private ordinary functions
Function, semantic-checker⎵for⎵character⎵class⎵with⎵clauses⎵((#\0⎵#\9))⎵: Private ordinary functions
Function, semantic-checker⎵for⎵character⎵class⎵with⎵clauses⎵((#\0⎵#\9)⎵(#\a⎵#\f)↵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵(#\a⎵#\f))⎵: Private ordinary functions
Function, semantic-checker⎵for⎵character⎵class⎵with⎵clauses⎵((#\a⎵#\z)⎵(#\a⎵#\z)⎵#\_)⎵: Private ordinary functions
Function, stream-contents: Private ordinary functions
Function, temporary⎵function⎵to⎵add⎵symbol⎵and⎵into⎵ast: Private ordinary functions
Function, temporary⎵function⎵to⎵add⎵symbol⎵char⎵into⎵ast: Private ordinary functions
Function, temporary⎵function⎵to⎵add⎵symbol⎵class⎵into⎵ast: Private ordinary functions
Function, temporary⎵function⎵to⎵add⎵symbol⎵close⎵into⎵ast: Private ordinary functions
Function, temporary⎵function⎵to⎵add⎵symbol⎵comment⎵into⎵ast: Private ordinary functions
Function, temporary⎵function⎵to⎵add⎵symbol⎵definition⎵into⎵ast: Private ordinary functions
Function, temporary⎵function⎵to⎵add⎵symbol⎵dot⎵into⎵ast: Private ordinary functions
Function, temporary⎵function⎵to⎵add⎵symbol⎵endoffile⎵into⎵ast: Private ordinary functions
Function, temporary⎵function⎵to⎵add⎵symbol⎵endofline⎵into⎵ast: Private ordinary functions
Function, temporary⎵function⎵to⎵add⎵symbol⎵expression⎵into⎵ast: Private ordinary functions
Function, temporary⎵function⎵to⎵add⎵symbol⎵grammar⎵into⎵ast: Private ordinary functions
Function, temporary⎵function⎵to⎵add⎵symbol⎵identcont⎵into⎵ast: Private ordinary functions
Function, temporary⎵function⎵to⎵add⎵symbol⎵identifier⎵into⎵ast: Private ordinary functions
Function, temporary⎵function⎵to⎵add⎵symbol⎵identstart⎵into⎵ast: Private ordinary functions
Function, temporary⎵function⎵to⎵add⎵symbol⎵leftarrow⎵into⎵ast: Private ordinary functions
Function, temporary⎵function⎵to⎵add⎵symbol⎵literal⎵into⎵ast: Private ordinary functions
Function, temporary⎵function⎵to⎵add⎵symbol⎵not⎵into⎵ast: Private ordinary functions
Function, temporary⎵function⎵to⎵add⎵symbol⎵open⎵into⎵ast: Private ordinary functions
Function, temporary⎵function⎵to⎵add⎵symbol⎵plus⎵into⎵ast: Private ordinary functions
Function, temporary⎵function⎵to⎵add⎵symbol⎵prefix⎵into⎵ast: Private ordinary functions
Function, temporary⎵function⎵to⎵add⎵symbol⎵primary⎵into⎵ast: Private ordinary functions
Function, temporary⎵function⎵to⎵add⎵symbol⎵question⎵into⎵ast: Private ordinary functions
Function, temporary⎵function⎵to⎵add⎵symbol⎵range⎵into⎵ast: Private ordinary functions
Function, temporary⎵function⎵to⎵add⎵symbol⎵sequence⎵into⎵ast: Private ordinary functions
Function, temporary⎵function⎵to⎵add⎵symbol⎵slash⎵into⎵ast: Private ordinary functions
Function, temporary⎵function⎵to⎵add⎵symbol⎵space⎵into⎵ast: Private ordinary functions
Function, temporary⎵function⎵to⎵add⎵symbol⎵spacing⎵into⎵ast: Private ordinary functions
Function, temporary⎵function⎵to⎵add⎵symbol⎵star⎵into⎵ast: Private ordinary functions
Function, temporary⎵function⎵to⎵add⎵symbol⎵suffix⎵into⎵ast: Private ordinary functions
Function, to-text: Private ordinary functions

M
Macro, character-class-rule: Private macros
Macro, def-ast-rule: Private macros
Macro, def-peg-fun: Public macros
Macro, def-peg-matchers: Public macros
Macro, define-character-classes: Private macros
Macro, peg-compile: Public macros

P
parse-peg-file: Public ordinary functions
peg-code: Public ordinary functions
peg-compile: Public macros

S
semantic-checker⎵for⎵character⎵class⎵with⎵clauses⎵(#\n⎵#\r⎵#\t⎵#\'⎵#\"⎵#\[⎵#\]↵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵#\\)⎵: Private ordinary functions
semantic-checker⎵for⎵character⎵class⎵with⎵clauses⎵((#\0⎵#\3))⎵: Private ordinary functions
semantic-checker⎵for⎵character⎵class⎵with⎵clauses⎵((#\0⎵#\7))⎵: Private ordinary functions
semantic-checker⎵for⎵character⎵class⎵with⎵clauses⎵((#\0⎵#\9))⎵: Private ordinary functions
semantic-checker⎵for⎵character⎵class⎵with⎵clauses⎵((#\0⎵#\9)⎵(#\a⎵#\f)↵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵⎵(#\a⎵#\f))⎵: Private ordinary functions
semantic-checker⎵for⎵character⎵class⎵with⎵clauses⎵((#\a⎵#\z)⎵(#\a⎵#\z)⎵#\_)⎵: Private ordinary functions
stream-contents: Private ordinary functions

T
temporary⎵function⎵to⎵add⎵symbol⎵and⎵into⎵ast: Private ordinary functions
temporary⎵function⎵to⎵add⎵symbol⎵char⎵into⎵ast: Private ordinary functions
temporary⎵function⎵to⎵add⎵symbol⎵class⎵into⎵ast: Private ordinary functions
temporary⎵function⎵to⎵add⎵symbol⎵close⎵into⎵ast: Private ordinary functions
temporary⎵function⎵to⎵add⎵symbol⎵comment⎵into⎵ast: Private ordinary functions
temporary⎵function⎵to⎵add⎵symbol⎵definition⎵into⎵ast: Private ordinary functions
temporary⎵function⎵to⎵add⎵symbol⎵dot⎵into⎵ast: Private ordinary functions
temporary⎵function⎵to⎵add⎵symbol⎵endoffile⎵into⎵ast: Private ordinary functions
temporary⎵function⎵to⎵add⎵symbol⎵endofline⎵into⎵ast: Private ordinary functions
temporary⎵function⎵to⎵add⎵symbol⎵expression⎵into⎵ast: Private ordinary functions
temporary⎵function⎵to⎵add⎵symbol⎵grammar⎵into⎵ast: Private ordinary functions
temporary⎵function⎵to⎵add⎵symbol⎵identcont⎵into⎵ast: Private ordinary functions
temporary⎵function⎵to⎵add⎵symbol⎵identifier⎵into⎵ast: Private ordinary functions
temporary⎵function⎵to⎵add⎵symbol⎵identstart⎵into⎵ast: Private ordinary functions
temporary⎵function⎵to⎵add⎵symbol⎵leftarrow⎵into⎵ast: Private ordinary functions
temporary⎵function⎵to⎵add⎵symbol⎵literal⎵into⎵ast: Private ordinary functions
temporary⎵function⎵to⎵add⎵symbol⎵not⎵into⎵ast: Private ordinary functions
temporary⎵function⎵to⎵add⎵symbol⎵open⎵into⎵ast: Private ordinary functions
temporary⎵function⎵to⎵add⎵symbol⎵plus⎵into⎵ast: Private ordinary functions
temporary⎵function⎵to⎵add⎵symbol⎵prefix⎵into⎵ast: Private ordinary functions
temporary⎵function⎵to⎵add⎵symbol⎵primary⎵into⎵ast: Private ordinary functions
temporary⎵function⎵to⎵add⎵symbol⎵question⎵into⎵ast: Private ordinary functions
temporary⎵function⎵to⎵add⎵symbol⎵range⎵into⎵ast: Private ordinary functions
temporary⎵function⎵to⎵add⎵symbol⎵sequence⎵into⎵ast: Private ordinary functions
temporary⎵function⎵to⎵add⎵symbol⎵slash⎵into⎵ast: Private ordinary functions
temporary⎵function⎵to⎵add⎵symbol⎵space⎵into⎵ast: Private ordinary functions
temporary⎵function⎵to⎵add⎵symbol⎵spacing⎵into⎵ast: Private ordinary functions
temporary⎵function⎵to⎵add⎵symbol⎵star⎵into⎵ast: Private ordinary functions
temporary⎵function⎵to⎵add⎵symbol⎵suffix⎵into⎵ast: Private ordinary functions
to-text: Private ordinary functions