Fix off-by-one indentation error

This commit is contained in:
Collin Winter 2007-02-09 14:50:40 +00:00
parent fd91896d80
commit 0a3078f1cc
1 changed files with 18 additions and 18 deletions

View File

@ -215,24 +215,24 @@ The following translations will be performed:
except E as V:
handle(V)
2. ``raise E, V`` as a way of "casting" an exception to another
class. Taking an example from
distutils.compiler.unixcompiler ::
try:
self.spawn(pp_args)
except DistutilsExecError as msg:
raise CompileError(msg)
This would be better expressed as ::
try:
self.spawn(pp_args)
except DistutilsExecError as msg:
raise CompileError from msg
Using the ``raise ... from ...`` syntax introduced in
PEP 344.
2. ``raise E, V`` as a way of "casting" an exception to another
class. Taking an example from
distutils.compiler.unixcompiler ::
try:
self.spawn(pp_args)
except DistutilsExecError as msg:
raise CompileError(msg)
This would be better expressed as ::
try:
self.spawn(pp_args)
except DistutilsExecError as msg:
raise CompileError from msg
Using the ``raise ... from ...`` syntax introduced in
PEP 344.
References