Skip to content
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

fix off-by-one in dynamic array length calculation #2821

Merged

Conversation

charles-cooper
Copy link
Member

What I did

fix #2820

How I did it

How to verify it

Commit message

Commit message for the final, squashed PR. (Optional, but reviewers will appreciate it! Please see our commit message style guide for what we would ideally like to see in a commit message.)

Description for the changelog

Cute Animal Picture

Put a link to a cute animal picture inside the parenthesis-->

this only affects storage allocation.
@codecov-commenter
Copy link

codecov-commenter commented Apr 21, 2022

Codecov Report

Merging #2821 (5f30d0c) into master (c270363) will increase coverage by 0.05%.
The diff coverage is 100.00%.

@@            Coverage Diff             @@
##           master    #2821      +/-   ##
==========================================
+ Coverage   87.47%   87.52%   +0.05%     
==========================================
  Files          94       94              
  Lines       10003    10007       +4     
  Branches     2480     2480              
==========================================
+ Hits         8750     8759       +9     
+ Misses        785      782       -3     
+ Partials      468      466       -2     
Impacted Files Coverage Δ
vyper/semantics/types/indexable/sequence.py 88.18% <100.00%> (ø)
vyper/semantics/types/bases.py 84.53% <0.00%> (+0.51%) ⬆️
vyper/semantics/types/function.py 87.10% <0.00%> (+0.99%) ⬆️
vyper/ast/validation.py 77.77% <0.00%> (+4.44%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update c270363...5f30d0c. Read the comment docs.

Copy link
Member

@fubuloubu fubuloubu left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Needs tests

vyper/semantics/types/indexable/sequence.py Show resolved Hide resolved
@charles-cooper charles-cooper marked this pull request as ready for review April 21, 2022 16:38
@charles-cooper charles-cooper merged commit e991b1f into vyperlang:master Apr 21, 2022
@charles-cooper charles-cooper deleted the fix_dynarray_allocation branch April 21, 2022 17:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Dynamic arrays are not allocated properly in storage, overlap with following variables
3 participants