-
Notifications
You must be signed in to change notification settings - Fork 0
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
Read from init_data or contract state in scilla_read precompile #1475
Conversation
f7f25d6
to
e97fe35
Compare
e97fe35
to
f4aaca3
Compare
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.
Happy to approve but don't want to auto-merge until you've said your format change was intentional - sorry!
f4aaca3
to
955856e
Compare
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.
Looks good to me :-)
955856e
to
0c6d2b6
Compare
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.
Looks good to me :-)
0c6d2b6
to
20fca0d
Compare
20fca0d
to
3a89252
Compare
The scilla_read precompile now reads from either the contract state or the contract's init data when a value is queried. To achieve this, I have changed the type of a Scilla contract's `init_data` from `String` to `Vec<ParamValue>`. The same data is stored, but we now parse the data on entry so that we can retrieve values easily later.
3a89252
to
4c36826
Compare
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.
Looks good to me :-)
The scilla_read precompile now reads from either the contract state or the contract's init data when a value is queried.
To achieve this, I have changed the type of a Scilla contract's
init_data
fromString
toVec<ParamValue>
. The same data is stored, but we now parse the data on entry so that we can retrieve values easily later.Also this fixes #1380