This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug go/68496] [libgo] reflect test fails on Linux x86-64
- From: "ian at gcc dot gnu.org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Mon, 23 Nov 2015 21:18:35 +0000
- Subject: [Bug go/68496] [libgo] reflect test fails on Linux x86-64
- Auto-submitted: auto-generated
- References: <bug-68496-4 at http dot gcc dot gnu dot org/bugzilla/>
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=68496
--- Comment #4 from ian at gcc dot gnu.org <ian at gcc dot gnu.org> ---
Author: ian
Date: Mon Nov 23 21:18:03 2015
New Revision: 230777
URL: https://gcc.gnu.org/viewcvs?rev=230777&root=gcc&view=rev
Log:
PR go/68496
reflect: Allocate space for FFI functions returning a zero-sized type.
The libffi library does not understand zero-sized types. We represent
them as a struct with a single field of type void. If such a type is
returned from a function, libffi will copy 1 byte of data. Allocate
space for that byte, although we won't use it.
Fixes https://gcc.gnu.org/PR68496.
Reviewed-on: https://go-review.googlesource.com/17175
Modified:
branches/gcc-5-branch/libgo/runtime/go-reflect-call.c