-
Notifications
You must be signed in to change notification settings - Fork 18k
hash/maphash: hashing channels with purego impl. of maphash.Comparable panics #73657
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
Comments
Thanks for report. |
Make maphash properly hash channels as represented by pointer. Fixes golang#73657
Change https://go.dev/cl/671655 mentions this issue: |
@gopherbot please consider this for backport to 1.24. This issue causes when using pruego build tags, maphash.Comparable cannot handle channal type correctly. There is no solution. |
Backport issue(s) opened: #73669 (for 1.24). Remember to create the cherry-pick CL(s) as soon as the patch is submitted to master, according to https://go.dev/wiki/MinorReleases. |
Go version
go version go1.24.2 linux/amd64
Output of
go env
in your module/workspace:What did you do?
Minimal example to reproduce:
What did you see happen?
Run with
go run -tags purego main.go
causes panic:The problem is that purego implementation of maphash doesn't handle
reflect.Chan
kind of values: https://cs.opensource.google/go/go/+/refs/tags/go1.24.3:src/hash/maphash/maphash_purego.go;l=115-175I can submit pull request which will make it handle
reflect.Chan
as every other pointer types, hashingv.Pointer()
value.What did you expect to see?
No panic like with regular
go run main.go
command.The text was updated successfully, but these errors were encountered: