Make language extensions their own category in the documentation
I.e. instead of .. ghc-flag:: -XUnboxedTuples :shortdesc: Enable the use of unboxed tuple syntax. :type: dynamic :reverse: -XNoUnboxedTuples :category: one simply writes .. extension:: UnboxedTuples :shortdesc: Enable the use of unboxed tuple syntax. This allows language extensions to be referenced as If :extension:`UnboxedTuples` is enabled, then... This directive still creates the entries for the `-XUnboxedTuples` flag, so in particular, Set :ghc-flag:`-XUnboxedTuples` if you have to. still works, and lists of flags in general (e.g. for the manpage) include these. I also removed lots of links from the shortdesc of the extensions, when this link simply points to the section where the extension is defined. I removed the list of `-X` flags from the flag reference table, but added a table of extension under “10.1. Language options” Lots of text in the manual now refers to “extension `Foo`” rather than “flag `-XFoo`”. I consider `-XFoo` a historic artifact that stems from when language extensions were really just flags. These days, the use of `-XFoo` is (IMHO) deprecated: You should be using `LANGUAGE Foo`, or maybe the appropriate field in a `.cabal` file. See 9278994a which did this change to error messages already. Differential Revision: https://phabricator.haskell.org/D4112
Showing
- docs/users_guide/ffi-chap.rst 6 additions, 15 deletionsdocs/users_guide/ffi-chap.rst
- docs/users_guide/flags.py 274 additions, 35 deletionsdocs/users_guide/flags.py
- docs/users_guide/flags.rst 0 additions, 11 deletionsdocs/users_guide/flags.rst
- docs/users_guide/ghci.rst 8 additions, 13 deletionsdocs/users_guide/ghci.rst
- docs/users_guide/glasgow_exts.rst 556 additions, 841 deletionsdocs/users_guide/glasgow_exts.rst
- docs/users_guide/phases.rst 2 additions, 5 deletionsdocs/users_guide/phases.rst
- docs/users_guide/safe_haskell.rst 48 additions, 54 deletionsdocs/users_guide/safe_haskell.rst
- docs/users_guide/what_glasgow_exts_does.rst 31 additions, 31 deletionsdocs/users_guide/what_glasgow_exts_does.rst
Loading
Please register or sign in to comment