private void parseVar()
{
    switch(currentToken.kind)
    {
        case Token.NAME:
        {
            parseName();
            if (prefixexp1Starters())
            {                
                parsePrefixexp1();
                parsePrefixexp2();
                if (flag == 1)
                    error = true;
                if (currentToken.kind == Token.LBRACKET)
                {
                    acceptIt();
                    parseExp();
                    accept(Token.RBRACKET);
                }
                else if (currentToken.kind == Token.DOT)
                {
                    acceptIt();
                    parseName();
                }
            }
            else
                dummy();
            break;
            
        }
        case Token.LPAREN:
        {
            acceptIt();
            parseExp();
            accept(Token.RPAREN);
            parsePrefixexp1();
            parsePrefixexp2();
            if (flag == 1)
                error = true;
            if(currentToken.kind == Token.LBRACKET)
            {
                acceptIt();
                parseExp();
                accept(Token.RBRACKET);
            }
            else if (currentToken.kind == Token.DOT)
            {
                acceptIt();
                parseName();
            }
            break;
        }
        default:
            error = true;
    } 
}