modernc.org/gc@v1.0.1-0.20240304020402-f0dba7c97c2b/testdata/errchk/test/fixedbugs/issue10219.dir/a.go (about)

     1  // Copyright 2015 The Go Authors. All rights reserved.
     2  // Use of this source code is governed by a BSD-style
     3  // license that can be found in the LICENSE file.
     4  
     5  package a
     6  
     7  type m struct {
     8  	S string
     9  }
    10  
    11  var g = struct {
    12  	m
    13  	P string
    14  }{
    15  	m{"a"},
    16  	"",
    17  }
    18  
    19  type S struct{}
    20  
    21  func (s *S) M(p string) {
    22  	r := g
    23  	r.P = p
    24  }