'Determine the type of reference of a target.
:Return: A 2-tuple, one of:
- \'refname\' and the indirect reference name
- \'refuri\' and the URI
- \'malformed\' and a system_message node'

def parse_target(self, block, block_text, lineno):

    if (block and (block[(-1)].strip()[(-1):] == '_')):
        reference = '    '.join([line.strip() for line in block])
        refname = self.is_reference(reference)
        if refname:
            return ('refname', refname)
    reference = ''.join([''.join(line.split()) for line in block])
    return ('refuri', unescape(reference))
