]> Cypherpunks repositories - gostls13.git/commit
reflect: fix methodValueCall code pointer mismatched
authorCuong Manh Le <cuong.manhle.vn@gmail.com>
Tue, 19 Oct 2021 09:34:43 +0000 (16:34 +0700)
committerCuong Manh Le <cuong.manhle.vn@gmail.com>
Tue, 19 Oct 2021 16:19:27 +0000 (16:19 +0000)
commitf92a3589fa04285dccab3ca7454eaaf2d0e7cde3
treed939473c2be0eb22eb9324e4dffef2fbfb12dcb1
parentfe7df4c4d043fc65800bbec7f575c1ba50327aa9
reflect: fix methodValueCall code pointer mismatched

CL 322350 changed how to take address of assembly functions, using
abi.FuncPCABI0 intrinsic. But we forgot to update the code in
Value.UnsafePointer (was Value.Pointer) to reflect that change.

This CL fixes that bug, and also add a test to make sure the code
pointer is in sync.

Change-Id: I05ae7df31c706583a0f374d8af027066528f5ceb
Reviewed-on: https://go-review.googlesource.com/c/go/+/356809
Trust: Cuong Manh Le <cuong.manhle.vn@gmail.com>
Run-TryBot: Cuong Manh Le <cuong.manhle.vn@gmail.com>
TryBot-Result: Go Bot <gobot@golang.org>
Reviewed-by: Cherry Mui <cherryyz@google.com>
src/reflect/all_test.go
src/reflect/export_test.go
src/reflect/makefunc.go
src/reflect/value.go