all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* Re: master 8bee4060ea4 2/2: Add peg.el as a built-in library
@ 2024-03-31  7:33 Eli Zaretskii
  2024-04-01 14:28 ` Eric Abrahamsen
  0 siblings, 1 reply; 10+ messages in thread
From: Eli Zaretskii @ 2024-03-31  7:33 UTC (permalink / raw)
  To: Eric Abrahamsen; +Cc: emacs-devel, Stefan Monnier

> branch: master
> commit 8bee4060ea42c61e52ebe6487ff97bc095261050
> Author: Eric Abrahamsen <eric@ericabrahamsen.net>
> Commit: Eric Abrahamsen <eric@ericabrahamsen.net>
> 
>     Add peg.el as a built-in library
>     
>     * lisp/progmodes/peg.el: New file, taken from ELPA package.
>     * test/lisp/peg-tests.el: Package tests.
>     * doc/lispref/peg.texi: Documentation.

Thanks.  A few comments about this:

I fixed the manual additions, but there are a few FIXME's there;
please take care of them.

The doc string of define-peg-rule doesn't reference a mandatory
argument ARGS.  It also doesn't tell what happens if PEXS is omitted
or nil.

The doc string of define-peg-rule doesn't say how the NAME argument is
used.

The doc string of with-peg-rules doesn't explain the meaning of NAME
in each rule.

Some public functions in peg.el lack doc strings, and others don't
mention their arguments in the first line of the doc string.

Last, but not least: the test suite fails to compile, even after I
moved it to the correct subdirectory of test/:

    ELC      lisp/progmodes/peg-tests.elc

  In toplevel form:
  lisp/progmodes/peg-tests.el: Warning: Possible left recursion: r -> r
  lisp/progmodes/peg-tests.el: Warning: `let' with empty body
  lisp/progmodes/peg-tests.el: Warning: `let' with empty body

  In peg-ex-arith:
  lisp/progmodes/peg-tests.el:210:2: Warning: `peg-rule eol' called with 1 argument, but accepts only 0
  lisp/progmodes/peg-tests.el:212:10: Warning: reference to free variable `_'
  lisp/progmodes/peg-tests.el:212:12: Warning: reference to free variable `sum'
  lisp/progmodes/peg-tests.el:212:16: Warning: reference to free variable `eol'
  lisp/progmodes/peg-tests.el:213:9: Warning: reference to free variable `product'
  lisp/progmodes/peg-tests.el:215:13: Warning: reference to free variable `value'
  lisp/progmodes/peg-tests.el:217:21: Warning: value from call to `substring' is unused
  lisp/progmodes/peg-tests.el:217:31: Warning: reference to free variable `number'
  lisp/progmodes/peg-tests.el: Error: Too many arguments for inlined function (#[0 "l\207" [((guard (eolp)))] 1 peg-function] "
  ")

  In peg-ex-uri:
  lisp/progmodes/peg-tests.el:229:23: Warning: reference to free variable `absoluteURI'
  lisp/progmodes/peg-tests.el:229:35: Warning: reference to free variable `relativeURI'
  lisp/progmodes/peg-tests.el:230:43: Warning: reference to free variable `fragment'
  lisp/progmodes/peg-tests.el:237:28: Warning: reference to free variable `scheme'
  lisp/progmodes/peg-tests.el:237:44: Warning: reference to free variable `hier-part'
  lisp/progmodes/peg-tests.el:237:54: Warning: reference to free variable `opaque-part'
  lisp/progmodes/peg-tests.el:239:9: Warning: reference to free variable `net-path'

  lisp/progmodes/peg-tests.el:241:14: Warning: reference to free variable `abs-path'
  lisp/progmodes/peg-tests.el:242:29: Warning: reference to free variable `query'
  lisp/progmodes/peg-tests.el:244:19: Warning: reference to free variable `authority'
  lisp/progmodes/peg-tests.el:245:18: Warning: reference to free variable `path-segments'
  lisp/progmodes/peg-tests.el:246:19: Warning: reference to free variable `segment'

  lisp/progmodes/peg-tests.el:247:27: Warning: reference to free variable `pchar'
  lisp/progmodes/peg-tests.el:247:41: Warning: reference to free variable `param'
  lisp/progmodes/peg-tests.el:249:15: Warning: reference to free variable `unreserved'
  lisp/progmodes/peg-tests.el:249:26: Warning: reference to free variable `escaped'

  lisp/progmodes/peg-tests.el:250:14: Warning: reference to free variable `uric'
  lisp/progmodes/peg-tests.el:252:39: Warning: reference to free variable `rel-path'
  lisp/progmodes/peg-tests.el:253:14: Warning: reference to free variable `rel-segment'
  lisp/progmodes/peg-tests.el:255:19: Warning: reference to free variable `server'
  lisp/progmodes/peg-tests.el:255:26: Warning: reference to free variable `reg-name'
  lisp/progmodes/peg-tests.el:256:31: Warning: value from call to `substring' is unused
  lisp/progmodes/peg-tests.el:256:41: Warning: reference to free variable `userinfo'
  lisp/progmodes/peg-tests.el:258:21: Warning: reference to free variable `hostport'
  lisp/progmodes/peg-tests.el:261:25: Warning: reference to free variable `host'
  lisp/progmodes/peg-tests.el:261:55: Warning: reference to free variable `port'
  lisp/progmodes/peg-tests.el:263:14: Warning: reference to free variable `hostname'
  lisp/progmodes/peg-tests.el:263:23: Warning: reference to free variable `ipv4address'
  lisp/progmodes/peg-tests.el:264:17: Warning: reference to free variable `domainlabel'
  lisp/progmodes/peg-tests.el:264:34: Warning: reference to free variable `toplabel'
  lisp/progmodes/peg-tests.el:265:17: Warning: reference to free variable `alphanum'
  lisp/progmodes/peg-tests.el:268:14: Warning: reference to free variable `alpha'
  lisp/progmodes/peg-tests.el:271:20: Warning: reference to free variable `digit'
  lisp/progmodes/peg-tests.el:275:17: Warning: reference to free variable `uric-no-slash'
  lisp/progmodes/peg-tests.el:276:14: Warning: reference to free variable `reserved'
  lisp/progmodes/peg-tests.el:278:15: Warning: `set' called with 1 arg, but requires 2
  lisp/progmodes/peg-tests.el:278:15: Warning: `set' called with 1 argument, but requires 2
  lisp/progmodes/peg-tests.el:279:29: Warning: reference to free variable `mark'
  lisp/progmodes/peg-tests.el:280:17: Warning: reference to free variable `hex'
  lisp/progmodes/peg-tests.el:282:11: Warning: `set' called with 1 arg, but requires 2
  lisp/progmodes/peg-tests.el:282:11: Warning: `set' called with 1 argument, but requires 2
  lisp/progmodes/peg-tests.el:284:15: Warning: reference to free variable `lowalpha'
  lisp/progmodes/peg-tests.el:284:24: Warning: reference to free variable `upalpha'


  In peg-ex-lisp:
  lisp/progmodes/peg-tests.el:305:10: Warning: reference to free variable `_'
  lisp/progmodes/peg-tests.el:305:16: Warning: reference to free variable `string'
  lisp/progmodes/peg-tests.el:305:23: Warning: reference to free variable `list'
  lisp/progmodes/peg-tests.el:305:28: Warning: reference to free variable `number'
  lisp/progmodes/peg-tests.el:305:35: Warning: reference to free variable `symbol'
  lisp/progmodes/peg-tests.el:309:29: Warning: `set' called with 1 arg, but requires 2
  lisp/progmodes/peg-tests.el:309:29: Warning: `set' called with 1 argument, but requires 2
  lisp/progmodes/peg-tests.el:309:43: Warning: reference to free variable `digit'
  lisp/progmodes/peg-tests.el:310:16: Warning: reference to free variable `terminating'
  lisp/progmodes/peg-tests.el:312:28: Warning: reference to free variable `symchar'

  lisp/progmodes/peg-tests.el:319:22: Warning: `set' called with 1 arg, but requires 2
  lisp/progmodes/peg-tests.el:319:22: Warning: `set' called with 1 argument, but requires 2

  In end of data:
  lisp/progmodes/peg-tests.el:319:42: Warning: the function `eob' is not known to be defined.
  lisp/progmodes/peg-tests.el: Warning: the function `peg-rule terminating' is not known to be defined.
  lisp/progmodes/peg-tests.el: Warning: the function `peg-rule symchar' is not known to be defined.
  lisp/progmodes/peg-tests.el: Warning: the function `peg-rule symbol' is not known to be defined.
  lisp/progmodes/peg-tests.el: Warning: the function `peg-rule string' is not known to be defined.
  lisp/progmodes/peg-tests.el:307:43: Warning: the function `any' is not known to be defined.
  lisp/progmodes/peg-tests.el: Warning: the function `peg-rule comment' is not known to be defined.
  lisp/progmodes/peg-tests.el: Warning: the function `peg-rule sexp' is not known to be defined.
  lisp/progmodes/peg-tests.el: Warning: the function `peg-rule digit' is not known to be defined.
  lisp/progmodes/peg-tests.el: Warning: the function `peg-rule upalpha' is not known to be defined.
  lisp/progmodes/peg-tests.el: Warning: the function `peg-rule lowalpha' is not known to be defined.
  lisp/progmodes/peg-tests.el: Warning: the function `peg-rule alpha' is not known to be defined.
  lisp/progmodes/peg-tests.el: Warning: the function `peg-rule alphanum' is not known to be defined.
  lisp/progmodes/peg-tests.el: Warning: the function `peg-rule mark' is not known to be defined.
  lisp/progmodes/peg-tests.el: Warning: the function `peg-rule hex' is not known to be defined.
  lisp/progmodes/peg-tests.el: Warning: the function `peg-rule escaped' is not known to be defined.
  lisp/progmodes/peg-tests.el: Warning: the function `peg-rule unreserved' is not known to be defined.
  lisp/progmodes/peg-tests.el: Warning: the function `peg-rule reserved' is not known to be defined.
  lisp/progmodes/peg-tests.el: Warning: the function `peg-rule uric-no-slash' is not known to be defined.
  lisp/progmodes/peg-tests.el: Warning: the function `peg-rule uric' is not known to be defined.
  lisp/progmodes/peg-tests.el: Warning: the function `peg-rule opaque-part' is not known to be defined.
  lisp/progmodes/peg-tests.el: Warning: the function `peg-rule reg-name' is not known to be defined.
  lisp/progmodes/peg-tests.el: Warning: the function `peg-rule scheme' is not known to be defined.
  lisp/progmodes/peg-tests.el: Warning: the function `peg-rule port' is not known to be defined.
  lisp/progmodes/peg-tests.el: Warning: the function `peg-rule ipv4address' is not known to be defined.
  lisp/progmodes/peg-tests.el: Warning: the function `peg-rule toplabel' is not known to be defined.
  lisp/progmodes/peg-tests.el: Warning: the function `peg-rule domainlabel' is not known to be defined.
  lisp/progmodes/peg-tests.el: Warning: the function `peg-rule hostname' is not known to be defined.
  lisp/progmodes/peg-tests.el: Warning: the function `peg-rule host' is not known to be defined.
  lisp/progmodes/peg-tests.el: Warning: the function `peg-rule hostport' is not known to be defined.
  lisp/progmodes/peg-tests.el: Warning: the function `peg-rule userinfo' is not known to be defined.
  lisp/progmodes/peg-tests.el: Warning: the function `peg-rule server' is not known to be defined.
  lisp/progmodes/peg-tests.el: Warning: the function `peg-rule authority' is not known to be defined.
  lisp/progmodes/peg-tests.el: Warning: the function `peg-rule rel-segment' is not known to be defined.
  lisp/progmodes/peg-tests.el: Warning: the function `peg-rule rel-path' is not known to be defined.
  lisp/progmodes/peg-tests.el:252:50: Warning: the function `opt' is not known to be defined.
  lisp/progmodes/peg-tests.el: Warning: the function `peg-rule relativeURI' is not known to be defined.
  lisp/progmodes/peg-tests.el: Warning: the function `peg-rule fragment' is not known to be defined.
  lisp/progmodes/peg-tests.el: Warning: the function `peg-rule query' is not known to be defined.
  lisp/progmodes/peg-tests.el: Warning: the function `peg-rule pchar' is not known to be defined.
  lisp/progmodes/peg-tests.el: Warning: the function `peg-rule param' is not known to be defined.
  lisp/progmodes/peg-tests.el: Warning: the function `peg-rule segment' is not known to be defined.
  lisp/progmodes/peg-tests.el: Warning: the function `peg-rule path-segments' is not known to be defined.
  lisp/progmodes/peg-tests.el: Warning: the function `peg-rule abs-path' is not known to be defined.
  lisp/progmodes/peg-tests.el: Warning: the function `peg-rule net-path' is not known to be defined.
  lisp/progmodes/peg-tests.el: Warning: the function `peg-rule hier-part' is not known to be defined.
  lisp/progmodes/peg-tests.el: Warning: the function `peg-rule absoluteURI' is not known to be defined.
  lisp/progmodes/peg-tests.el: Warning: the function `peg-rule URI-reference' is not known to be defined.
  lisp/progmodes/peg-tests.el: Warning: the function `peg-rule _' is not known to be defined.
  lisp/progmodes/peg-tests.el: Warning: the function `peg-rule number' is not known to be defined.
  lisp/progmodes/peg-tests.el: Warning: the function `peg-rule value' is not known to be defined.
  lisp/progmodes/peg-tests.el: Warning: the function `peg-rule product' is not known to be defined.
  lisp/progmodes/peg-tests.el: Warning: the function `peg-rule sum' is not known to be defined.
  lisp/progmodes/peg-tests.el: Warning: the function `peg-rule expr' is not known to be defined.
  lisp/progmodes/peg-tests.el: Warning: the function `peg-rule other' is not known to be defined.
  Makefile:163: recipe for target `lisp/progmodes/peg-tests.elc' failed
  make[1]: *** [lisp/progmodes/peg-tests.elc] Error 1



^ permalink raw reply	[flat|nested] 10+ messages in thread

end of thread, other threads:[~2024-04-16 12:31 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-03-31  7:33 master 8bee4060ea4 2/2: Add peg.el as a built-in library Eli Zaretskii
2024-04-01 14:28 ` Eric Abrahamsen
2024-04-03  3:03   ` Eric Abrahamsen
2024-04-13  8:04     ` Eli Zaretskii
2024-04-13 18:00       ` Stefan Monnier
2024-04-13 18:13         ` Eli Zaretskii
2024-04-13 19:36       ` Stefan Monnier
2024-04-14  4:58         ` Eli Zaretskii
2024-04-16  3:18           ` Eric Abrahamsen
2024-04-16 12:31             ` Eli Zaretskii

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.