diff --git a/special-method-names.html b/special-method-names.html index 1fafe34..cec4b8d 100644 --- a/special-method-names.html +++ b/special-method-names.html @@ -101,8 +101,6 @@ td a:link, td a:visited{border:0}

Computed Attributes

-

FIXME not sure of the wording/depth required here because I don't yet know if I'm going to cover these in a previous chapter. Let's assume I'm not, and I can move the examples later if need be. -
Notes You Want… @@ -733,9 +731,7 @@ class FieldStorage: x.__exit__()
-

This is how the [FIXME-xref] with file idiom works. - -

FIXME-xref to as-yet-unwritten section on function annotations +

This is how the with file idiom works.

# excerpt from io.py:
 def _checkClosed(self, msg=None):
@@ -745,12 +741,12 @@ def _checkClosed(self, msg=None):
         raise ValueError('I/O operation on closed file.'
                          if msg is None else msg)
 
-def __enter__(self) -> 'IOBase':
+def __enter__(self):
     '''Context management protocol.  Returns self.'''
     self._checkClosed()                                
     return self                                        
 
-def __exit__(self, *args) -> None:
+def __exit__(self, *args):
     '''Context management protocol.  Calls close()'''
     self.close()