;; Match an optional program name which is used for
;; non-interactive programs other than compilers (e.g. the
;; "jade:" entry in compilation.txt).
- (? (: (* " ") ; Allow space to precede the program name.
- (| (: alpha (+ (in ?. ?- alnum)) ":" (? " "))
- ;; Skip indentation generated by GCC's -fanalyzer.
- (: (+ " ") "|"))))
+ (? (| (: alpha (+ (in ?. ?- alnum)) ":" (? " "))
+ ;; Skip indentation generated by GCC's -fanalyzer.
+ (: (+ " ") "|")))
;; File name group.
(group-n 1
;; Avoid matching the file name as a program in the pattern
;; above by disallowing file names entirely composed of digits.
- (* (in "0-9"))
- (not (in "0-9" "\n"))
+ ;; Do not allow file names beginning with a space.
+ (| (not (in "0-9" "\n\t "))
+ (: (+ (in "0-9"))
+ (not (in "0-9" "\n"))))
;; A file name can be composed of any non-newline char, but
;; rule out some valid but unlikely cases, such as a trailing
;; space or a space followed by a -, or a colon followed by a