[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Missing functions? (custom-initialize-safe-set, custom-initialize-sa

From: Eli Zaretskii
Subject: Re: Missing functions? (custom-initialize-safe-set, custom-initialize-safe-default)
Date: Fri, 15 Jun 2018 10:37:34 +0300

> From: Adam Porter <address@hidden>
> Date: Thu, 14 Jun 2018 18:47:20 -0500
> ‘custom-initialize-safe-set’
> ‘custom-initialize-safe-default’
>      These functions behave like ‘custom-initialize-set’
>      (‘custom-initialize-default’, respectively), but catch errors.
>      If an error occurs during initialization, they set the
>      variable to ‘nil’ using ‘set-default’, and signal no error.
>      These functions are meant for options defined in pre-loaded
>      files, where the STANDARD expression may signal an error
>      because some required variable or function is not yet defined.
>      The value normally gets updated in ‘startup.el’, ignoring the
>      value computed by ‘defcustom’.  After startup, if one unsets
>      the value and reevaluates the ‘defcustom’, the STANDARD
>      expression can be evaluated without error.
> However, I cannot find those functions defined anywhere, in either
> Emacs 25 or 26.  Searching the git history, I see they were added in
> 2005 in commit 8cb9beb32163fa3ce3b052ced646fd673814ddc6.  Then they
> were removed in 2009 in commit
> adba8116c3a918f2f091600b60ea1700c9ea7362, however there was no reason
> given, and they were not removed from the manual.

Right.  I have now removed them from the manual.

The reason for their removal was that their introduction was a mistake
in interpreting the reason for the errors signaled by
custom-initialize-set and custom-initialize-default: they signaled
errors because the variables couldn't be initialized at build time,
since the conditions for their correct initialization couldn't be met
at build time.  The commit which removed these functions introduced
custom-initialize-delay, which delays the actual initialization to the
next Emacs startup, and all the uses of the removed functions were
replaced by this new function.

> I noticed this because, if I understood the manual correctly, they
> sounded like they might be useful to fix a problem I was having.

What is the problem you were having?

reply via email to

[Prev in Thread] Current Thread [Next in Thread]