Index: pyyaml/trunk/lib3/yaml/parser.py
===================================================================
--- pyyaml/trunk/lib3/yaml/parser.py	(revision 328)
+++ pyyaml/trunk/lib3/yaml/parser.py	(revision 377)
@@ -87,4 +87,9 @@
         self.state = self.parse_stream_start
 
+    def dispose(self):
+        # Reset the state attributes (to clear self-references)
+        self.states = []
+        self.state = None
+
     def check_event(self, *choices):
         # Check the type of the next event.
