[GHC] #14421: LambdaCase should be suggested if it is used but not enabled

#14421: LambdaCase should be suggested if it is used but not enabled -------------------------------------+------------------------------------- Reporter: tomjaguarpaw | Owner: (none) Type: bug | Status: new Priority: normal | Milestone: Component: Compiler | Version: 8.2.1 Keywords: | Operating System: Unknown/Multiple Architecture: | Type of failure: None/Unknown Unknown/Multiple | Test Case: | Blocked By: Blocking: | Related Tickets: Differential Rev(s): | Wiki Page: -------------------------------------+------------------------------------- If I try to make a multiparameter typeclass GHC (well, GHCi here) advises me to turn on {{{MultiParamTypeClasses}}} {{{ Prelude> class C a b where ... (Use MultiParamTypeClasses to allow multi-parameter classes) }}} But if I try to use {{{\case}}} it doesn't give me a helpful suggestion {{{ Prelude> :t \case (_,_) -> () <interactive>:1:2: error: parse error on input ‘case’ }}} Could it? -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/14421 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler

#14421: LambdaCase should be suggested if it is used but not enabled -------------------------------------+------------------------------------- Reporter: tomjaguarpaw | Owner: (none) Type: bug | Status: closed Priority: normal | Milestone: Component: Compiler | Version: 8.2.1 Resolution: fixed | Keywords: Operating System: Unknown/Multiple | Architecture: | Unknown/Multiple Type of failure: None/Unknown | Test Case: Blocked By: | Blocking: Related Tickets: | Differential Rev(s): Phab:D4260 Wiki Page: | -------------------------------------+------------------------------------- Changes (by sighingnow): * status: new => closed * differential: => Phab:D4260 * resolution: => fixed Comment: This ticket has already implemented in the `BlockArguments` patch, which will be included in ghc-8.6.1. With ghc-HEAD, you will get: {{{#!hs Prelude> :t \case (_,_) -> () <interactive>:1:2: error: Illegal lambda-case (use -XLambdaCase) }}} -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/14421#comment:1 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler

#14421: LambdaCase should be suggested if it is used but not enabled -------------------------------------+------------------------------------- Reporter: tomjaguarpaw | Owner: (none) Type: bug | Status: closed Priority: normal | Milestone: 8.6.1 Component: Compiler | Version: 8.2.1 Resolution: fixed | Keywords: Operating System: Unknown/Multiple | Architecture: | Unknown/Multiple Type of failure: None/Unknown | Test Case: Blocked By: | Blocking: Related Tickets: | Differential Rev(s): Phab:D4260 Wiki Page: | -------------------------------------+------------------------------------- Changes (by sighingnow): * milestone: => 8.6.1 -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/14421#comment:2 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler

#14421: LambdaCase should be suggested if it is used but not enabled -------------------------------------+------------------------------------- Reporter: tomjaguarpaw | Owner: (none) Type: bug | Status: closed Priority: normal | Milestone: 8.6.1 Component: Compiler | Version: 8.2.1 (Parser) | Resolution: fixed | Keywords: Operating System: Unknown/Multiple | Architecture: | Unknown/Multiple Type of failure: None/Unknown | Test Case: | parser/should_fail/ParserNoLambdaCase Blocked By: | Blocking: Related Tickets: | Differential Rev(s): Phab:D4260 Wiki Page: | -------------------------------------+------------------------------------- Changes (by sighingnow): * testcase: => parser/should_fail/ParserNoLambdaCase * component: Compiler => Compiler (Parser) -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/14421#comment:3 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler
participants (1)
-
GHC