[PATCH] verify: remove unreachable code to reraise KeyboardInterrupt

Sean Farley sean at farley.io
Sun Dec 20 13:00:40 CST 2015


Yuya Nishihara <yuya at tcha.org> writes:

> # HG changeset patch
> # User Yuya Nishihara <yuya at tcha.org>
> # Date 1450604301 -32400
> #      Sun Dec 20 18:38:21 2015 +0900
> # Node ID bdb06cd254b9ab4f5d5b928f9a976d953fc8cb04
> # Parent  7f38cf67f49e9ac1af8c22f2d57cbd648e2a9d49
> verify: remove unreachable code to reraise KeyboardInterrupt
>
> KeyboardInterrupt should never be caught as it doesn't inherit Exception in
> Python 2.5 or later. And if it was, "interrupted" would be printed twice.
>
> https://docs.python.org/2.7/library/exceptions.html#exception-hierarchy

Yep, looks good to me.


More information about the Mercurial-devel mailing list