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

funcs/element: fix panic when used with negative index #62

Merged
merged 2 commits into from
Aug 26, 2020

Conversation

mildwonkey
Copy link
Contributor

This adds a check for a negative index to both Type Impl functions, and
some basic tests.

Downstream issue reference: hashicorp/terraform#25775

This adds a check for a negative index to both Type Impl functions, and
some basic tests.
@codecov
Copy link

codecov bot commented Aug 20, 2020

Codecov Report

Merging #62 into master will increase coverage by 0.19%.
The diff coverage is 66.66%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master      #62      +/-   ##
==========================================
+ Coverage   70.71%   70.90%   +0.19%     
==========================================
  Files          79       79              
  Lines        7178     7184       +6     
==========================================
+ Hits         5076     5094      +18     
+ Misses       1661     1645      -16     
- Partials      441      445       +4     
Impacted Files Coverage Δ
cty/function/stdlib/collection.go 22.46% <66.66%> (+2.66%) ⬆️

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 15177b9...53e2169. Read the comment docs.

@apparentlymart
Copy link
Collaborator

Nice! Thanks for fixing this.

@apparentlymart apparentlymart merged commit ffe1db7 into zclconf:master Aug 26, 2020
@mildwonkey mildwonkey deleted the mildwonkey/b-element-panic branch August 27, 2020 12:02
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.

None yet

2 participants