\f
Lisp_Object Vfeatures;
-DEFUN ("featurep", Ffeaturep, 1, 2, 0, /*
+DEFUN ("featurep", Ffeaturep, 1, 1, 0, /*
Return non-nil if feature FEXP is present in this Emacs.
Use this to conditionalize execution of lisp code based on the
presence or absence of emacs or environment extensions.
for supporting multiple Emacs variants, lobby Richard Stallman at
<bug-gnu-emacs@prep.ai.mit.edu>.
*/
- (fexp, console))
+ (fexp))
{
#ifndef FEATUREP_SYNTAX
CHECK_SYMBOL (fexp);
if (SYMBOLP (fexp))
{
/* Original definition */
- return (NILP (Fmemq (fexp, Vfeatures))
- &&
- NILP (Fmemq (fexp,
- CONSOLE_FEATURES (decode_console (console)))))
- ? Qnil : Qt;
+ return NILP (Fmemq (fexp, Vfeatures)) ? Qnil : Qt;
}
else if (INTP (fexp) || FLOATP (fexp))
{
CHECK_SYMBOL (feature);
if (!NILP (Vautoload_queue))
Vautoload_queue = Fcons (Fcons (Vfeatures, Qnil), Vautoload_queue);
-
tem = Fmemq (feature, Vfeatures);
if (NILP (tem))
Vfeatures = Fcons (feature, Vfeatures);
return feature;
}
-DEFUN ("provide-on-console", Fprovide_on_console, 2, 2, 0, /*
-Announce that FEATURE is a feature of the current Emacs.
-This function updates the value of `console-features' for the provided CONSOLE.
-*/
- (feature, console))
-{
- Lisp_Object tem;
- CHECK_SYMBOL (feature);
-
- if (SYMBOLP (console))
- {
- struct console_methods* meths = decode_console_type (console, ERROR_ME);
-
- tem = Fmemq (feature, CONMETH_FEATURES (meths));
- if (NILP (tem))
- CONMETH_FEATURES (meths) =
- Fcons (feature, CONMETH_FEATURES (meths));
- }
- else
- {
- struct console* pconsole;
- CHECK_CONSOLE (console);
-
- pconsole = decode_console (console);
- tem = Fmemq (feature, CONSOLE_FEATURES (pconsole));
- if (NILP (tem))
- CONSOLE_FEATURES (pconsole) =
- Fcons (feature, CONSOLE_FEATURES (pconsole));
- }
- return feature;
-}
-
DEFUN ("require", Frequire, 1, 2, 0, /*
If feature FEATURE is not loaded, load it from FILENAME.
If FEATURE is not a member of the list `features', then the feature
CHECK_SYMBOL (feature);
tem = Fmemq (feature, Vfeatures);
LOADHIST_ATTACH (Fcons (Qrequire, feature));
- if (!NILP (tem)
- ||
- !NILP (Fmemq (feature, CONSOLE_FEATURES
- (XCONSOLE (Fselected_console ())))))
+ if (!NILP (tem))
return feature;
else
{
DEFSUBR (Ffeaturep);
DEFSUBR (Frequire);
DEFSUBR (Fprovide);
- DEFSUBR (Fprovide_on_console);
DEFSUBR (Fbase64_encode_region);
DEFSUBR (Fbase64_encode_string);
DEFSUBR (Fbase64_decode_region);