summaryrefslogtreecommitdiff
path: root/libgo/go/reflect/makefunc.go
diff options
context:
space:
mode:
authorian <ian@138bc75d-0d04-0410-961f-82ee72b054a4>2014-06-04 23:15:33 +0000
committerian <ian@138bc75d-0d04-0410-961f-82ee72b054a4>2014-06-04 23:15:33 +0000
commit5892f89fbf9417381ac68163890704fe9e7d11f7 (patch)
tree89766166feb4ceca2d983169c5360e3f6f521b12 /libgo/go/reflect/makefunc.go
parent40196b7832598b0a0298d7a8bc5b8a4c723c80aa (diff)
downloadgcc-5892f89fbf9417381ac68163890704fe9e7d11f7.tar.gz
libgo: Merge from revision 18783:00cce3a34d7e of master library.
This revision was committed January 7, 2014. The next revision deleted runtime/mfinal.c. That will be done in a subsequent merge. This merge changes type descriptors to add a zero field, pointing to a zero value for that type. This is implemented as a common variable. * go-gcc.cc (Gcc_backend::implicit_variable): Add is_common and alignment parameters. Permit init parameter to be NULL. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@211249 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'libgo/go/reflect/makefunc.go')
-rw-r--r--libgo/go/reflect/makefunc.go4
1 files changed, 2 insertions, 2 deletions
diff --git a/libgo/go/reflect/makefunc.go b/libgo/go/reflect/makefunc.go
index 935a3d3be02..03ddd49f008 100644
--- a/libgo/go/reflect/makefunc.go
+++ b/libgo/go/reflect/makefunc.go
@@ -87,7 +87,7 @@ func makeFuncStub()
// by code like Convert and Interface and Assign.
func makeMethodValue(op string, v Value) Value {
if v.flag&flagMethod == 0 {
- panic("reflect: internal error: invalid use of makePartialFunc")
+ panic("reflect: internal error: invalid use of makeMethodValue")
}
switch runtime.GOARCH {
@@ -99,7 +99,7 @@ func makeMethodValue(op string, v Value) Value {
// Ignoring the flagMethod bit, v describes the receiver, not the method type.
fl := v.flag & (flagRO | flagAddr | flagIndir)
fl |= flag(v.typ.Kind()) << flagKindShift
- rcvr := Value{v.typ, v.val, fl}
+ rcvr := Value{v.typ, v.ptr /* v.scalar, */, fl}
// v.Type returns the actual type of the method value.
ft := v.Type().(*rtype)