Opened 3 years ago

Closed 3 years ago

Last modified 2 years ago

#13791 closed bug (fixed)

Document allowed syntax in WARNING and DEPRECATED pragmas

Reported by: phischu Owned by:
Priority: lowest Milestone: 8.2.1
Component: Compiler Version: 8.0.2
Keywords: Cc:
Operating System: Unknown/Multiple Architecture: Unknown/Multiple
Type of failure: Documentation bug Test Case:
Blocked By: Blocking:
Related Tickets: Differential Rev(s):
Wiki Page:

Description

GHC accepts the following deprecation pragma:

{-# DEPRECATED f ["f is deprecated","use g instead"] #-}
f :: a -> a
f x = x

The deprecation message here is a list of strings. I didn't expect this to be allowed because https://downloads.haskell.org/~ghc/latest/docs/html/users_guide/glasgow_exts.html#warning-and-deprecated-pragmas only shows examples where the deprecation message is a single string.

Are there other forms of deprecation message allowed by GHC?

Change History (3)

comment:1 Changed 3 years ago by Ben Gamari <ben@…>

In 8f72608/ghc:

users-guide: Document multi-line DEPRECATED pragmas

Fixes #13791.

[skip ci]

Test Plan: Read it

Reviewers: austin

Subscribers: rwbarton, thomie

GHC Trac Issues: #13791

Differential Revision: https://phabricator.haskell.org/D3639

comment:2 Changed 3 years ago by bgamari

Milestone: 8.2.1
Resolution: fixed
Status: newclosed

comment:3 Changed 2 years ago by bgamari

Note: See TracTickets for help on using tickets.