Verified Commit 4527cced authored by Camil Staps's avatar Camil Staps 🚀

Fix properties in Data.SetBy

parent e2336345
Pipeline #42479 passed with stage
in 2 minutes and 9 seconds
...@@ -23,6 +23,14 @@ definition module Data.SetBy ...@@ -23,6 +23,14 @@ definition module Data.SetBy
* - if a < b then not (b < a) * - if a < b then not (b < a)
* - if not (a < b) and not (b < a) then a and b are considered to 'equal' * - if not (a < b) and not (b < a) then a and b are considered to 'equal'
* *
* @property-bootstrap
* import StdChar, StdInt
* from StdList import instance length []
*
* @property-test-with a = Char
*
* @property-test-generator [a] -> SetBy a | < a
* gen xs = fromListBy (<) xs
*/ */
from StdOverloaded import class ==, class < (..) from StdOverloaded import class ==, class < (..)
...@@ -78,7 +86,7 @@ instance Foldable SetBy ...@@ -78,7 +86,7 @@ instance Foldable SetBy
* @property equivalence with size 0: A.s :: SetBy a: * @property equivalence with size 0: A.s :: SetBy a:
* size s == 0 <==> null s * size s == 0 <==> null s
* @property equivalence with newSet: A.s :: SetBy a: * @property equivalence with newSet: A.s :: SetBy a:
* s == newSet <==> null s * isEqualBy (<) s newSet <==> null s
*/ */
null s :== case s of null s :== case s of
TipBy -> True TipBy -> True
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment