GNU bug report logs - #69249
bug in native-compile?

Previous Next

Package: emacs;

Reported by: Robert Boyer <robertstephenboyer <at> gmail.com>

Date: Sun, 18 Feb 2024 18:31:05 UTC

Severity: wishlist

Tags: notabug

Done: Stefan Kangas <stefankangas <at> gmail.com>

Bug is archived. No further changes may be made.

Full log


Message #20 received at 69249 <at> debbugs.gnu.org (full text, mbox):

From: Stefan Monnier <monnier <at> iro.umontreal.ca>
To: Robert Boyer <robertstephenboyer <at> gmail.com>
Cc: 69249 <at> debbugs.gnu.org, rms <at> gnu.org
Subject: Re: bug#69249: bug in native-compile?
Date: Sun, 18 Feb 2024 18:32:30 -0500
> ;; However, (native-compile "compile-bug.el") results in the following
> error message:
>
> ;; Compiling file
> /mnt/chromeos/GoogleDrive/MyDrive/Linux/working/compile-bug.el at Fri Feb
> 16 08:25:19 2024
> ;; compile-bug.el:2:45: Warning: Unknown defun property ‘fixnum’ in foo
> ;; compile-bug.el:2:45: Warning: Unknown defun property ‘vector’ in foo

First thing: these are not error messages!  They're *warnings*!

`batch-byte-compile` also gives those warnings, because ELisp does not
know those declarations.  The native compiler does support some type
annotations, but they do not take this shape.

I presume you took those from some other Lisp dialect, but that won't do
you much good.  Scheme is not Clojure is not Common Lisp is not ELisp ...

BTW, A more recent Emacs would give you an additional warning:

    Warning: file has no ‘lexical-binding’ directive on its first line

So, I see no bug.  Did the resulting native-compile misbehave in
any way?  I presume you're worried about its performance.
If so, do you have concrete code where you measured the performance and
were disappointed and where you have good reasons to believe that type
annotations would make a difference?  If so, we'd be interested to see
your code to try and improve our compiler.


        Stefan





This bug report was last modified 81 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.