diff options
Diffstat (limited to 'libgo/runtime/go-rec-small.c')
-rw-r--r-- | libgo/runtime/go-rec-small.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/libgo/runtime/go-rec-small.c b/libgo/runtime/go-rec-small.c index 019b20a..946a18c 100644 --- a/libgo/runtime/go-rec-small.c +++ b/libgo/runtime/go-rec-small.c @@ -266,12 +266,14 @@ uint64_t __go_receive_small_closed (struct __go_channel *channel, _Bool for_select, _Bool *received) { + uintptr_t element_size; uint64_t ret; if (channel == NULL) __go_panic_msg ("receive from nil channel"); - __go_assert (channel->element_size <= sizeof (uint64_t)); + element_size = channel->element_type->__size; + __go_assert (element_size <= sizeof (uint64_t)); if (!__go_receive_acquire (channel, for_select)) { |