0
0
mirror of https://github.com/python/cpython.git synced 2024-12-01 11:15:56 +01:00
cpython/Python
Guido van Rossum 0aa9ee65ab Moved the raise logic out of the main interpreter loop to a separate function.
The raise logic has one additional feature: if you raise <class>,
<value> where <value> is not an instance, it will construct an
instance using <value> as argument.  If <value> is None, <class> is
instantiated without arguments.  If <value> is a tuple, it is used as
the argument list.

This feature is intended to make it easier to upgrade code from using
string exceptions to using class exceptions; without this feature,
you'd have to change every raise statement from ``raise X'' to ``raise
X()'' and from ``raise X, y'' to ``raise X(y)''.  The latter is still
the recommended form (because it has no ambiguities about the number
of arguments), but this change makes the transition less painful.
1996-12-10 18:07:35 +00:00
..
atof.c
bltinmodule.c Add unistd.h to make gcc -Wall happy. 1996-12-10 15:37:36 +00:00
ceval.c Moved the raise logic out of the main interpreter loop to a separate function. 1996-12-10 18:07:35 +00:00
cgensupport.c
compile.c Keep gcc -Wall happy. 1996-12-05 23:27:02 +00:00
dup2.c
errors.c Add const to error and newstring functions 1996-12-10 15:33:34 +00:00
fmod.c
frozen.c
frozenmain.c
getargs.c Keep gcc -Wall happy. 1996-12-05 23:27:02 +00:00
getcompiler.c
getcopyright.c
getcwd.c
getmtime.c
getopt.c
getplatform.c
getversion.c
graminit.c
hypot.c
import.c Keep gcc -Wall happy. 1996-12-05 23:27:02 +00:00
importdl.c Some extra flags that an HPUX user wants me to add. 1996-12-05 23:15:35 +00:00
importdl.h
Makefile.in
marshal.c Better way to handle 64-bit ints, keeping gcc -Wall happy. 1996-12-10 15:39:04 +00:00
memmove.c
modsupport.c
mystrtoul.c Keep gcc -Wall happy. 1996-12-05 23:27:02 +00:00
pythonmain.c
pythonrun.c Keep gcc -Wall happy. 1996-12-05 23:27:02 +00:00
sigcheck.c
strdup.c
strerror.c
strtod.c
structmember.c
sysmodule.c
thread_cthread.h
thread_foobar.h
thread_lwp.h
thread_nt.h
thread_os2.h
thread_pthread.h
thread_sgi.h
thread_solaris.h
thread.c Keep gcc -Wall happy. 1996-12-05 23:27:02 +00:00
traceback.c