aboutsummaryrefslogtreecommitdiffstats
path: root/testdata/simple.go
diff options
context:
space:
mode:
Diffstat (limited to 'testdata/simple.go')
-rw-r--r--testdata/simple.go12
1 files changed, 12 insertions, 0 deletions
diff --git a/testdata/simple.go b/testdata/simple.go
index 0a2f0af..d01a95e 100644
--- a/testdata/simple.go
+++ b/testdata/simple.go
@@ -23,3 +23,15 @@ func main() {
strings.Repeat(str, 3)
}(copied)
}
+
+func argumentReference() {
+ type aStruct struct{
+ field int
+ }
+
+ s := aStruct{field: 0}
+
+ go func(s *aStruct) {
+ s.field += 1
+ }(&s)
+}