Skip to content
This repository was archived by the owner on May 14, 2024. It is now read-only.
This repository was archived by the owner on May 14, 2024. It is now read-only.

Add distinct Address type #39

Description

Currently the 20-byte Addresses are simply a typedef for uint256_t. This means we can easily reuse the parsing and serialisation code, but introduces type confusion and memory bloat (32 bytes for every 20-byte Address). In particular, we always want to export an Address as a fixed-size 20 byte hex value, ideally checksum-encoded, whereas uint256_ts are written with variable length (rather than padded with leading 0s). We can achieve this by explicitly calling the correct functions everywhere we do these conversions, but it would be neater if these were automatically handled by the type system.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    backlogWIBNIF, not on immediate roadmapenhancementNew feature or request

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions