gnu-emacs-sources
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[GNU ELPA] Peg version 1.0.1


From: ELPA update
Subject: [GNU ELPA] Peg version 1.0.1
Date: Tue, 29 Nov 2022 17:03:13 -0500

Version 1.0.1 of package Peg has just been released in GNU ELPA.
You can now find it in M-x list-packages RET.

Peg describes itself as:

  =========================================
  Parsing Expression Grammars in Emacs Lisp
  =========================================

More at https://elpa.gnu.org/packages/peg.html

## Summary:

  This package implements Parsing Expression Grammars for Emacs Lisp.

  Parsing Expression Grammars (PEG) are a formalism in the spirit of
  Context Free Grammars (CFG) with some simplifications which makes
  the implementation of PEGs as recursive descent parsers particularly
  simple and easy to understand [Ford, Baker].
  PEGs are more expressive than regexps and potentially easier to use.

  This file implements the macros `define-peg-rule', `with-peg-rules', and
  `peg-parse' which parses the current buffer according to a PEG.
  E.g. we can match integers with:

      (with-peg-rules
          ((number sign digit (* digit))
           (sign   (or "+" "-" ""))
           (digit  [0-9]))
        (peg-run (peg number)))
  or
      (define-peg-rule digit ()
        [0-9])
      (peg-parse (number sign digit (* digit))

## Recent NEWS:

[Not available 🙁]



reply via email to

[Prev in Thread] Current Thread [Next in Thread]