lib/monkey/parser.rb
def expect_peek(type)
      if peek_token_is(type)
        next_token
        true
      else
        peek_error(type)
        false
      end
    end
# Initialize the parser. It will use the provided lexer.
#
# @param [Lexer] lexer the lexer providing tokens
Initialize the parser. It will use the provided lexer.
Initialize the parser . It will use the provided lexer .
def expect_peek(type)
      if peek_token_is(type)
        next_token
        true
      else
        peek_error(type)
        false
      end
    end
def expect_peek ( type ) if peek_token_is ( type ) next_token true else peek_error ( type ) false end end
Initialize the parser.
Initialize the parser .
type
lexer the lexer providing tokens
lexer the lexer providing tokens