Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
7
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Open sidebar
emacs
emacs
Commits
f0a50954
Commit
f0a50954
authored
Aug 04, 1997
by
Richard M. Stallman
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
(Fload): New optional arg MUST-SUFFIX.
parent
1c1e0fe5
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
9 additions
and
4 deletions
+9
-4
src/lread.c
src/lread.c
+9
-4
No files found.
src/lread.c
View file @
f0a50954
...
...
@@ -384,7 +384,7 @@ static void readevalloop ();
static
Lisp_Object
load_unwind
();
static
Lisp_Object
load_descriptor_unwind
();
DEFUN
(
"load"
,
Fload
,
Sload
,
1
,
4
,
0
,
DEFUN
(
"load"
,
Fload
,
Sload
,
1
,
5
,
0
,
"Execute a file of Lisp code named FILE.
\n
\
First try FILE with `.elc' appended, then try with `.el',
\n
\
then try FILE unmodified.
\n
\
...
...
@@ -395,9 +395,11 @@ Print messages at start and end of loading unless\n\
optional third arg NOMESSAGE is non-nil.
\n
\
If optional fourth arg NOSUFFIX is non-nil, don't try adding
\n
\
suffixes `.elc' or `.el' to the specified name FILE.
\n
\
If optional fifth arg MUST-SUFFIX is non-nil, insist on adding
\n
\
the suffixe `.elc' or `.el'; don't accept just FILE.
\n
\
Return t if file exists."
)
(
file
,
noerror
,
nomessage
,
nosuffix
)
Lisp_Object
file
,
noerror
,
nomessage
,
nosuffix
;
(
file
,
noerror
,
nomessage
,
nosuffix
,
must_suffix
)
Lisp_Object
file
,
noerror
,
nomessage
,
nosuffix
,
must_suffix
;
{
register
FILE
*
stream
;
register
int
fd
=
-
1
;
...
...
@@ -432,7 +434,10 @@ Return t if file exists.")
if
(
XSTRING
(
file
)
->
size
>
0
)
{
GCPRO1
(
file
);
fd
=
openp
(
Vload_path
,
file
,
!
NILP
(
nosuffix
)
?
""
:
".elc:.el:"
,
fd
=
openp
(
Vload_path
,
file
,
(
!
NILP
(
nosuffix
)
?
""
:
!
NILP
(
must_suffix
)
?
".elc:.el"
:
".elc:.el:"
),
&
found
,
0
);
UNGCPRO
;
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment