Conversation
added 10 commits
July 3, 2024 23:24
sjoshisupra
requested changes
Aug 9, 2024
Comment on lines
+97
to
+111
| spec initialize_delegation_pool { | ||
| pragma verify = true; | ||
| include stake::ResourceRequirement; | ||
| /// [high-level-req-1] | ||
| let owner_address = signer::address_of(owner); | ||
| let seed = spec_create_resource_account_seed(delegation_pool_creation_seed); | ||
| let resource_address = account::spec_create_resource_address(owner_address, seed); | ||
| ensures exists<DelegationPoolOwnership>(TRACE(owner_address)); | ||
| // ensures exists<DelegationPool>(resource_address); | ||
| // ensures exists<stake::StakePool>(TRACE(resource_address)); | ||
| /// [high-level-req-2] | ||
| let signer_address = global<DelegationPool>(resource_address).stake_pool_signer_cap.account; | ||
| let pool_address_in_owner = global<DelegationPoolOwnership>(TRACE(owner_address)).pool_address; | ||
| // ensures TRACE(signer_address) == TRACE(pool_address_in_owner); | ||
| } |
There was a problem hiding this comment.
It seems there's no property in this block, all properties are commented out.
Comment on lines
+186
to
+188
| spec coins_to_transfer_to_ensure_min_stake { | ||
|
|
||
| } |
There was a problem hiding this comment.
Do these empty block serve any purpose? If no, then delete.
Comment on lines
+190
to
+192
| spec update_governanace_records_for_redeem_pending_inactive_shares { | ||
|
|
||
| } |
Comment on lines
+194
to
+199
| spec buy_in_active_shares { | ||
| pragma verify = true; | ||
| let new_shares = pool_u64::amount_to_shares(pool.active_shares, coins_amount); | ||
|
|
||
| ensures new_shares == 0 ==> result == 0; | ||
| } |
There was a problem hiding this comment.
this is trivial property, perhaps we want to assert that appropriate amount of shares are actually given in active_shares pool at the end of the buy_in.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.