public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug go/61322] New: gccgo: spurious "incompatible type for field 2 in struct construction" error [GoSmith]
@ 2014-05-26 16:25 dvyukov at google dot com
  2014-12-10  1:41 ` [Bug go/61322] " cmang at google dot com
  2014-12-16 17:48 ` cmang at google dot com
  0 siblings, 2 replies; 3+ messages in thread
From: dvyukov at google dot com @ 2014-05-26 16:25 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=61322

            Bug ID: 61322
           Summary: gccgo: spurious "incompatible type for field 2 in
                    struct construction" error [GoSmith]
           Product: gcc
           Version: 4.10.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: go
          Assignee: ian at airs dot com
          Reporter: dvyukov at google dot com
                CC: cmang at google dot com

gcc version 4.10.0 20140516 (experimental) (GCC) 

The program is:

package main
func main() {
    x := [1]int16{0}
    y := make([][2]int, 1)
    var s *string
    _ = func() {
        (x)[y[(func() int)(nil)()][len(*s)]]++
    }
}

$ go build -compiler=gccgo src.go
src.go:6:6: error: incompatible type for field 2 in struct construction
  _ = func() {
      ^
src.go:6:6: error: too few expressions for struct
src.go:7:34: error: expected pointer
   (x)[y[(func() int)(nil)()][len(*s)]]++

gc compiles successfully.


^ permalink raw reply	[flat|nested] 3+ messages in thread

* [Bug go/61322] gccgo: spurious "incompatible type for field 2 in struct construction" error [GoSmith]
  2014-05-26 16:25 [Bug go/61322] New: gccgo: spurious "incompatible type for field 2 in struct construction" error [GoSmith] dvyukov at google dot com
@ 2014-12-10  1:41 ` cmang at google dot com
  2014-12-16 17:48 ` cmang at google dot com
  1 sibling, 0 replies; 3+ messages in thread
From: cmang at google dot com @ 2014-12-10  1:41 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=61322

--- Comment #1 from Chris Manghane <cmang at google dot com> ---
I'm unable to reproduce this on gcc version 5.0.0 20141210 (experimental)
(GCC).


^ permalink raw reply	[flat|nested] 3+ messages in thread

* [Bug go/61322] gccgo: spurious "incompatible type for field 2 in struct construction" error [GoSmith]
  2014-05-26 16:25 [Bug go/61322] New: gccgo: spurious "incompatible type for field 2 in struct construction" error [GoSmith] dvyukov at google dot com
  2014-12-10  1:41 ` [Bug go/61322] " cmang at google dot com
@ 2014-12-16 17:48 ` cmang at google dot com
  1 sibling, 0 replies; 3+ messages in thread
From: cmang at google dot com @ 2014-12-16 17:48 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=61322

Chris Manghane <cmang at google dot com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |RESOLVED
         Resolution|---                         |FIXED

--- Comment #2 from Chris Manghane <cmang at google dot com> ---
(In reply to Chris Manghane from comment #1)
> I'm unable to reproduce this on gcc version 5.0.0 20141210 (experimental)
> (GCC).


^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2014-12-16 17:48 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-05-26 16:25 [Bug go/61322] New: gccgo: spurious "incompatible type for field 2 in struct construction" error [GoSmith] dvyukov at google dot com
2014-12-10  1:41 ` [Bug go/61322] " cmang at google dot com
2014-12-16 17:48 ` cmang at google dot com

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).