summaryrefslogtreecommitdiff
path: root/src/Prolog.hs
diff options
context:
space:
mode:
authorChris Wells <chris@mathematicaster.org>2026-01-20 17:00:40 -0600
committerChris Wells <chris@mathematicaster.org>2026-01-20 17:00:40 -0600
commit5d83e36ef8210d1514259c89ff97a25c4d19600c (patch)
treebb15b5d2f15e671b6963b1088a501e0dee758f2e /src/Prolog.hs
parent8424579b0c79038510c3e763b1154cb6aea5cdfe (diff)
downloadmain-5d83e36ef8210d1514259c89ff97a25c4d19600c.tar
main-5d83e36ef8210d1514259c89ff97a25c4d19600c.tar.gz
main-5d83e36ef8210d1514259c89ff97a25c4d19600c.tar.bz2
main-5d83e36ef8210d1514259c89ff97a25c4d19600c.tar.lz
main-5d83e36ef8210d1514259c89ff97a25c4d19600c.tar.xz
main-5d83e36ef8210d1514259c89ff97a25c4d19600c.tar.zst
main-5d83e36ef8210d1514259c89ff97a25c4d19600c.zip
Technically working, but I need a cleaner way to pass personA and
journalA into a list context...
Diffstat (limited to 'src/Prolog.hs')
-rw-r--r--src/Prolog.hs8
1 files changed, 7 insertions, 1 deletions
diff --git a/src/Prolog.hs b/src/Prolog.hs
index 94a6eb6..f7e72eb 100644
--- a/src/Prolog.hs
+++ b/src/Prolog.hs
@@ -23,6 +23,7 @@ module Prolog
, Binary
, Generic
, Generic1
+ , Typeable
, Generically (..)
, MonadThrow (..)
, Exception (..)
@@ -89,6 +90,8 @@ import Data.String
import Data.String.Conv
import Data.Text qualified as T
import Data.Text.Lazy qualified as TL
+import Data.Time qualified as Time
+import Data.Typeable (Typeable)
import GHC.Generics
import Network.URI
@@ -186,7 +189,7 @@ rebaseWith :: (Applicative m, Comonad w) => (a -> b) -> w a -> m b
rebaseWith f = rebaseWithM $ pure . f
{-# INLINE rebaseWith #-}
-rebaseWithM :: (Applicative m, Comonad w) => (a -> m b) -> w a -> m b
+rebaseWithM :: (Comonad w) => (a -> m b) -> w a -> m b
rebaseWithM f = f . extract
{-# INLINE rebaseWithM #-}
@@ -311,3 +314,6 @@ instance MonadThrow H.Compiler where
-- | Huh, I guess I need a version bump for this guy?
instance A.FromJSON URI where
parseJSON = A.withText "URI" $ maybe (fail "Invalid URI") pure . parseURI . toSL
+
+deriving instance Generic Time.Day
+deriving newtype instance Binary Time.Day