* [PATCH] org-macs.el: Fix Emacs-26 compatibility
@ 2023-08-11 15:17 Max Nikulin
2023-08-11 16:27 ` Ihor Radchenko
0 siblings, 1 reply; 3+ messages in thread
From: Max Nikulin @ 2023-08-11 15:17 UTC (permalink / raw)
To: emacs-orgmode
[-- Attachment #1: Type: text/plain, Size: 315 bytes --]
Current state of the main branch is not compatible with Emacs-26.
Loading /home/ubuntu/src/org-mode/lisp/org-compat.el (source)...
Eager macro-expansion failure: (wrong-number-of-arguments (2 . 2) 6)
It is again `setq-local' call with multiple variables. See the attached
patch that splits it into several parts.
[-- Attachment #2: 0001-org-macs.el-Fix-Emacs-26-compatibility.patch --]
[-- Type: text/x-patch, Size: 1242 bytes --]
From 9bb21fe2354206d3edf0cc7e145f9d4c5a7bd2ec Mon Sep 17 00:00:00 2001
From: Max Nikulin <manikulin@gmail.com>
Date: Fri, 11 Aug 2023 22:13:17 +0700
Subject: [PATCH] org-macs.el: Fix Emacs-26 compatibility
lisp/org-macs.el (org-string-width): Avoid multiple variables in
`setq-local' since it is not supported by Emacs-26.
The code caused the issue was added in 0c29f53ab8723.
---
lisp/org-macs.el | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/lisp/org-macs.el b/lisp/org-macs.el
index 9533d7b07..442c607d7 100644
--- a/lisp/org-macs.el
+++ b/lisp/org-macs.el
@@ -1117,9 +1117,9 @@ (defun org-string-width (string &optional pixels)
result)))
(current-char-property-alias-alist char-property-alias-alist))
(with-current-buffer (get-buffer-create " *Org string width*")
- (setq-local display-line-numbers nil
- line-prefix nil
- wrap-prefix nil)
+ (setq-local display-line-numbers nil)
+ (setq-local line-prefix nil)
+ (setq-local wrap-prefix nil)
(setq-local buffer-invisibility-spec
(if (listp current-invisibility-spec)
(mapcar (lambda (el)
--
2.25.1
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH] org-macs.el: Fix Emacs-26 compatibility
2023-08-11 15:17 [PATCH] org-macs.el: Fix Emacs-26 compatibility Max Nikulin
@ 2023-08-11 16:27 ` Ihor Radchenko
2023-08-12 8:21 ` Max Nikulin
0 siblings, 1 reply; 3+ messages in thread
From: Ihor Radchenko @ 2023-08-11 16:27 UTC (permalink / raw)
To: Max Nikulin; +Cc: emacs-orgmode
Max Nikulin <manikulin@gmail.com> writes:
> Current state of the main branch is not compatible with Emacs-26.
>
> Loading /home/ubuntu/src/org-mode/lisp/org-compat.el (source)...
> Eager macro-expansion failure: (wrong-number-of-arguments (2 . 2) 6)
>
> It is again `setq-local' call with multiple variables. See the attached
> patch that splits it into several parts.
Thanks!
Applied, onto main.
https://git.savannah.gnu.org/cgit/emacs/org-mode.git/commit/?id=2f79c63c2
That failure does not really point to where it happened... I am
wondering how you managed to find out the cause.
--
Ihor Radchenko // yantar92,
Org mode contributor,
Learn more about Org mode at <https://orgmode.org/>.
Support Org development at <https://liberapay.com/org-mode>,
or support my work at <https://liberapay.com/yantar92>
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] org-macs.el: Fix Emacs-26 compatibility
2023-08-11 16:27 ` Ihor Radchenko
@ 2023-08-12 8:21 ` Max Nikulin
0 siblings, 0 replies; 3+ messages in thread
From: Max Nikulin @ 2023-08-12 8:21 UTC (permalink / raw)
To: emacs-orgmode
On 11/08/2023 23:27, Ihor Radchenko wrote:
> Max Nikulin writes:
>
>> Loading /home/ubuntu/src/org-mode/lisp/org-compat.el (source)...
>> Eager macro-expansion failure: (wrong-number-of-arguments (2 . 2) 6)
>
> That failure does not really point to where it happened... I am
> wondering how you managed to find out the cause.
This time I decided that it is becoming a recurring issue (despite the
comment in the function performing expansion) and I should not be first
person faced it. A search engine gave me
https://emacs.stackexchange.com/questions/54455/how-to-get-a-stack-trace-for-eager-macro-expansion-failure
> (setq debug-on-signal t))
Fortunately other signals (a lot of them) are emitted later. Sometimes
debugging facilities in Emacs are rather disappointing.
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2023-08-12 8:27 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-08-11 15:17 [PATCH] org-macs.el: Fix Emacs-26 compatibility Max Nikulin
2023-08-11 16:27 ` Ihor Radchenko
2023-08-12 8:21 ` Max Nikulin
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.