-
Notifications
You must be signed in to change notification settings - Fork 41
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[6.0] UnsignedBigInt implementation #997
Conversation
@kushti the target branch seems to be not correct. I wonder if the changeset is so big because of that? |
weird it no retargeted automatically after merged, fixed manually |
@@ -55,6 +55,7 @@ trait ContractSyntax { contract: SigmaContract => | |||
case _: String => StringType | |||
case _: Unit => UnitType | |||
case _: sigma.BigInt => BigIntRType | |||
case _: sigma.BigInt => UnsignedBigIntRType |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this case is unreachable
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
fixed
(newName, Select(obj, newName, resType)) | ||
} else { | ||
(nOriginal, selOriginal) | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hm, why not just use different method names? This will be the only place with such exception, so will lead to more questions than answers.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The idea is to provide unified interface to users (ErgoScript) developers, so kinda polymorphic exp method (which is then translated by typer into exp or expUnsigned, depends on argument)
sc/shared/src/test/scala/sigmastate/ErgoTreeSpecification.scala
Outdated
Show resolved
Hide resolved
sdk/shared/src/main/scala/org/ergoplatform/sdk/JavaHelpers.scala
Outdated
Show resolved
Hide resolved
Co-authored-by: Alexander Slesarenko <aslesarenko@users.noreply.github.com>
Co-authored-by: Alexander Slesarenko <aslesarenko@users.noreply.github.com>
Co-authored-by: Alexander Slesarenko <aslesarenko@users.noreply.github.com>
@aslesarenko comments addressed, please make another pass! |
This PR contains implementation of new numeric type, UnsignedBigInt, 256 bits unsigned big integers.