]> git.eshelyaron.com Git - emacs.git/commitdiff
* Fix native comp for non trivial function names (bug#52833)
authorAndrea Corallo <akrl@sdf.org>
Tue, 28 Dec 2021 11:12:16 +0000 (12:12 +0100)
committerAndrea Corallo <akrl@sdf.org>
Mon, 17 Jan 2022 10:54:52 +0000 (11:54 +0100)
* lisp/emacs-lisp/comp.el (comp-c-func-name): Fix native compilation
for functions with function names containing non trivial
characters (bug#52833).

This commit is the backport of e7699bf290.

Do not merge to master

lisp/emacs-lisp/comp.el

index 2ced6277adde48633f4486666e01ced475574de9..a363bed3642f13126aa914879330df7ae0b33d8d 100644 (file)
@@ -1181,7 +1181,9 @@ clashes."
                           for i across orig-name
                           for byte = (format "%x" i)
                           do (aset str j (aref byte 0))
-                             (aset str (1+ j) (aref byte 1))
+                             (aset str (1+ j) (if (length> byte 1)
+                                                  (aref byte 1)
+                                                ?\_))
                           finally return str))
          (human-readable (string-replace
                           "-" "_" orig-name))