Subject: bug#48029: 28.1; [native-comp] Function names with non-ascii characters

From: Andrea Corallo <[email-masked]>
Date: Thu, 07 Jul 2022 08:58:26 +0000

Eli Zaretskii <[email-masked]> writes:

>> Cc: [email-masked], [email-masked]
>> From: Andrea Corallo <[email-masked]>
>> Date: Mon, 04 Jul 2022 08:51:01 +0000
>> 
>> Lars Ingebrigtsen <[email-masked]> writes:
>> 
>> > Andrea Corallo <[email-masked]> writes:
>> >
>> >>>> nonascii.el, saved with encoding utf-8-unix:
>> >>>>
>> >>>>     ;; -*- lexical-binding: t; -*-
>> >>>>     (defun nonascii-test-žžž (arg)
>> >>>>       (when arg t))
>> >>>>
>> >>>> Visit it and M-x emacs-lisp-native-compile-and-load.
>> >>>> A function called "nonascii-test-Å¾Å¾Å¾" will be defined.
>> >>>
>> >>> I can reproduce this problem here, too (under Debian/bullseye).  (And
>> >>> this works fine when doing non-native compilation.)
>> >>>
>> >>> I've added Andrea to the CCs.
>> >>
>> >> Thanks Lars,
>> >>
>> >> it's in my todo, I'll try to have a look this coming week.
>> >
>> > This is still the case in Emacs 29 -- did you get any further with this?
>> 
>> Hi Lars,
>> 
>> nope, had no time to progress with this.
>
> Andrea, can you point to the place (or places) where the name of the
> function is generated in this scenario?  Perhaps armed with that
> knowledge, fixing the problem will not be too hard.
>
> Thanks.
>

Sure,

the place where the C function name is generated is `comp-c-func-name'
at comp.el:1175.

ATM I'm not 100% sure the fix limited to this tho.

BR

  Andrea