diff options
Diffstat (limited to 'misc/cgo/testshared/shared_test.go')
-rw-r--r-- | misc/cgo/testshared/shared_test.go | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/misc/cgo/testshared/shared_test.go b/misc/cgo/testshared/shared_test.go index e77f848915..0568ac773f 100644 --- a/misc/cgo/testshared/shared_test.go +++ b/misc/cgo/testshared/shared_test.go @@ -1070,3 +1070,11 @@ func TestIssue44031(t *testing.T) { goCmd(t, "install", "-buildmode=shared", "-linkshared", "./issue44031/b") goCmd(t, "run", "-linkshared", "./issue44031/main") } + +// Test that we use a variable from shared libraries (which implement an +// interface in shared libraries.). A weak reference is used in the itab +// in main process. It can cause unreacheble panic. See issue 47873. +func TestIssue47873(t *testing.T) { + goCmd(t, "install", "-buildmode=shared", "-linkshared", "./issue47837/a") + goCmd(t, "run", "-linkshared", "./issue47837/main") +} |