def __eq__(self, other):
if not hasattr(other, '<STR_LIT:name>') or not hasattr(other, '<STR_LIT>') or not hasattr(other, '<STR_LIT>') or self.name != other.name or self.attrs != other.attrs or len(self) != len(other):<EOL><INDENT>return False<EOL><DEDENT>for i in range(<NUM_LIT:0>, len(self.contents)):<EOL><INDENT>if self.contents[i] != other.contents[i]:<EOL><INDENT>return False<EOL><DEDENT><DEDENT>return True<EOL>
Returns true iff this tag has the same name, the same attributes,
        and the same contents (recursively) as the given tag.

        NOTE: right now this will return false if two tags have the
        same attributes in a different order. Should this be fixed?