aboutsummaryrefslogtreecommitdiffstats
path: root/lisp/progmodes/peg.el (follow)
Commit message (Collapse)AuthorAgeFilesLines
* ; Add 2026 to copyright years.Sean Whitton2026-01-011-1/+1
|
* peg.el: Fix bug#79502 a bit moreStefan Monnier2025-09-271-1/+8
| | | | | * lisp/progmodes/peg.el (peg--detect-cycles): Accept args. (peg--detect-cycles) <funcall>: New method.
* peg.el: Fix bug#79502Stefan Monnier2025-09-271-17/+5
| | | | | | | | | * lisp/progmodes/peg.el (peg--merge-error): Provide a default method. (peg--merge-error) <call>: Handle calls with arguments. (peg--merge-error) <any, not>: Remove methods, now redundant with the default method. (peg--merge-error) <guard>: Delegate to the default method if we can't do better.
* (peg-parse): Fix bug#78884Stefan Monnier2025-06-271-3/+7
| | | | | | | * lisp/progmodes/peg.el (peg-parse): Be more careful when testing if a symbol is the name of an existing rule. Improve docstring. test/lisp/progmodes/peg-tests.el (peg-tests--peg-parse): New test.
* (peg--merge-error) <guard>: Add missing methodStefan Monnier2025-06-201-1/+3
| | | | | | Also clarify that the package requires at least Emacs-25. * lisp/progmodes/peg.el (peg--merge-error) <guard>: Add missing method.
* PEG: Fix bug#76555Stefan Monnier2025-03-271-1/+1
| | | | | | | * doc/lispref/peg.texi (Parsing Expression Grammars): Fix `define-peg-ruleset` example. * lisp/progmodes/peg.el (define-peg-rule): Fix indent rule.
* ; Replace "Elisp" with "Lisp" or "Emacs Lisp" in some placesSean Whitton2025-03-121-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | * configure.ac (libgccjit_not_found_err) (libgccjit_dev_not_found_err): * doc/lispref/elisp.texi (Top): * doc/lispref/functions.texi (What Is a Function): * doc/lispref/parsing.texi (Parsing Program Source) (Tree-sitter C API): * doc/misc/gnus.texi (The Gnus Registry): * etc/TODO: * lisp/auth-source.el (auth-source-search): * lisp/cedet/semantic/bovine/el.el (emacs-lisp-mode): * lisp/editorconfig.el (editorconfig-get-local-variables-functions): * lisp/emacs-lisp/cconv.el (cconv-make-interpreted-closure): * lisp/emacs-lisp/oclosure.el (cconv--interactive-helper): * lisp/net/tramp-message.el (tramp-debug-font-lock-keywords): * src/frame.c (do_switch_frame): * test/lisp/emacs-lisp/shortdoc-tests.el (shortdoc-help-fns-examples-function-test): Say "Lisp" not "Elisp". * lisp/progmodes/peg.el (peg-translate-exp): Say "Emacs Lisp" not "Elisp".
* Fix capitalization ELisp -> ElispSean Whitton2025-03-121-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * configure.ac (libgccjit_not_found_err) (libgccjit_dev_not_found_err): * doc/emacs/buffers.texi (List Buffers): * doc/lispref/elisp.texi (Tree-sitter C API): * doc/lispref/functions.texi (What Is a Function): * doc/lispref/parsing.texi (Parsing Program Source) (Tree-sitter C API): * doc/misc/gnus.texi (The Gnus Registry): * etc/DEBUG: * etc/NEWS: * etc/NEWS.25: * etc/NEWS.26: * etc/NEWS.28: * etc/NEWS.30: * etc/TODO: * lib-src/emacsclient.c (print_help_and_exit): * lisp/auth-source.el (auth-source-search): * lisp/cedet/semantic/bovine/el.el (emacs-lisp-mode): * lisp/cedet/semantic/wisent/comp.el (wisent-automaton-lisp-form): * lisp/cedet/srecode/el.el (srecode-semantic-apply-tag-to-dict): * lisp/editorconfig.el (editorconfig-get-local-variables-functions): * lisp/emacs-lisp/bindat.el (bindat-type): * lisp/emacs-lisp/byte-opt.el (byte-compile-inline-expand): * lisp/emacs-lisp/cconv.el (cconv-make-interpreted-closure): * lisp/emacs-lisp/cl-macs.el (cl--labels-convert): * lisp/emacs-lisp/lisp-mode.el (lisp-fdefs) (lisp-fill-paragraphs-as-doc-string): * lisp/emacs-lisp/macroexp.el (macroexp--fgrep): * lisp/emacs-lisp/oclosure.el (cconv--interactive-helper): * lisp/emacs-lisp/re-builder.el: * lisp/erc/erc-button.el (erc-emacswiki-lisp-url): * lisp/help-fns.el (help-fns--describe-function-or-command-prompt): * lisp/menu-bar.el (menu-bar-search-documentation-menu): * lisp/net/tramp-message.el (tramp-debug-font-lock-keywords): * lisp/org/org-capture.el (org-capture): * lisp/org/org.el (org-category, org-todo): * lisp/org/ox.el (org-export-async-start): * lisp/progmodes/elisp-mode.el (emacs-lisp-mode): * lisp/progmodes/peg.el (peg-translate-exp): * lisp/progmodes/ruby-ts-mode.el: * lisp/woman.el (woman-mode, woman-parse-numeric-arg): * src/chartab.c (map_char_table_for_charset): * src/fns.c (extract_data_from_object): * src/frame.c (do_switch_frame): * src/keyboard.c (make_lispy_event): * test/lisp/emacs-lisp/cl-macs-tests.el (cl-&key-arguments): * test/lisp/emacs-lisp/shortdoc-tests.el (shortdoc-help-fns-examples-function-test): * test/manual/etags/c-src/emacs/src/keyboard.c (make_lispy_event): Fix capitalization ELisp -> Elisp.
* Update copyright year to 2025Paul Eggert2025-01-011-1/+1
| | | | Run "TZ=UTC0 admin/update-copyright".
* (with-peg-rules): Build proper `peg-function`sStefan Monnier2024-11-121-3/+2
| | | | | * lisp/progmodes/peg.el (with-peg-rules): Use the new (FUNC EXP) feature in `cl-labels`.
* (with-peg-rules): Fix references to rulesets (bug#74018)Stefan Monnier2024-10-281-2/+13
| | | | | | | | | | | | | | | | | | | | | | | PEG rules get "compiled" to functions with name `peg-rule <RULE>`. `define-peg-ruleset` instead defines it PEG rules with name `peg-rule <RULESET> <RULE>`, so that they can be made visible by `with-peg-rules` simply by adding local aliases from `peg-rule <RULE>` to `peg-rule <RULESET> <RULE>`. Apparently when I added `define-peg-ruleset` I somehow failed to install some of the corresponding code in `with-peg-rules`, so the aliases were not installed, making it "impossible" to use rulesets. [ I still have no idea how this happened and/or where the missing code went, so I "recreated" it. ] * lisp/progmodes/peg.el (with-peg-rules): Install the aliases for the rulesets. (peg--translate-rule-body): Try and preserve location info when emitting a warning. * test/lisp/progmodes/peg-tests.el (peg-test-myrules): New ruleset. (peg-test-ruleset): New test.
* * lisp/progmodes/peg.el (peg-syntax-classes): Typo (bug#72131)Stefan Monnier2024-07-191-1/+1
|
* ; Fix typos (bug#72167)john muhl2024-07-181-1/+1
| | | | | | | | | * lisp/minibuffer.el (completion-auto-deselect): Correct spelling of "minibuffer". * lisp/progmodes/peg.el (peg--actions): Correct spelling of "post-processing". * lisp/progmodes/php-ts-mode.el: Correct spelling of "taken".
* ; Fix typosStefan Kangas2024-06-161-1/+1
|
* ; Improvements to PEG documentation (second attempt)Eric Abrahamsen2024-04-161-3/+4
| | | | | | | * doc/lispref/peg.texi: Make more use of defmac/defmacro, and try to clarify the relationships between the various macros and functions. * lisp/progmodes/peg.el (peg-parse): Remove claim that PEXS can also be a single list of rules.
* Revert "; Improvements to PEG documentation"Mattias EngdegÄrd2024-04-161-4/+3
| | | | | This reverts commit 930c578c1042e6372e5433e31b2ea801315c01c9. Looks like an editing mistake ate a large part of the text.
* ; Improvements to PEG documentationEric Abrahamsen2024-04-151-3/+4
| | | | | | | * doc/lispref/peg.texi: Make more use of defmac/defmacro, and try to clarify the relationships between the various macros and functions. * lisp/progmodes/peg.el (peg-parse): Remove claim that PEXS can also be a single list of rules.
* peg-tests.el: Fix test failuresStefan Monnier2024-04-131-8/+6
| | | | | | | | | | | | | * lisp/progmodes/peg.el (peg-parse): Refine heuristic since unknown terminals are resolved at run-time rather than compile-time now. (peg--macroexpand) <stack-action>: Avoid generating a `let` with an empty body. (peg--translate-rule-body): Adjust to name change of `macroexp-warn-and-return` and the fact that it's always available. * test/lisp/progmodes/peg-tests.el (peg-parse-string): Add `indent` declaration. (peg-test): Check that the compiler emits the warnings we expect.
* Add peg.el as a built-in libraryEric Abrahamsen2024-03-301-0/+944
* lisp/progmodes/peg.el: New file, taken from ELPA package. * test/lisp/peg-tests.el: Package tests. * doc/lispref/peg.texi: Documentation.