diff options
author | Tim Peters <tim.peters@gmail.com> | 2004-03-21 17:06:20 (GMT) |
---|---|---|
committer | Tim Peters <tim.peters@gmail.com> | 2004-03-21 17:06:20 (GMT) |
commit | 660252047347d1effbe00162ff990fc7a57d4d2a (patch) | |
tree | 9005a52cce5ef585592fa7a69b0e8229227cfd7f | |
parent | 93d448198b2a883639ed2c2e30f1f0fd7f002a90 (diff) | |
download | cpython-660252047347d1effbe00162ff990fc7a57d4d2a.zip cpython-660252047347d1effbe00162ff990fc7a57d4d2a.tar.gz cpython-660252047347d1effbe00162ff990fc7a57d4d2a.tar.bz2 |
SF bug 917108: warnings.py does not define _test().
Removed the entire __name__ == '__main__' block.
-rw-r--r-- | Lib/warnings.py | 11 |
1 files changed, 3 insertions, 8 deletions
diff --git a/Lib/warnings.py b/Lib/warnings.py index c6e6006..849cced 100644 --- a/Lib/warnings.py +++ b/Lib/warnings.py @@ -249,11 +249,6 @@ def _getcategory(category): return cat # Module initialization -if __name__ == "__main__": - import __main__ - sys.modules['warnings'] = __main__ - _test() -else: - _processoptions(sys.warnoptions) - simplefilter("ignore", category=OverflowWarning, append=1) - simplefilter("ignore", category=PendingDeprecationWarning, append=1) +_processoptions(sys.warnoptions) +simplefilter("ignore", category=OverflowWarning, append=1) +simplefilter("ignore", category=PendingDeprecationWarning, append=1) |