Added a tostring function for bigints

pull/16/head
Ishaan Bhardwaj 2021-02-08 10:34:47 -05:00 committed by GitHub
parent 035f6dd7b4
commit 38947e00c0
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 3 additions and 0 deletions

View File

@ -63,6 +63,9 @@ function bigint.new(num)
end,
__le = function(lhs, rhs)
return bigint.compare(lhs, rhs, "<=")
end,
__tostring = function()
return bigint.unserialize(self, "s")
end
})