'Handle character references as data.'

def handle_charref(self, ref):

    if self.soup.convertEntities:
        data = unichr(int(ref))
    else:
        data = ('&#%s;' % ref)
    self.handle_data(data)
