Skip to content
  • Ben Gamari's avatar
    Lexer: Suggest adding 'let' on unexpected '=' token · 1ff7f09b
    Ben Gamari authored and Ben Gamari's avatar Ben Gamari committed
    Summary:
    I've heard numerous fledgling Haskeller's complain about the behavior of
    ghci regarding bindings. While most REPLs accept bindings of the form
    `x = 42`, GHCi is implicitly a `do` block, meaning that the user must
    know to use a `let` to introduce a binding.
    
    Here we suggest to the user that they may need a `let` and give them a
    small example in the event that we find an unexpected `=` token.
    
    Reviewers: austin
    
    Reviewed By: austin
    
    Subscribers: thomie, bgamari
    
    Differential Revision: https://phabricator.haskell.org/D980
    1ff7f09b