Skip to content

Commit

Permalink
Use Data.String.fromString to avoid compilation errors with the lates…
Browse files Browse the repository at this point in the history
…t version of text-display
  • Loading branch information
mmhat committed Jan 6, 2025
1 parent 3d533af commit 8ee38e4
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/GetTested/Types.hs
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,10 @@
module GetTested.Types where

import Data.Aeson
import Data.String (fromString)
import Data.Text (Text)
import Data.Text qualified as Text
import Data.Text.Display
import Data.Text.Lazy.Builder qualified as Builder
import Data.Vector (Vector)
import Data.Vector qualified as Vector
import Data.Vector.NonEmpty (NonEmptyVector)
Expand Down Expand Up @@ -47,10 +47,10 @@ instance FromJSON CompilerFlavor where
maybe (fail "Invalid compiler flavor") pure (simpleParsec $ Text.unpack s)

instance Display CompilerFlavor where
displayBuilder = Builder.fromString . Pretty.prettyShow
displayBuilder = fromString . Pretty.prettyShow

instance Display VersionRange where
displayBuilder = Builder.fromString . Pretty.prettyShow
displayBuilder = fromString . Pretty.prettyShow

instance ToJSON Version where
toJSON = toJSON . Pretty.prettyShow
Expand Down

0 comments on commit 8ee38e4

Please sign in to comment.