Remove use of undefined in Read instance
This commit is contained in:
parent
bbd6779cc5
commit
1996ec05f7
1 changed files with 1 additions and 6 deletions
|
@ -54,6 +54,7 @@ instance (KnownSymbol format, T.FormatTime t) => Show (FTime format t) where
|
|||
instance (KnownSymbol format, T.ParseTime t) => Read (FTime format t) where
|
||||
readsPrec i str = res
|
||||
where
|
||||
fmt = symbolVal (Proxy :: Proxy format)
|
||||
res = fmap (first FTime)
|
||||
(readParen (i > 1)
|
||||
#if !MIN_VERSION_time(1,5,0)
|
||||
|
@ -64,12 +65,6 @@ instance (KnownSymbol format, T.ParseTime t) => Read (FTime format t) where
|
|||
str
|
||||
)
|
||||
|
||||
toFTimeTy :: [(FTime format t, String)] -> FTime format t
|
||||
toFTimeTy _ = undefined
|
||||
|
||||
fmt = getFormat (toFTimeTy res)
|
||||
|
||||
|
||||
|
||||
instance (KnownSymbol format, T.FormatTime t) => ToHttpApiData (FTime format t) where
|
||||
toUrlPiece = toUrlPiece . renderTime
|
||||
|
|
Loading…
Add table
Reference in a new issue