bug-gnu-emacs
[Top][All Lists]
Advanced

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

bug#39709: #39709: 28.0.50; [PATCH] substring and the byte compiler


From: Mattias Engdegård
Subject: bug#39709: #39709: 28.0.50; [PATCH] substring and the byte compiler
Date: Fri, 21 Feb 2020 12:48:01 +0100

The missing 1-3 case seems to be a simple omission -- thanks for spotting it.

+(defun byte-compile-one-to-three-args (form)
+  (let ((len (length form)))
+    (cond ((= len 2) (byte-compile-one-arg form))
+          ((= len 3) (byte-compile-two-args form))
+          ((= len 4) (byte-compile-three-args form))
+         (t (byte-compile-subr-wrong-args form "1-3")))))

Not sure how this would work. Don't you need to add the missing arguments?

Cleaned-up patch attached.
(Unless, of course, there is evidence that the byte op has never been emitted 
--- then we have an opportunity to drop it instead.)

Attachment: 0001-Generate-substring-byte-op-bug-39709.patch
Description: Binary data


reply via email to

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