A collection of Solidity libraries, with an initial focus on arrays.
Documentation is generated from Natspec.
npm install --save cryptofin-solidity
import "cryptofin-solidity/contracts/array-utils/AddressArrayUtils.sol";
contract Contract {
using AddressArrayUtils for address[];
function containsDeadBeef(address[] memory addresses)
returns (bool)
{
return addresses.contains(address(0xdeadbeef));
}
}
If you'd like to contribute, this library is in need of:
- More functionality
- More tests
- Other open feature requests
This library is still relatively new and may have breaking changes in the future.