[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Getting ready to land native-compilation on master
From: |
Jens C . Jensen |
Subject: |
Re: Getting ready to land native-compilation on master |
Date: |
Sat, 10 Apr 2021 10:45:34 +0200 |
> From: Stefan Monnier <monnier@iro.umontreal.ca>
> Date: Fri, 09 Apr 2021 18:43:59 -0400
> Cc: emacs-devel@gnu.org
>>> I'm curious: why would it affect syntax highlighting?
>> I'm using `highlight-defined', which adds faces to defined
>> variables/functions, I don't think it messes with any
>> built-in highlighting.
>
> Still: why does `subrp` affect it?
The problem seems to be the way `highlight-defined.el' determines if a function
is built-in, using `(subrp (indirect-function #'some-function))'.
This evaluates to `nil' when an elisp function is defined or byte-compiled, but
to `t' when it is native-compiled (or actually built-in).
The solution seems to be, like Andrea suggested, to test if a function is
`(and (subrp) (not (subr-native-elisp-p)))'.
- Re: Getting ready to land native-compilation on master, (continued)
- Re: Getting ready to land native-compilation on master, Stefan Kangas, 2021/04/09
- Re: Getting ready to land native-compilation on master, T.V Raman, 2021/04/09
- Re: Getting ready to land native-compilation on master, Pip Cet, 2021/04/09
- Re: Getting ready to land native-compilation on master, Thierry Volpiatto, 2021/04/09
- Re: Getting ready to land native-compilation on master, Jens C . Jensen, 2021/04/09
Re: Getting ready to land native-compilation on master, Andrea Corallo, 2021/04/09
Re: Getting ready to land native-compilation on master, Sujith Manoharan, 2021/04/09
Re: Getting ready to land native-compilation on master, Alex Bennée, 2021/04/09
Re: Getting ready to land native-compilation on master, Andrea Corallo, 2021/04/09