Open
Conversation
…/Documentation into shelly/gapsfromvoodoodoc
Contributor
|
Going over the stale open doc PRs. @shellygr is this still relevant? If so, I'll review it |
Contributor
Author
|
Should be still true |
urikirsh
reviewed
Sep 4, 2024
Contributor
urikirsh
left a comment
There was a problem hiding this comment.
Small fixes and a question
| put into an array in storage. | ||
| This is done by the compiler using a 'copy-loop'. | ||
| The selector component `this.testPush.selector` requires one iteration. | ||
| the string `aa` requires three iterations: according to the [ABI specification](https://docs.soliditylang.org/en/v0.8.24/abi-spec.html), |
Contributor
There was a problem hiding this comment.
Suggested change
| the string `aa` requires three iterations: according to the [ABI specification](https://docs.soliditylang.org/en/v0.8.24/abi-spec.html), | |
| The string `aa` requires three iterations: according to the [ABI specification](https://docs.soliditylang.org/en/v0.8.24/abi-spec.html), |
|
|
||
| Yes - when we copy `data` from memory to storage, the Solidity compiler | ||
| also generates code that nullifies the previous data. | ||
| As we do not know (and probably not wishing to constrain) the size of the previous data, |
Contributor
There was a problem hiding this comment.
Suggested change
| As we do not know (and probably not wishing to constrain) the size of the previous data, | |
| As we do not know (and probably do not wish to constrain) the size of the previous data, |
| } | ||
| ``` | ||
|
|
||
| The only difference in this new functionality is that we assume that the previous data has size of 225 bytes. |
Contributor
There was a problem hiding this comment.
Suggested change
| The only difference in this new functionality is that we assume that the previous data has size of 225 bytes. | |
| The only difference in this new functionality is that we assume that the previous data has a size of 225 bytes. |
| The push to `myArray` generates the two aforementioned loops. | ||
| If we wish to analyze this code with the Prover, there are two questions to be answered: | ||
|
|
||
| 1. Do we need to set a value for `--loop_iter` which is bigger than 1? |
Contributor
There was a problem hiding this comment.
Isn't the prover smart enough to unroll the loop enough times for this case? The string is static
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.