Add a new warning gategory, ResourceWarning, as discussed on python-dev.  It is silent by default,
except when configured --with-pydebug.

Emit this warning from the GC shutdown procedure, rather than just printing to stderr.
diff --git a/Doc/library/warnings.rst b/Doc/library/warnings.rst
index 309fec5..64689ad 100644
--- a/Doc/library/warnings.rst
+++ b/Doc/library/warnings.rst
@@ -82,6 +82,9 @@
 | :exc:`BytesWarning`              | Base category for warnings related to         |
 |                                  | :class:`bytes` and :class:`buffer`.           |
 +----------------------------------+-----------------------------------------------+
+| :exc:`ResourceWarning`           | Base category for warnings related to         |
+|                                  | resource usage.                               |
++----------------------------------+-----------------------------------------------+
 
 
 While these are technically built-in exceptions, they are documented here,