Path to this page:
./
devel/ruby-equatable,
Extends equality comparison and inspection methods
Branch: pkgsrc-2021Q3,
Version: 0.7.0,
Package name: ruby27-equatable-0.7.0,
Maintainer: pkgsrc-usersEquatable
Allows ruby objects to implement equality comparison and inspection methods.
By including this module, a class indicates that its instances have explicit
general contracts for `hash`, `==` and `eql?` methods. Specifically `eql?`
contract requires that it implements an equivalence relation. By default
each instance of the class is equal only to itself. This is a right
behaviour when you have distinct objects. However, it is the responsibility
of any class to clearly define their equality. Failure to do so may prevent
instances to behave as expected when for instance `Array#uniq` is invoked or
when they are used as `Hash` keys.
Master sites:
SHA1: bcfd52de09c792b092c2f0546b220878b13580e9
RMD160: ab78b44eddb7adbd58da5acdeed8176c800ff613
Filesize: 8 KB
Version history: (Expand)
- (2021-09-28) Package added to pkgsrc.se, version ruby27-equatable-0.7.0 (created)