summaryrefslogtreecommitdiff
path: root/docs/users_guide/8.8.1-notes.rst
blob: da236f923d34220e4da8c400cc68b9c3adac0c4d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
.. _release-8-8-1:

Release notes for version 8.8.1
===============================

The significant changes to the various parts of the compiler are listed in the
following sections. There have also been numerous bug fixes and performance
improvements over the 8.6.1 release.


Highlights
----------

The highlights, since the 8.6.1 release, are:

- Many, many bug fixes.


Full details
------------

Language
~~~~~~~~

- :extension:`ScopedTypeVariables`: The type variable that a type signature on
  a pattern can bring into scope can now stand for arbitrary types. Previously,
  they could only stand in for other type variables, but this restriction was deemed
  unnecessary in `GHC proposal #29 <https://github.com/ghc-proposals/ghc-proposals/blob/master/proposals/0029-scoped-type-variables-types.rst>`__. Also see :ghc-ticket:`15050`.

- The pattern-match coverage checker now checks for cases that are unreachable
  due to constructors have strict argument types. For instance, in the
  following example: ::

    data K = K1 | K2 !Void

    f :: K -> ()
    f K1 = ()

  ``K2`` cannot be matched on in ``f``, since it is impossible to construct a
  terminating value of type ``Void``. Accordingly, GHC will not warn about
  ``K2`` (whereas previous versions of GHC would).

Compiler
~~~~~~~~

- New :ghc-flag:`-keep-hscpp-files` to keep the output of the CPP pre-processor.

Runtime system
~~~~~~~~~~~~~~


Template Haskell
~~~~~~~~~~~~~~~~

- Reifying type classes no longer shows redundant class type variables and
  contexts in the type signature of each class method. For instance,
  reifying the following class: ::

    class C a where
      method :: a

  Used to produce the following: ::

    class C a where
      method :: forall a. C a => a

  Where the ``forall a. C a =>`` part is entirely redundant. This part is no
  longer included when reifying ``C``. It's possible that this may break some
  code which assumes the existence of ``forall a. C a =>``.

``ghc-prim`` library
~~~~~~~~~~~~~~~~~~~~

- GHC now exposes a new primop, ``traceBinaryEvent#``. This primop writes
  eventlog events similar to ``traceBinaryEvent#`` but allows the user to pass
  the event payload as a binary blob instead of a ``String``.

``ghc`` library
~~~~~~~~~~~~~~~


``base`` library
~~~~~~~~~~~~~~~~

- Support the characters from recent versions of Unicode (up to v. 12) in literals
    (see :ghc-ticket:`5518`).

Build system
~~~~~~~~~~~~


Included libraries
------------------

The package database provided with this distribution also contains a number of
packages other than GHC itself. See the changelogs provided with these packages
for further change information.

.. ghc-package-list::

    libraries/array/array.cabal:             Dependency of ``ghc`` library
    libraries/base/base.cabal:               Core library
    libraries/binary/binary.cabal:           Dependency of ``ghc`` library
    libraries/bytestring/bytestring.cabal:   Deppendency of ``ghc`` library
    libraries/Cabal/Cabal/Cabal.cabal:       Dependency of ``ghc-pkg`` utility
    libraries/containers/containers.cabal:   Dependency of ``ghc`` library
    libraries/deepseq/deepseq.cabal:         Dependency of ``ghc`` library
    libraries/directory/directory.cabal:     Dependency of ``ghc`` library
    libraries/filepath/filepath.cabal:       Dependency of ``ghc`` library
    compiler/ghc.cabal:                      The compiler itself
    libraries/ghci/ghci.cabal:               The REPL interface
    libraries/ghc-boot/ghc-boot.cabal:       Internal compiler library
    libraries/ghc-boot-th/ghc-boot-th.cabal: Internal compiler library
    libraries/ghc-compact/ghc-compact.cabal: Core library
    libraries/ghc-heap/ghc-heap.cabal:       GHC heap-walking library
    libraries/ghc-prim/ghc-prim.cabal:       Core library
    libraries/haskeline/haskeline.cabal:     Dependency of ``ghci`` executable
    libraries/hpc/hpc.cabal:                 Dependency of ``hpc`` executable
    libraries/integer-gmp/integer-gmp.cabal: Core library
    libraries/mtl/mtl.cabal:                 Dependency of ``Cabal`` library
    libraries/parsec/parsec.cabal:           Dependency of ``Cabal`` library
    libraries/process/process.cabal:         Dependency of ``ghc`` library
    libraries/stm/stm.cabal:                 Dependency of ``haskeline`` library
    libraries/template-haskell/template-haskell.cabal:     Core library
    libraries/terminfo/terminfo.cabal:       Dependency of ``haskeline`` library
    libraries/text/text.cabal:               Dependency of ``Cabal`` library
    libraries/time/time.cabal:               Dependency of ``ghc`` library
    libraries/transformers/transformers.cabal: Dependency of ``ghc`` library
    libraries/unix/unix.cabal:               Dependency of ``ghc`` library
    libraries/Win32/Win32.cabal:             Dependency of ``ghc`` library
    libraries/xhtml/xhtml.cabal:             Dependency of ``haddock`` executable