1 // Copyright 2020 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.
5 // Test that GC data is generated correctly for global
6 // variables with types defined in a shared library.
9 // This test run under GODEBUG=clobberfree=1. The check
10 // *x[i] == 12345 depends on this debug mode to clobber
11 // the value if the object is freed prematurely.
33 fmt.Printf("x[%d] == %d, want 12345\n", i, *x[i])