Issue #23615: Modules bz2, tarfile and tokenize now can be reloaded with

imp.reload().  Patch by Thomas Kluyver.
This commit is contained in:
Serhiy Storchaka 2015-03-11 17:18:03 +02:00
parent 13be8c2691
commit cf4a2f29ad
5 changed files with 7 additions and 6 deletions

View file

@ -38,6 +38,7 @@ __credits__ = "Gustavo Niemeyer, Niels Gust\u00e4bel, Richard Townsend."
#---------
# Imports
#---------
from builtins import open as bltn_open
import sys
import os
import io
@ -2421,7 +2422,6 @@ def is_tarfile(name):
except TarError:
return False
bltn_open = open
open = TarFile.open