ucntcme at ucntcme at
Fri Jul 15 00:08:42 CEST 2005

well that appears to have been munged up ...
that tell() belongs immediately after self.str. making it

class FrankenString:
  def __init__(self,string=None):
	self.str = StringIO(string)
	self.atEnd = False
	self.lastidx = 0 =
	self.tell = self.str.tell
  def __iter__(self):
	while not self.atEnd:
		char =
		idx = self.str.tell()
		if self.lastidx == idx:
			self.atEnd = True
		self.lastidx = idx
		yield char

More information about the Python-list mailing list