]> git.ipfire.org Git - thirdparty/gcc.git/commit
go: fix f().x where f returns zero-sized type
authorIan Lance Taylor <iant@golang.org>
Sat, 16 Jul 2022 23:29:38 +0000 (16:29 -0700)
committerIan Lance Taylor <iant@golang.org>
Sat, 16 Jul 2022 23:30:34 +0000 (16:30 -0700)
commit2b5baaef0b6e4d1d8e36cda091be26649163ffdb
treef5c46f9c6f20ff4d80922339633f10282beb53ec
parentd6d8e6a7e1379f9dfdf2f39efcc82d9185cca6d0
go: fix f().x where f returns zero-sized type

Test case is https://go.dev/cl/417874.

Fixes golang/go#23870

* go-gcc.cc (Gcc_backend::struct_field_expression): Handle a void
expression, as for f().x where f returns a zero-sized type.
gcc/go/go-gcc.cc