FreeBSD.software
Home/devel/rubygem-equatable

rubygem-equatable

0.7.0

Implement equality comparison and inspection methods

Equatable 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. Howerver, 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.

Origin: devel/rubygem-equatable
Category: devel
Size: 12.8KiB
License: MIT
Maintainer: sunpoet@FreeBSD.org
Dependencies: 2 packages
Required by: 1 packages
$pkg install rubygem-equatable

Dependencies (2)

Required By (1 packages)

More in devel