cl-peg
The cl-peg package (cl-peg_0.03.tar.gz) is a PEG packrat parser generator by John Leuner. cl-peg is released under the MIT License.

PEG (Parsing Expression Grammars) and packrat parsers are described in The Packrat Parsing and Parsing Expression Grammars Page.

Similar works:

Quick assessment (2023-03-14)

  • ASDF complains about version specifiers like "0.03" and wants "0.0.3" or whatever.
  • Wants *hash-nickname-map* in genhash but it's called *hash-test-designator-map*.
  • The tests in test.lisp try to load a file named testg.peg but it's missing from the directory.
  • Violation of fixnum type declaration on the slot named hash-val in the call-rule class.

#S(PV :PE NT: |sentence| :CHILDREN (#S(PV :PE NT: |article| :CHILDREN #S(PV :PE NT: |spaces| :CHILDREN NIL)) (#S(PV :PE NT: |subject| :CHILDREN #S(PV :PE NT: |spaces| :CHILDREN NIL)) (#S(PV :PE NT: |verb| :CHILDREN #S(PV :PE NT: |spaces| :CHILDREN NIL)) (#S(PV :PE NT: |preposition| :CHILDREN #S(PV :PE NT: |spaces| :CHILDREN NIL)) (#S(PV :PE NT: |article| :CHILDREN #S(PV :PE NT: |spaces| :CHILDREN NIL)) #S(PV :PE NT: |object| :CHILDREN #S(PV :PE NT: |spaces| :CHILDREN NIL))))))))

The above output of a parse tree is somewhat bad style because it's not actually readable.


obsolete