Hello r, ken2 (cc: golang-dev@googlegroups.com), I'd like you to review this change.
LGTM On May 19, 2010, at 10:09 AM, gri@golang.org wrote: > Reviewers: r, ken2, > > Message: > Hello r, ken2 (cc: golang-dev@googlegroups.com), > > I'd like you to review this change. > > > Description: > bug275: cannot apply real() to a complex array element > > Please review this at http://codereview.appspot.com/1260041/show > > Affected files: > A test/bugs/bug275.go > M test/golden.out > > > Index: test/bugs/bug275.go > =================================================================== > new file mode 100644 > --- /dev/null > +++ b/test/bugs/bug275.go > @@ -0,0 +1,20 @@ > +// $G $D/$F.go || echo BUG should compile > + > +// Copyright 2010 The Go Authors. All rights reserved. > +// Use of this source code is governed by a BSD-style > +// license that can be found in the LICENSE file. > + > +// This is a test case for issue 788. > + > +package main > + > +func main() { > + var a [1]complex64 > + > + t := a[0] > + _ = real(t) // this works > + > + _ = real(a[0]) // this doesn't > +} > + > +// bug275.go:17: internal compiler error: subnode not addable > Index: test/golden.out > =================================================================== > --- a/test/golden.out > +++ b/test/golden.out > @@ -180,3 +180,7 @@ > > =========== bugs/bug274.go > BUG: errchk: command succeeded unexpectedly > + > +=========== bugs/bug275.go > +bugs/bug275.go:17: internal compiler error: subnode not addable > +BUG should compile > >
*** Submitted as http://code.google.com/p/go/source/detail?r=f83d5263416f *** bug275: cannot apply real() to a complex array element R=r, ken2 CC=golang-dev http://codereview.appspot.com/1260041