From 2506453874aa30968d8533a603d295ac248273c5 Mon Sep 17 00:00:00 2001 From: Joey Hess Date: Fri, 25 Mar 2016 02:00:23 -0400 Subject: add type alias for Sing to be less confusing for users --- src/Propellor/Types/MetaTypes.hs | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) (limited to 'src/Propellor/Types') diff --git a/src/Propellor/Types/MetaTypes.hs b/src/Propellor/Types/MetaTypes.hs index 6edea291..7dafe422 100644 --- a/src/Propellor/Types/MetaTypes.hs +++ b/src/Propellor/Types/MetaTypes.hs @@ -10,7 +10,7 @@ module Propellor.Types.MetaTypes ( FreeBSD, HasInfo, type (+), - Sing, + MetaTypes, sing, SingI, IncludesInfo, @@ -36,15 +36,17 @@ data OS deriving (Show, Eq) -- | Any unix-like system -type UnixLike = Sing '[ 'Targeting 'OSDebian, 'Targeting 'OSBuntish, 'Targeting 'OSFreeBSD ] -type Debian = Sing '[ 'Targeting 'OSDebian ] +type UnixLike = MetaTypes '[ 'Targeting 'OSDebian, 'Targeting 'OSBuntish, 'Targeting 'OSFreeBSD ] +type Debian = MetaTypes '[ 'Targeting 'OSDebian ] +type Buntish = MetaTypes '[ 'Targeting 'OSBuntish ] +type FreeBSD = MetaTypes '[ 'Targeting 'OSFreeBSD ] -- | Debian and derivatives. -type DebianLike = Sing '[ 'Targeting 'OSDebian, 'Targeting 'OSBuntish ] -type Buntish = Sing '[ 'Targeting 'OSBuntish ] -type FreeBSD = Sing '[ 'Targeting 'OSFreeBSD ] +type DebianLike = Debian + Buntish -- | Used to indicate that a Property adds Info to the Host where it's used. -type HasInfo = Sing '[ 'WithInfo ] +type HasInfo = MetaTypes '[ 'WithInfo ] + +type MetaTypes = Sing -- | The data family of singleton types. data family Sing (x :: k) -- cgit v1.2.3