]> Cypherpunks.ru repositories - gostls13.git/blobdiff - test/nilptr2.go
cmd/compile/internal/inline: score call sites exposed by inlines
[gostls13.git] / test / nilptr2.go
index 250a0ee6a907aaa0dfb807edf590cf6ea5af1ddb..8a85b6dbcb16484f3bdfe1052f20dd24a5494534 100644 (file)
@@ -1,13 +1,11 @@
 // run
 
-// Copyright 2013 The Go Authors.  All rights reserved.
+// Copyright 2013 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.
 
 package main
 
-import "os"
-
 func main() {
        ok := true
        for _, tt := range tests {
@@ -23,7 +21,6 @@ func main() {
        }
        if !ok {
                println("BUG")
-               os.Exit(1)
        }
 }
 
@@ -38,7 +35,10 @@ var m *M
 var m1 *M1
 var m2 *M2
 
-func use(interface{}) {
+var V interface{}
+
+func use(x interface{}) {
+       V = x
 }
 
 var tests = []struct{