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 #1641 #1642

Merged
merged 2 commits into from Apr 19, 2022
Merged

fix #1641 #1642

merged 2 commits into from Apr 19, 2022

Conversation

chavacava
Copy link
Contributor

@chavacava chavacava commented Apr 17, 2022

fix #1641 by using a pointer receiver

Copy link
Contributor

@klauspost klauspost left a comment

Choose a reason for hiding this comment

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

You need to change the return types:

Error: utils.go:513:9: cannot use (hashWrapper literal) (value of type hashWrapper) as md5simd.Hasher value in return statement: hashWrapper does not implement md5simd.Hasher (method Close has pointer receiver) (typecheck)
	return hashWrapper{Hash: md5Pool.Get().(hash.Hash), isMD5: true}
	       ^
Error: utils.go:517:9: cannot use (hashWrapper literal) (value of type hashWrapper) as md5simd.Hasher value in return statement: hashWrapper does not implement md5simd.Hasher (method Close has pointer receiver) (typecheck)
	return hashWrapper{Hash: sha256Pool.Get().(hash.Hash), isSHA256: true}
	       ^
Error: make: *** [Makefile:15: lint] Error 1

@harshavardhana harshavardhana merged commit 0836bb8 into minio:master Apr 19, 2022
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.

suspicious assignment to a by-value method receiver
3 participants