Commit Graph

123 Commits

Author SHA1 Message Date
Barry Warsaw 83b6709d8e Swap the sense of the -X option vis-a-vis Py_UseClassExceptionsFlag so
that class based exceptions are enabled by default.  -X disables them
in favor of the old-style string exceptions.
1997-08-29 22:20:16 +00:00
Barry Warsaw f488af3360 Parse new command line option -X which enables exception classes. 1997-08-29 21:57:49 +00:00
Guido van Rossum 9b5dbedf43 Attempt to import readline at interactive startup. 1997-08-05 21:34:14 +00:00
Guido van Rossum 5d1770ee24 Py_Cleanup() is now Py_Finalize(). 1997-08-05 02:23:48 +00:00
Guido van Rossum 05f7c50bfd Free the malloc'ed buffer that holds the command once we're done with it.
Instead of calling Py_Exit(sts), call Py_Cleanup() and return sts.
1997-08-02 03:00:42 +00:00
Guido van Rossum 534ac094f9 Removed a bunch of extern declarations of functions that are now
properly declared in Python.h.
1997-07-19 19:51:43 +00:00
Guido van Rossum ed52aacb33 This is no longer the real main program; it now defines Py_Main(), so
it can be placed in the library.

Other, related changes:

- Moved the inspection of some environment variables to
Py_Initialize().

- Got rid of -s option.

- Moved Py_GetProgramName() and related logic to pythonrun.c; call
Py_SetProgramName() instead.

- Print the version header *after* successful initialization.
1997-07-19 19:20:32 +00:00
Guido van Rossum fe4dfc7ce3 Add platform to welcome message. 1997-05-19 18:33:01 +00:00
Guido van Rossum 03ef647847 Add PYTHONHOME to the usage message. 1997-04-30 19:48:59 +00:00
Guido van Rossum b31c7dcb43 OK, I lied. On Windows, _IOLBF seems to be the same as full
buffering, so to get the normal behavior back, I set it to
unbuffered.
1997-04-11 22:19:12 +00:00
Guido van Rossum 2a212191f8 Change in when and how stdin and stdout are set to line-buffering.
This used to be done whenever stdin was interactive.  Now we only do
it when the -i flag is given.  Also (and this is the real reason for
this fix) we explicitly allocate a buffer -- this seems to be
necessary on Windows.
1997-04-11 21:57:53 +00:00
Guido van Rossum 7614da6b87 Add -O option which sets Py_OptimizeFlag to avoid emitting SET_LINENO.
Fred: sorry, I hadn't checked these changes in.  This should fix your
tracebacks!
1997-03-03 19:14:45 +00:00
Guido van Rossum 129e91aa77 Add parentheses around && within || as gcc -Wall advises. 1997-02-14 21:00:50 +00:00
Guido van Rossum 775af91911 My version of Lee Busby's patches to make '-i' pretend stdin is a tty
even if it isn't.  Changes:

- set the global flag Py_InteractiveFlag when -i is given
- call Py_FdIsInteractive() instead of isatty()
- make stdin unbuffered, too, when using -u
- make stdin and stdout line buffered, when stdin is interactive and not -u

Note that setting the environment variable PYTHONINSPECT does not have
these extra effects of -i.  (Should it?)

Unlike Lee's changes, I don't set change the prompt to go to stderr
when -i is given.
1997-02-14 19:50:32 +00:00
Guido van Rossum 3e7ae7ab17 Fix the _setmode() patch for MS_WINDOWS: include <fcntl.h> and use
fileno(std*).
1997-01-17 22:05:38 +00:00
Guido van Rossum f22d7e2c69 On Windows, -u implies binary mode for stdin/stdout
(as well as unbuffered stdout/stderr).
1997-01-11 19:28:55 +00:00
Guido van Rossum 66a7013c5c Include unistd.h to keep gcc -Wall happy. 1996-12-09 18:46:58 +00:00
Guido van Rossum a376cc5cc8 Keep gcc -Wall happy. 1996-12-05 23:43:35 +00:00
Guido van Rossum d266eb460e New permission notice, includes CNRI. 1996-10-25 14:44:06 +00:00
Guido van Rossum ac56b03f9a New style names for getprogramname and getargcargv 1996-07-21 02:33:38 +00:00
Guido van Rossum 8026febbd6 Made comment for getprogramname() more helpful. 1996-06-20 16:49:26 +00:00
Guido van Rossum 582646aecc grand renaming; added copyright to some files 1996-05-28 22:30:17 +00:00
Guido van Rossum 667d704997 Initial revision 1995-08-04 04:20:48 +00:00