On 08/13/10 17:57, Tom Tromey wrote: > Chris> + return ('[%d]' % count, obit) > > It seems like it might be nicer to only print the set bits, something > like bitset. > If it's a sparse vector, yeah, you're right. But it's probably more trouble than it's worth to figure that out and do different things depending, and, on average, it probably dumps more chares to print the indices of the '1's than to print all of the bits. > > Chris> + return ('%s of length %d, capacity %d' > Chris> + % (self.typename, int (length), int (capacity))) > > Doesn't self.typename already include the? > No. typename comes from a string in the dictionary entry for std::vector<.*> and is the same regardless of the template argument.