Robbepop / apint

Arbitrary precision integers library.
Other
26 stars 4 forks source link

Implement Bin, Oct, LowerHex and UpperHex for ApInt #12

Open Robbepop opened 6 years ago

Robbepop commented 6 years ago

Currently ApInt only provides printing via the fmt::Debug trait implementation which offers internal debug information about each instance but is not suitable for simple printing of values.

Due to the data structures used for ApInt the following display-traits are simple to implement and offer a decent initial starting ground:

Later an implementation of Display for (decimal representation) may be useful but this still requires robust implementation of the arithmetic module.

Robbepop commented 6 years ago

Initial implementation of Binary, LowerHex and UpperHex in https://github.com/Robbepop/apint/commit/edf46b111c410b1643000ba162bddf95e43c707c and forwarding impls for Int and UInt in https://github.com/Robbepop/apint/commit/af6d35bf2f0dd0952e24af60817d4f0ee1e9399c.

Now only the implementation for Octal is missing.