mirror of
https://github.com/RGBCube/serenity
synced 2025-07-27 01:07:36 +00:00
LibCrypto: Add {Signed,Unsigned}BigInteger::from_base{2, 8, 16} helpers
These can be used to create BigInteger instances from non-decimal number strings.
This commit is contained in:
parent
e4e6e03364
commit
2ad2e055e2
4 changed files with 69 additions and 2 deletions
|
@ -53,8 +53,11 @@ public:
|
|||
|
||||
size_t export_data(Bytes, bool remove_leading_zeros = false) const;
|
||||
|
||||
static UnsignedBigInteger from_base2(const String& str);
|
||||
static UnsignedBigInteger from_base8(const String& str);
|
||||
static UnsignedBigInteger from_base10(const String& str);
|
||||
String to_base10() const;
|
||||
static UnsignedBigInteger from_base16(const String& str);
|
||||
|
||||
u64 to_u64() const;
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue