[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: frame-environment
From: |
Juanma Barranquero |
Subject: |
Re: frame-environment |
Date: |
Sun, 18 Jan 2009 03:53:15 +0100 |
On Sun, Jan 18, 2009 at 02:52, Stefan Monnier <address@hidden> wrote:
> An entry of the form "VAR" instead of "VAR=VAL". Such an entry means
> "remove VAR from the environment", IIRC.
Is that standard terminology? I've never heard it.
> This is not the "frame environment" (which is the `environment'
> frame-parameter).
Sorry, I should've said "it only uses the frame parameter to look for
one variable, DISPLAY".
The docstring needs a patch like the attached one, which more
accurately reflects what Fgetenv_internal does. I say "like" because
that docstring still doesn't explain the special case where
if ((variable is "DISPLAY")
&& (ENV is not a list)
&& ("DISPLAY" not found in `process-environment')
{
if (ENV is a frame)
return `display' parameter of ENV;
else if (ENV is nil)
return `display' parameter of selected frame;
else
error;
}
Juanma
Index: src/callproc.c
===================================================================
RCS file: /cvsroot/emacs/emacs/src/callproc.c,v
retrieving revision 1.243
diff -u -2 -r1.243 callproc.c
--- src/callproc.c 8 Jan 2009 03:15:26 -0000 1.243
+++ src/callproc.c 18 Jan 2009 02:30:41 -0000
@@ -1391,13 +1391,9 @@
the environment. Otherwise, value is a string.
-This function searches `process-environment' for VARIABLE. If it is
-not found there, then it continues the search in the environment list
-of the selected frame.
+This function searches `process-environment' for VARIABLE.
If optional parameter ENV is a list, then search this list instead of
-`process-environment', and return t when encountering a negative entry.
+`process-environment', and return t when encountering a negative entry
+\(an entry for a variable with no value). */)
-
-If it is a frame, then this function will ignore `process-environment' and
-will simply look up the variable in that frame's environment. */)
(variable, env)
Lisp_Object variable, env;
Re: frame-environment, Chong Yidong, 2009/01/17
Re: frame-environment, Stefan Monnier, 2009/01/17