Esempio n. 1
0
        private Identifier parseIdentifier(Tipo tipo)
        {
            Identifier id = null;

            // grab ID value if token type is ID
            if (token.TokenType == TokenType.ID)
            {
                id = new Identifier(token, tipo);
            }
            if (entornoActual.Get(token) != null)
            {
                error(token.Lexeme + " ha sido declarado previamente");
            }
            entornoActual.Put(token, id);
            eat(TokenType.ID);
            return(id);
        }