mirror of
https://github.com/python/cpython.git
synced 2025-10-09 16:34:44 +00:00
SF bug 917108: warnings.py does not define _test().
Removed the entire __name__ == '__main__' block.
This commit is contained in:
parent
93d448198b
commit
6602520473
1 changed files with 3 additions and 8 deletions
|
@ -249,11 +249,6 @@ def _getcategory(category):
|
||||||
return cat
|
return cat
|
||||||
|
|
||||||
# Module initialization
|
# Module initialization
|
||||||
if __name__ == "__main__":
|
_processoptions(sys.warnoptions)
|
||||||
import __main__
|
simplefilter("ignore", category=OverflowWarning, append=1)
|
||||||
sys.modules['warnings'] = __main__
|
simplefilter("ignore", category=PendingDeprecationWarning, append=1)
|
||||||
_test()
|
|
||||||
else:
|
|
||||||
_processoptions(sys.warnoptions)
|
|
||||||
simplefilter("ignore", category=OverflowWarning, append=1)
|
|
||||||
simplefilter("ignore", category=PendingDeprecationWarning, append=1)
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue