emacs-orgmode
[Top][All Lists]
Advanced

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

[BUG] org parser error [9.6.1 (9.6.1-g351279 @ /home/mah/.emacs.d/straig


From: Mark A. Hershberger
Subject: [BUG] org parser error [9.6.1 (9.6.1-g351279 @ /home/mah/.emacs.d/straight/build/org/)]
Date: Sat, 25 Feb 2023 23:13:32 -0500


Loading the following file with "emacs -Q", I'm un-able to type 'C-c
C-c' in the source block to execute it.

#+begin_src elisp
(defun count-lines (dir)
  "Number of lines in *.php files in a DIR."
  (let ((extdir (concat "../mediawiki/extensions/" dir)))
    (if (not (f-directory-p extdir))
        ""
        (let ((files (directory-files-recursively extdir "\\.php$"))
              (count 0))
          (dolist (file files)
            (setq count (+ count (-reduce '+ (mapcar 'file-lines (list 
file))))))
          count))))
#+end_src

When I do the following error appears:

⛔ Warning (org-element-cache): org-element--cache: Org parser error in 
tmp.org::4740. Resetting.
 The error was: (wrong-number-of-arguments (lambda (dir) "Number of lines in 
*.php files in a DIR." (let ((extdir (concat "../mediawiki/extensions/" dir))) 
(if (not (f-directory-p extdir)) "" (let ((files (directory-files-recursively 
extdir "\\.php$")) (count 0)) (dolist (file files) (setq count (+ count 
(-reduce '+ (mapcar 'file-lines (list file)))))) count)))) 2)
 Backtrace:
nil
 Please report this to Org mode mailing list (M-x org-submit-bug-report).



Emacs  : GNU Emacs 30.0.50 (build 1, x86_64-pc-linux-gnu, GTK+ Version 3.24.36, 
cairo version 1.16.0)
 of 2023-02-23
Package: Org mode version 9.6.1 (9.6.1-g351279 @ 
/home/mah/.emacs.d/straight/build/org/)



reply via email to

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