From ace352cc0aa732d00900122e0ab8552c870f3901 Mon Sep 17 00:00:00 2001 From: Joey Hess Date: Mon, 19 Oct 2015 12:33:18 -0400 Subject: improve Info type using GADT, at nomeata's suggestion This makes Show Info work, and simplifies the implementation. --- src/Propellor/Property/Spin.hs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/Propellor/Property/Spin.hs') diff --git a/src/Propellor/Property/Spin.hs b/src/Propellor/Property/Spin.hs index ead85f59..5f857ef4 100644 --- a/src/Propellor/Property/Spin.hs +++ b/src/Propellor/Property/Spin.hs @@ -125,7 +125,7 @@ cdesc n = "controller for " ++ n -- To detect loops of controlled hosts, each Host's info contains a list -- of the hosts it's controlling. newtype Controlling = Controlled [Host] - deriving (Typeable, Monoid) + deriving (Typeable, Monoid, Show) isControlledBy :: Host -> Controlling -> Bool h `isControlledBy` (Controlled hs) = any (== hostName h) (map hostName hs) -- cgit v1.2.3