From 0e478407f3aa03425011f6ab5081d39eeca7df05 Mon Sep 17 00:00:00 2001 From: Takenobu Tani Date: Mon, 23 Sep 2019 16:34:03 +0900 Subject: users-guide: Fix links and formats for GHC 8.10 This commit only fixes links and markdown syntax. [skip ci] --- docs/users_guide/8.10.1-notes.rst | 24 ++++++++++++------------ docs/users_guide/debugging.rst | 2 +- docs/users_guide/extending_ghc.rst | 8 ++++---- docs/users_guide/ffi-chap.rst | 6 +++--- docs/users_guide/ghci.rst | 2 +- docs/users_guide/glasgow_exts.rst | 4 ++-- docs/users_guide/safe_haskell.rst | 2 +- 7 files changed, 24 insertions(+), 24 deletions(-) diff --git a/docs/users_guide/8.10.1-notes.rst b/docs/users_guide/8.10.1-notes.rst index f0cd9006ad..8d70c7b34c 100644 --- a/docs/users_guide/8.10.1-notes.rst +++ b/docs/users_guide/8.10.1-notes.rst @@ -10,7 +10,7 @@ following sections. Highlights ---------- -- The `UnliftedNewtypes` extension. +- The :extension:`UnliftedNewtypes` extension. Full details ------------ @@ -53,8 +53,8 @@ Language data Proxy :: forall k -> k -> Type - See the `section on explicit kind quantification - <#explicit-kind-quantification>`__ for more details. + See the :ref:`section on explicit kind quantification + ` for more details. - Type variables in associated type family default declarations can now be explicitly bound with a ``forall`` when :extension:`ExplicitForAll` is @@ -87,7 +87,7 @@ Language - A new extension :extension:`UnliftedNewtypes` that relaxes restrictions around what kinds of types can appear inside of the data constructor - for a `newtype`. This was proposed in + for a ``newtype``. This was proposed in `GHC proposal #13 `__. Compiler @@ -97,10 +97,10 @@ Compiler :ghc-flag:`-Wredundant-record-wildcards` which warn users when they have redundant or unused uses of a record wildcard match. -- Calls to `memset` and `memcpy` are now unrolled more aggressively +- Calls to ``memset`` and ``memcpy`` are now unrolled more aggressively and the produced code is more efficient on `x86_64` with added - support for 64-bit `MOV`s. In particular, `setByteArray#` and - `copyByteArray#` calls that were not optimized before, now will + support for 64-bit ``MOV``\s. In particular, ``setByteArray#`` and + ``copyByteArray#`` calls that were not optimized before, now will be. See :ghc-ticket:`16052`. - GHC's runtime linker no longer uses global state. This allows programs that use the GHC API to safely use multiple GHC sessions in a single @@ -108,10 +108,10 @@ Compiler global state. - When loading modules that use :extension:`UnboxedTuples` into GHCi, - it will now automatically enable `-fobject-code` for these modules + it will now automatically enable :ghc-flag:`-fobject-code` for these modules and all modules they depend on. Before this change, attempting to load these modules into the interpreter would just fail, and the - only convenient workaround was to enable `-fobject-code` for all + only convenient workaround was to enable :ghc-flag:`-fobject-code` for all modules. - The eventlog now contains events for biographical and retainer profiling. @@ -122,7 +122,7 @@ Compiler GHCi ~~~~ -- Added a command `:instances` to show the class instances available for a type. +- Added a command :ghci-cmd:`:instances` to show the class instances available for a type. - Added new debugger commands :ghci-cmd:`:disable` and :ghci-cmd:`:enable` to disable and re-enable breakpoints. @@ -142,8 +142,8 @@ Template Haskell ``ghc-prim`` library ~~~~~~~~~~~~~~~~~~~~ -- Add new `bitReverse#` primops that, for a `Word` of 8, 16, 32 or 64 bits, - reverse the order of its bits e.g. `0b110001` becomes `0b100011`. +- Add new ``bitReverse#`` primops that, for a ``Word`` of 8, 16, 32 or 64 bits, + reverse the order of its bits e.g. ``0b110001`` becomes ``0b100011``. These primitives use optimized machine instructions when available. ``ghc`` library diff --git a/docs/users_guide/debugging.rst b/docs/users_guide/debugging.rst index 572dd154f8..f8e862e5f0 100644 --- a/docs/users_guide/debugging.rst +++ b/docs/users_guide/debugging.rst @@ -408,7 +408,7 @@ These flags dump various phases of GHC's C-\\- pipeline. :shortdesc: Write output from main C-\\- pipeline passes to files :type: dynamic - If used in conjunction with `-ddump-to-file`, writes dump + If used in conjunction with :ghc-flag:`-ddump-to-file`, writes dump output from main C-\\- pipeline stages to files (each stage per file). .. ghc-flag:: -ddump-cmm-from-stg diff --git a/docs/users_guide/extending_ghc.rst b/docs/users_guide/extending_ghc.rst index 7035e02465..0ed65d13b3 100644 --- a/docs/users_guide/extending_ghc.rst +++ b/docs/users_guide/extending_ghc.rst @@ -234,7 +234,7 @@ be reset with the :ghc-flag:`-fclear-plugins` option. Clear the list of plugins previously specified with :ghc-flag:`-fplugin <-fplugin=⟨module⟩>`. This is useful in GHCi where simply removing the :ghc-flag:`-fplugin <-fplugin=⟨module⟩>` options from - the command line is not possible. Instead `:set -fclear-plugins` can be + the command line is not possible. Instead ``:set -fclear-plugins`` can be used. @@ -634,7 +634,7 @@ plugins is to make it easier to implement development tools. There are several different access points that you can use for defining plugins that access the representations. All these fields receive the list of ``CommandLineOption`` strings that are passed to the compiler using the -:ghc-flag:`-fplugin-opt` flags. +:ghc-flag:`-fplugin-opt=⟨module⟩:⟨args⟩` flags. :: @@ -834,7 +834,7 @@ output: typeCheckPlugin (tc): {$trModule = Module (TrNameS "main"#) (TrNameS "A"#), a = ()} -.. _hole-fit-plugins +.. _hole-fit-plugins: Hole fit plugins ~~~~~~~~~~~~~~~~ @@ -921,7 +921,7 @@ communication between the candidate and fit plugin. The plugin is then defined as by providing a value for the ``holeFitPlugin`` field, a function that takes the ``CommandLineOption`` strings that are passed -to the compiler using the :ghc-flag:`-fplugin-opt` flags and returns a +to the compiler using the :ghc-flag:`-fplugin-opt=⟨module⟩:⟨args⟩` flags and returns a ``HoleFitPluginR``. This function can be used to pass the ``CommandLineOption`` strings along to the candidate and fit plugins respectively. diff --git a/docs/users_guide/ffi-chap.rst b/docs/users_guide/ffi-chap.rst index e3b6f13710..ecfece9dc6 100644 --- a/docs/users_guide/ffi-chap.rst +++ b/docs/users_guide/ffi-chap.rst @@ -16,7 +16,7 @@ Foreign function interface (FFI) GHC (mostly) conforms to the Haskell Foreign Function Interface as specified in the Haskell Report. Refer to the `relevant chapter -_` +`__ of the Haskell Report for more details. FFI support is enabled by default, but can be enabled or disabled @@ -105,8 +105,8 @@ OK: :: .. _ffi-foralls: -Explicit ``forall``s in foreign types -~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +Explicit "forall"s in foreign types +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ The type variables in the type of a foreign declaration may be quantified with an explicit ``forall`` by using the :extension:`ExplicitForAll` language diff --git a/docs/users_guide/ghci.rst b/docs/users_guide/ghci.rst index 9677f8a938..9138f1d774 100644 --- a/docs/users_guide/ghci.rst +++ b/docs/users_guide/ghci.rst @@ -2566,7 +2566,7 @@ commonly used commands. The ``:loc-at`` command requires :ghci-cmd:`:set +c` to be set. -.. ghci-cmd:: :instances ⟨type⟩ +.. ghci-cmd:: :instances; ⟨type⟩ Displays all the class instances available to the argument ⟨type⟩. The command will match ⟨type⟩ with the first parameter of every diff --git a/docs/users_guide/glasgow_exts.rst b/docs/users_guide/glasgow_exts.rst index 9b9e060e92..8ec105f3a0 100644 --- a/docs/users_guide/glasgow_exts.rst +++ b/docs/users_guide/glasgow_exts.rst @@ -9203,8 +9203,8 @@ signature" for a type constructor? These are the forms: data T3 :: forall (k :: Type). k -> Type -- still a CUSK - For a newtype, the rules are the same as they are for a data type - unless `UnliftedNewtypes <#unboxed-newtypes>`__ is enabled. - With `UnliftedNewtypes <#unboxed-newtypes>`__, the type constructor + unless :extension:`UnliftedNewtypes` is enabled. + With :extension:`UnliftedNewtypes`, the type constructor only has a CUSK if a kind signature is present. As with a datatype with a top-level ``::``, all kind variables must introduced after the ``::`` must be explicitly quantified :: diff --git a/docs/users_guide/safe_haskell.rst b/docs/users_guide/safe_haskell.rst index 3911b9f41d..b95364531f 100644 --- a/docs/users_guide/safe_haskell.rst +++ b/docs/users_guide/safe_haskell.rst @@ -789,7 +789,7 @@ And five warning flags: single: safe haskell imports, warning The module ``A`` below is annotated to be explictly ``Safe``, but it imports - ``Safe-Inferred`` module. + ``Safe-Inferred`` module. :: {-# LANGUAGE Safe #-} module A where -- cgit v1.2.1