emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: Max Nikulin <manikulin@gmail.com>
To: emacs-orgmode@gnu.org
Subject: Re: org-fold documentation
Date: Sat, 7 May 2022 14:34:37 +0700	[thread overview]
Message-ID: <t557ee$a3d$1@ciao.gmane.io> (raw)
In-Reply-To: <87leveyo3p.fsf@localhost>

On 07/05/2022 11:15, Ihor Radchenko wrote:
> Vikas Rawal writes:
> 
>> After upgrading to 9.5.3, I am getting warnings such as this, which I
>> suspect are due to org-fold.et.
>>
>> Warning (comp): org-fold.el:834:27: Warning: Unused lexical variable
>> `org-hide-macro-markers' Disable showing Disable logging
>> Warning (comp): org.el:76:30: Warning: Package cl is deprecated Disable
>> showing Disable logging
>> Warning (comp): ox.el:79:1: Warning: the function ‘org-back-to-heading’
>> might not be defined at runtime. Disable showing Disable logging
>> Warning (comp): ox.el:79:1: Warning: the function
>> ‘org-next-visible-heading’ might not be defined at runtime. Disable showing
>> Disable logging
>> Warning (comp): ox.el:79:1: Warning: the function ‘org-at-heading-p’ might
>> not be defined at runtime. Disable showing Disable logging
>>
>> Is org-fold.el documented already?

I see that org-fold-core.el has several screens of comments at the top 
of the file. Is it what you are asking for?

>> Any pointers to what might be causing
>> the above?
> 
> These are native-comp warnings. They are not uncommon when
> native-compiling Org (not only org-fold.el) and generally harmless.
> If you are sufficiently annoyed with them, most of these warnings can be
> "fixed" by declaring the missing functions. The functions are available
> at runtime, but not during native-compilation.

The org-fold.el file has some `declare-function' forms. Do you mean it 
is just necessary to declare more names?

In c++ to speed-up compiling and to deal with circular dependence for 
declarations, there are some *_fwd.h header files with forward 
declarations. Such files are enough to make compiler aware that some 
word is a class, a type, or a function with arguments of certain types. 
They do not allow to allocate proper amount of space for an object and 
to construct it (it is necessary to "#include" full header for such 
purpose), but while e.g. a pointer is passed in the file to be compiled 
then nothing more is required.

Will it help to create files like org-fwd.el with function declarations 
to allow other packages (even from org-mode) to use "(require 
'org-fwd.el)" instead of adding a lot of `declare-function' forms that 
must be kept in sync with function definitions?

It is easier to notice new warnings introduced by changes when where 
were no warnings before.



  parent reply	other threads:[~2022-05-07  7:36 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-05-05 18:03 org-fold documentation Vikas Rawal
2022-05-07  4:15 ` Ihor Radchenko
2022-05-07  4:26   ` Samuel Wales
2022-05-07  4:41     ` Ihor Radchenko
2022-05-07  4:45       ` Samuel Wales
2022-05-07  5:17         ` Ihor Radchenko
2022-05-07  7:34   ` Max Nikulin [this message]
2022-05-08  7:18     ` Ihor Radchenko
2022-05-07  9:25   ` Vikas Rawal
2022-05-07 10:22     ` Eric S Fraga

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.orgmode.org/

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

  git send-email \
    --in-reply-to='t557ee$a3d$1@ciao.gmane.io' \
    --to=manikulin@gmail.com \
    --cc=emacs-orgmode@gnu.org \
    /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/org-mode.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).