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

Always copy the original slice to the copy before handling the elements #11

Merged
merged 1 commit into from
Apr 16, 2021

Conversation

urandom
Copy link
Collaborator

@urandom urandom commented Apr 15, 2021

Walking the slice elements will only produce code that handles non-value
elements. In case the elements contain a mix of pointers and values, not
copying the original items to the sink will result in only pointers
being present in the copy

Fixes #10

Walking the slice elements will only produce code that handles non-value
elements. In case the elements contain a mix of pointers and values, not
copying the original items to the sink will result in only pointers
being present in the copy

Fixes #10
@codecov
Copy link

codecov bot commented Apr 15, 2021

Codecov Report

Merging #11 (a8af544) into master (dfdeb68) will increase coverage by 1.36%.
The diff coverage is 100.00%.

❗ Current head a8af544 differs from pull request most recent head 225a4c1. Consider uploading reports for the commit 225a4c1 to get more accurate results
Impacted file tree graph

@@            Coverage Diff             @@
##           master      #11      +/-   ##
==========================================
+ Coverage   65.92%   67.28%   +1.36%     
==========================================
  Files           1        1              
  Lines         270      269       -1     
==========================================
+ Hits          178      181       +3     
+ Misses         74       71       -3     
+ Partials       18       17       -1     
Impacted Files Coverage Δ
main.go 67.28% <100.00%> (+1.36%) ⬆️

@urandom urandom merged commit ae0d49c into master Apr 16, 2021
@urandom urandom deleted the slice-with-pointer-and-value branch April 16, 2021 08:30
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.

Bug: struct properties not cloned with slice of value semantics
1 participant