'Read the next token and raise an exception if it isn\'t EOL or
EOF.
@raises dns.exception.SyntaxError:
@rtype: string'

def get_eol(self):

    token = self.get()
    if (not token.is_eol_or_eof()):
        raise dns.exception.SyntaxError(('expected    EOL    or    EOF,    got    %d    "%s"' % (token.ttype, token.value)))
    return token.value
