'Returns the target CPInfo field.'

def get_cp_entry(self):

    assert (self.value < self['/constant_pool_count'].value)
    if (self.allow_zero and (not self.value)):
        return None
    cp_entry = self[('/constant_pool/constant_pool[%d]' % self.value)]
    assert isinstance(cp_entry, CPInfo)
    if self.target_types:
        assert (cp_entry.constant_type in self.target_types)
    return cp_entry
