1# Revision history for th-abstraction
2
3## 0.3.2.0 -- 2020-02-06
4* Support substituting into and extracting free variables from `ForallVisT`s
5  on `template-haskell-2.16.0.0` (GHC 8.10) or later.
6* Fix a bug in which `freeVariables` could report duplicate kind variables when
7  they occur in the kinds of the type variable binders in a `ForallT`.
8* Fix a bug in which `resolveInfixT` would not resolve `UInfixT`s occurring in
9  the kinds of type variable binders in a `ForallT`.
10* Fix a bug in which the `TypeSubstitution ConstructorInfo` instance would not
11  detect free kind variables in the `constructorVars`.
12
13## 0.3.1.0 -- 2019-04-28
14* Fix a bug which would cause data family information to be reified incorrectly
15  with GHC 8.8+ in some situations.
16
17## 0.3.0.0 -- 2019-04-26
18* Breaking change: the `datatypeVars` field of `DatatypeInfo` is now of type
19  `[TyVarBndr]` instead of `[Type]`, as it now refers to all of the bound type
20  variables in the data type. The old `datatypeVars` field has been renamed to
21  `datatypeInstTypes` to better reflect its purpose.
22
23  In addition, the type of `normalizeCon` now has an additional `[TyVarBndr]`
24  argument, since `DatatypeInfo` now requires it.
25* Support `template-haskell-2.15`.
26* Fix a bug in which `normalizeDec` would not detect existential type variables
27  in a GADT constructor if they were implicitly quantified.
28* Fix a bug in which `normalizeDec` would report an incorrect number of
29  `datatypeVars` for GADT declarations with explicit return kinds (such as
30  `data Foo :: * -> * where`).
31
32## 0.2.11.0 -- 2019-02-26
33* Fix a bug in which `freeVariablesWellScoped` would sometimes not preserve
34  the left-to-right ordering of `Name`s generated with `newName`.
35
36## 0.2.10.0 -- 2018-12-20
37* Optimization: `quantifyType` now collapses consecutive `forall`s. For
38  instance, calling `quantifyType` on `forall b. a -> b -> T a` now produces
39  `forall a b. a -> b -> T a` instead of `forall a. forall b. a -> b -> T a`.
40
41## 0.2.9.0 -- 2018-12-20
42* Fix a bug in which `resolveTypeSynonyms` would not look into `ForallT`s,
43  `SigT`s, `InfixT`s, or `ParensT`s.
44* Fix a bug in which `quantifyType` would not respect the dependency order of
45  type variables (e.g., `Proxy (a :: k)` would have erroneously been quantified
46  as `forall a k. Proxy (a :: k)`).
47* Fix a bug in which `asEqualPred` would return incorrect results with GHC 8.7.
48* Add a `freeVariablesWellScoped` function which computes the free variables of
49  a list of types and sorts them according to dependency order.
50* Add a `resolveKindSynonyms` function which expands all type synonyms in a
51  `Kind`. This is mostly useful for supporting old GHCs where `Type` and `Kind`
52  were not the same.
53
54## 0.2.8.0 -- 2018-06-29
55* GADT reification is now much more robust with respect to `PolyKinds`:
56  * A bug in which universally quantified kind variables were mistakenly
57    flagged as existential has been fixed.
58  * A bug in which the kinds of existentially quantified type variables
59    were not substituted properly has been fixed.
60  * More kind equalities are detected than before. For example, in the
61    following data type:
62
63    ```haskell
64    data T (a :: k) where
65      MkT :: forall (a :: Bool). T a
66    ```
67
68    We now catch the `k ~ Bool` equality.
69* Tweak `resolveTypeSynonyms` so that failing to reify a type constructor
70  name so longer results in an error. Among other benefits, this makes
71  it possible to pass data types with GADT syntax to `normalizeDec`.
72
73## 0.2.7.0 -- 2018-06-17
74* Fix bug in which data family instances with duplicate occurrences of type
75  variables in the left-hand side would have redundant equality constraints
76  in their contexts.
77
78## 0.2.6.0 -- 2017-09-04
79* Fix bug in which `applySubstitution` and `freeVariables` would ignore
80  type variables in the kinds of type variable binders.
81
82## 0.2.5.0
83
84* Added `pragLineDCompat`, `newtypeDCompat` and `tySynInstDCompat`
85
86## 0.2.4.0 -- 2017-07-31
87
88* Fix bug that caused GADT equality constraints to be incorrect in some cases.
89* Expose `Unpackedness` and `Strictness` (which were unexported by accident).
90
91## 0.2.3.0 -- 2017-06-26
92
93* Add `resolvePredSynonyms`
94* Add `reifyConstructor`, which allows reification of `ConstructorInfo` from
95  a constructor name, and `lookupByConstructorName`, which allows directly
96  looking up a `ConstructorInfo` from a `DatatypeInfo` value for a given
97  constructor `Name`.
98* Augment `reifyDatatype` to be able to look up `DatatypeInfo` from the `Name`
99  of a record selector for one of its constructors. Also add `reifyRecord` for
100  reification of of `ConstructorInfo` from a record name, and
101  `lookupByRecordName`, which allows directly looking up a `ConstructorInfo`
102  from a `DatatypeInfo` value for a given record `Name`.
103* Fix bug that caused `th-abstraction` to fail on GHC 7.0 and 7.2 when passing
104  a vanilla constructor name to `reifyDatatype`
105* Make `normalizeDec` and `normalizeCon` more robust with respect to
106  data family instances on GHC 7.6 and 7.8
107
108## 0.2.2.0 -- 2017-06-10
109
110* Fix `freeVariables` on lists not not produce duplicates.
111
112## 0.2.1.0 -- 2017-06-09
113
114* Add sensible reify defaults and error messages when we
115  can't backport fixes to old GHC Template Haskell output
116  due to hand-written Decs being processed.
117
118## 0.2.0.0 -- 2017-06-03
119
120* Added `reifyFixityCompat`
121* Added `constructorStrictness` field to `ConstructorInfo`
122* Infer more kind signatures when missing on old GHCs
123* Added parameter to `normalizeCon`
124* Support GHC back to 7.0.4
125
126## 0.1.3.0 -- 2017-05-27
127
128* Added `resolveInfixT` which uses reified fixity information to resolve `UInfixT`
129* Added `asEqualPred` and `asClassPred`
130* Fixed data-instance GADTs
131
132## 0.1.2.1  -- 2017-05-21
133
134* Add eta reduction fixes to GHC 7.6
135
136## 0.1.2.0  -- 2017-05-21
137
138* Added `arrowKCompat`
139* Added workaround for GHC 7.8 data instance eta reduction bug
140* Added kind signatures to datatypeVars
141
142## 0.1.1.0  -- 2017-05-20
143
144* Better matching of constraints generated for GADTs across GHC versions
145* Added `dataDCompat`
146* Support for giving value constructors to reifyDatatype. This enables
147  data families to be reified easily.
148
149## 0.1.0.0  -- 2017-04-26
150
151* First version.
152