Source file src/cmd/cgo/internal/testplugin/testdata/issue75102/main.go

     1  // Copyright 2025 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 main
     6  
     7  import (
     8  	"fmt"
     9  	"plugin"
    10  )
    11  
    12  func init() {
    13  	_, err := plugin.Open("issue75102.so")
    14  	if err == nil {
    15  		panic("unexpected success to open a different version plugin")
    16  	}
    17  }
    18  
    19  func main() {
    20  	fmt.Println("done")
    21  }
    22  

View as plain text