unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: Stefan Monnier via "Bug reports for GNU Emacs, the Swiss army knife of text editors" <bug-gnu-emacs@gnu.org>
To: 56648@debbugs.gnu.org
Subject: bug#56648: 29.0.50; Need for `compiled-function-p`
Date: Tue, 19 Jul 2022 16:43:27 -0400	[thread overview]
Message-ID: <jwvtu7cbzps.fsf@iro.umontreal.ca> (raw)

Package: Emacs
Version: 29.0.50


I think we need something like `compiled-function-p`, i.e. a function
which will return non-nil for both byte-code and native-code functions.
Its definition would be

    (defun compiled-function-p (obj)
      "<Appropriate doc here>"
      (or (byte-code-function-p obj)
          (subr-native-elisp-p obj)))

This is because `byte-code-function-p` shouldn't be changed to return
non-nil for native-code functions (both because it would break a lot of
code and because the name would be too confusing), but several uses of
`byte-code-function-p` actually want to know "is this an (inefficient)
source code function or not" (e.g. in unidata-gen.el,
loadup.el, bytecomp.el, ...).


        Stefan






             reply	other threads:[~2022-07-19 20:43 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-07-19 20:43 Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors [this message]
     [not found] ` <handler.56648.B.165826342614243.ack@debbugs.gnu.org>
2022-07-22  5:07   ` bug#56648: Acknowledgement (29.0.50; Need for `compiled-function-p`) Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
2022-07-23  2:55     ` Mike Kupfer
2022-07-23 13:51       ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
2022-07-23  4:30 ` bug#56648: 29.0.50; Need for `compiled-function-p` Lars Ingebrigtsen
2022-07-24  0:27   ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
2022-07-24  9:22     ` Lars Ingebrigtsen
2022-08-14 16:30       ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
2022-08-14 16:34         ` Eli Zaretskii
2022-08-14 16:47           ` Lars Ingebrigtsen
2022-08-14 16:53             ` Eli Zaretskii
2022-08-14 17:27           ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
2022-08-14 16:49         ` Eli Zaretskii
2022-08-14 17:51           ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
2022-08-14 18:03             ` Eli Zaretskii
2022-08-15  2:36               ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=jwvtu7cbzps.fsf@iro.umontreal.ca \
    --to=bug-gnu-emacs@gnu.org \
    --cc=56648@debbugs.gnu.org \
    --cc=monnier@iro.umontreal.ca \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).