You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I like the idea of Discipline providing some default laws that can easily be shared and used. If @larsrh wants to go that direction I think these laws would be very helpful.
As a working example, discipline could provide an "AnyRefLaws" implementation that checks the behavior of the default
equals
andhashCode
methods.In particular, the implementation could work from:
makeClone
method that creates a deep copy of an instance,!=
with differing hashCode.See for example: https://github.com/denisrosset/alasc/blob/master/scalacheck-binding/src/main/scala/net.alasc/laws/AnyRefLaws.scala
I'd gladly provide a PR if there is interest.
The text was updated successfully, but these errors were encountered: