From 6108685424c6731f39f66636967257b58cc3c99a Mon Sep 17 00:00:00 2001 From: Jordan Martinez Date: Tue, 15 Feb 2022 15:41:29 -0600 Subject: [PATCH 1/2] Change NoConstructors to newtype Void --- src/Data/Generic/Rep.purs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/Data/Generic/Rep.purs b/src/Data/Generic/Rep.purs index 0d6a9f06..c3de434a 100644 --- a/src/Data/Generic/Rep.purs +++ b/src/Data/Generic/Rep.purs @@ -14,10 +14,11 @@ module Data.Generic.Rep import Data.Semigroup ((<>)) import Data.Show (class Show, show) import Data.Symbol (class IsSymbol, reflectSymbol) +import Data.Void (Void) import Type.Proxy (Proxy(..)) -- | A representation for types with no constructors. -data NoConstructors +newtype NoConstructors = NoConstructors Void -- | A representation for constructors with no arguments. data NoArguments = NoArguments From 2477c9e50c5535b06affc317f89556d2a01dec12 Mon Sep 17 00:00:00 2001 From: Jordan Martinez Date: Fri, 11 Mar 2022 12:03:11 -0800 Subject: [PATCH 2/2] Add changelog entry --- CHANGELOG.md | 1 + 1 file changed, 1 insertion(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 42e937eb..13d62ca2 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -6,6 +6,7 @@ Notable changes to this project are documented in this file. The format is based Breaking changes: - Migrated FFI to ES Modules (#287 by @kl0tl and @JordanMartinez) +- Change Generic Rep's `NoConstructors` to newtype `Void` (#282 by @JordanMartinez) New features: