diff options
| author | Joey Hess <joeyh@joeyh.name> | 2018-04-30 09:03:46 -0400 |
|---|---|---|
| committer | Joey Hess <joeyh@joeyh.name> | 2018-04-30 09:03:46 -0400 |
| commit | 14fe4c4d6b5a29be94ecfc0572e0f9a9a081e795 (patch) | |
| tree | 38ad23b09bd21a8569568335a13bfde9c16e79c1 /src/Propellor/Property/Ssh.hs | |
| parent | 96ea8e04251bc23dd27faf1f486a2a9f9c29ff98 (diff) | |
fix broken SemigroupMonoid transition <<loop>>
Turns out that with ghc 8.2.2, the instructions given on the page don't
work. And the cppless variant that I had compiles, but into effectively
mappend = mappend so it loops.
The only way I can see to make it work without cpp is to use
mappend = (Sem.<>)
which is ugly and a land mine waiting to explode if someone changes it
to a nicer mappend = (<>) with a newer version of ghc which will compile
it and work ok, while breaking it with 8.2.2. Sigh.
I posted to haskell-cafe about this.
Diffstat (limited to 'src/Propellor/Property/Ssh.hs')
| -rw-r--r-- | src/Propellor/Property/Ssh.hs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/Propellor/Property/Ssh.hs b/src/Propellor/Property/Ssh.hs index 05098983..c23a121b 100644 --- a/src/Propellor/Property/Ssh.hs +++ b/src/Propellor/Property/Ssh.hs @@ -238,7 +238,7 @@ instance Sem.Semigroup HostKeyInfo where instance Monoid HostKeyInfo where mempty = HostKeyInfo M.empty - mappend = (<>) + mappend = (Sem.<>) userPubKeys :: User -> [(SshKeyType, PubKeyText)] -> Property (HasInfo + UnixLike) userPubKeys u@(User n) l = pureInfoProperty ("ssh pubkey for " ++ n) $ @@ -260,7 +260,7 @@ instance Sem.Semigroup UserKeyInfo where instance Monoid UserKeyInfo where mempty = UserKeyInfo M.empty - mappend = (<>) + mappend = (Sem.<>) -- | Sets up a user with the specified public keys, and the corresponding -- private keys from the privdata. |
