From 91a6a9cb94172a4c2235e6b2f9001df982bed4cc Mon Sep 17 00:00:00 2001 From: Ben Gamari Date: Fri, 4 Mar 2016 22:48:50 +0100 Subject: Add Monoid instance for FastString --- compiler/utils/FastString.hs | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'compiler/utils/FastString.hs') diff --git a/compiler/utils/FastString.hs b/compiler/utils/FastString.hs index ea95d84763..27bb510299 100644 --- a/compiler/utils/FastString.hs +++ b/compiler/utils/FastString.hs @@ -192,6 +192,10 @@ instance Ord FastString where | otherwise = y compare a b = cmpFS a b +instance Monoid FastString where + mempty = nilFS + mappend = appendFS + instance Show FastString where show fs = show (unpackFS fs) -- cgit v1.2.1