summaryrefslogtreecommitdiff
path: root/src/Soat/Data/Product.idr
diff options
context:
space:
mode:
authorGreg Brown <greg.brown01@ed.ac.uk>2022-11-25 15:15:40 +0000
committerGreg Brown <greg.brown01@ed.ac.uk>2022-11-25 15:15:40 +0000
commitdfed64700d3caae5749cc94cfcf8b97a4e27a435 (patch)
tree938f8a29eb0edf301328713e6be1ff31c7c04177 /src/Soat/Data/Product.idr
parentd7fa1ccbbb6dcf78d16b8adfeab4e1a167a2f0b3 (diff)
Generalise bindUnique.
Diffstat (limited to 'src/Soat/Data/Product.idr')
-rw-r--r--src/Soat/Data/Product.idr7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/Soat/Data/Product.idr b/src/Soat/Data/Product.idr
index cd69098..f92c23c 100644
--- a/src/Soat/Data/Product.idr
+++ b/src/Soat/Data/Product.idr
@@ -109,6 +109,13 @@ namespace Pointwise
pwRefl f {xs = []} = []
pwRefl f {xs = (x :: xs)} = reflexive :: pwRefl f
+
+ public export
+ pwReflexive : {0 x : a -> Type} -> {0 rel : (i : a) -> Rel (x i)}
+ -> ((i : a) -> Reflexive (x i) (rel i))
+ -> {is : List a} -> {xs, ys : x ^ is} -> xs = ys -> Pointwise rel xs ys
+ pwReflexive refl Refl = pwRefl refl
+
public export
pwSym : {0 x : a -> Type} -> {0 rel : (i : a) -> Rel (x i)}
-> ((i : a) -> Symmetric (x i) (rel i))