def get_ID_text(token):
    """
    Get the text from the ID token.
    Strips off leading slash escape if present
    """
    if isinstance(token, CommonToken):
        text = token.text
    else:
        text = token.getText()

    text = text.lstrip('\\')
    return text