* Added a special case in Elk_Init for the forthcoming libelk.

git-svn-id: svn://svn.zoy.org/elk/trunk@17 55e467fa-43c5-0310-a8a2-de718669efc6
This commit is contained in:
sam 2003-08-21 09:51:00 +00:00
parent 86881e9a5f
commit f66cc0d573
1 changed files with 4 additions and 1 deletions

View File

@ -284,11 +284,14 @@ int main (int ac, char **av) {
Set_Error_Tag ("top-level"); Set_Error_Tag ("top-level");
#ifdef NOMAIN #ifdef NOMAIN
if ((loadfile = toplevel) == 0) { if (toplevel == 0) {
Interpreter_Initialized = 1; Interpreter_Initialized = 1;
GC_Debug = debug; GC_Debug = debug;
return; return;
} }
/* Special case: if toplevel is "", act as if run from main() */
if (loadfile == 0 && toplevel[0] != '\0')
loadfile = toplevel;
#endif #endif
if (loadfile == 0) if (loadfile == 0)
loadfile = "toplevel.scm"; loadfile = "toplevel.scm";