[GHC] #11044: Parse error on empty multi-line deprecation warnings

#11044: Parse error on empty multi-line deprecation warnings -------------------------------------+------------------------------------- Reporter: inaki | Owner: Type: bug | Status: new Priority: normal | Milestone: Component: Compiler | Version: 7.10.2 (Parser) | Keywords: | Operating System: Unknown/Multiple Architecture: | Type of failure: GHC rejects Unknown/Multiple | valid program Test Case: | Blocked By: Blocking: | Related Tickets: Differential Rev(s): | Wiki Page: -------------------------------------+------------------------------------- Bug #3303 introduced support for multi-line deprecation messages, with syntax {{{ {-# DEPRECATED someFunction ["One line", "another line"] #-} }}} The following gives a parse error, though: {{{ {-# DEPRECATED someFunction [] #-} }}} I think that it would be reasonable to treat this case as {{{ {-# DEPRECATED somefunction "" #-} }}} For motivation: we ran into this problem when writing bindings to external libraries. The API description for the original library includes deprecation info, with the deprecation messages sometimes spanning multiple lines, so it was convenient to use the list syntax above when generating the Haskell wrappers. But the parse error forced us to special case the case of no deprecation message. We can easily do this, of course, but perhaps the restriction to non-empty lists was not intentional? -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/11044 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler

#11044: Parse error on empty multi-line deprecation warnings -------------------------------------+------------------------------------- Reporter: inaki | Owner: Type: bug | Status: patch Priority: normal | Milestone: 8.0.1 Component: Compiler | Version: 7.10.2 (Parser) | Resolution: | Keywords: Operating System: Unknown/Multiple | Architecture: | Unknown/Multiple Type of failure: GHC rejects | Test Case: valid program | parser/should_compile/T3303 Blocked By: | Blocking: Related Tickets: | Differential Rev(s): Phab:D1433 Wiki Page: | -------------------------------------+------------------------------------- Changes (by thomie): * status: new => patch * testcase: => parser/should_compile/T3303 * differential: => Phab:D1433 * milestone: => 8.0.1 -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/11044#comment:1 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler

#11044: Parse error on empty multi-line deprecation warnings
-------------------------------------+-------------------------------------
Reporter: inaki | Owner:
Type: bug | Status: patch
Priority: normal | Milestone: 8.0.1
Component: Compiler | Version: 7.10.2
(Parser) |
Resolution: | Keywords:
Operating System: Unknown/Multiple | Architecture:
| Unknown/Multiple
Type of failure: GHC rejects | Test Case:
valid program | parser/should_compile/T3303
Blocked By: | Blocking:
Related Tickets: | Differential Rev(s): Phab:D1433
Wiki Page: |
-------------------------------------+-------------------------------------
Comment (by Ben Gamari

#11044: Parse error on empty multi-line deprecation warnings -------------------------------------+------------------------------------- Reporter: inaki | Owner: Type: bug | Status: closed Priority: normal | Milestone: 8.0.1 Component: Compiler | Version: 7.10.2 (Parser) | Resolution: fixed | Keywords: Operating System: Unknown/Multiple | Architecture: | Unknown/Multiple Type of failure: GHC rejects | Test Case: valid program | parser/should_compile/T3303 Blocked By: | Blocking: Related Tickets: | Differential Rev(s): Phab:D1433 Wiki Page: | -------------------------------------+------------------------------------- Changes (by thomie): * status: patch => closed * resolution: => fixed -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/11044#comment:3 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler
participants (1)
-
GHC