aboutsummaryrefslogtreecommitdiffstats
path: root/app/Text/Diff
diff options
context:
space:
mode:
authorLibravatar Alexander Foremny <aforemny@posteo.de>2023-12-07 03:55:45 +0100
committerLibravatar Alexander Foremny <aforemny@posteo.de>2023-12-07 03:55:47 +0100
commit3c6e62b75293b6625509ade3c278fc2d4d147c30 (patch)
treeb33f76c2634a771879f9178cff8e5335e43d2f43 /app/Text/Diff
parenta5dde0c6e1c1f54a1660f6c2345277927beef30f (diff)
chore: increase performance by caching everything
Initial cache generation is slower, as we are losing out on parallelism.
Diffstat (limited to 'app/Text/Diff')
-rw-r--r--app/Text/Diff/Extra.hs30
1 files changed, 30 insertions, 0 deletions
diff --git a/app/Text/Diff/Extra.hs b/app/Text/Diff/Extra.hs
new file mode 100644
index 0000000..f558495
--- /dev/null
+++ b/app/Text/Diff/Extra.hs
@@ -0,0 +1,30 @@
+{-# LANGUAGE TemplateHaskell #-}
+{-# OPTIONS_GHC -fno-warn-orphans #-}
+
+module Text.Diff.Extra where
+
+import Data.Binary (Binary)
+import Generics.Deriving.TH (deriveAll0)
+import Text.Diff.Parse.Types
+
+deriveAll0 ''FileDelta
+deriveAll0 ''FileStatus
+deriveAll0 ''Content
+deriveAll0 ''Hunk
+deriveAll0 ''Range
+deriveAll0 ''Line
+deriveAll0 ''Annotation
+
+instance Binary FileDelta
+
+instance Binary FileStatus
+
+instance Binary Content
+
+instance Binary Hunk
+
+instance Binary Range
+
+instance Binary Line
+
+instance Binary Annotation