Don't lie in __all__ attributes when SSL is not available: only add the SSL
classes when they are actually created.
diff --git a/Lib/imaplib.py b/Lib/imaplib.py
index 7e3a046..8ca9358 100644
--- a/Lib/imaplib.py
+++ b/Lib/imaplib.py
@@ -24,7 +24,7 @@
import binascii, os, random, re, socket, sys, time
-__all__ = ["IMAP4", "IMAP4_SSL", "IMAP4_stream", "Internaldate2tuple",
+__all__ = ["IMAP4", "IMAP4_stream", "Internaldate2tuple",
"Int2AP", "ParseFlags", "Time2Internaldate"]
# Globals
@@ -1205,6 +1205,7 @@
"""
return self.sslobj
+ __all__.append("IMAP4_SSL")
class IMAP4_stream(IMAP4):