Source file test/typeparam/issue51250a.dir/main.go

     1  // Copyright 2022 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  	"./a"
     9  	"./b"
    10  )
    11  
    12  func main() {
    13  	switch b.I.(type) {
    14  	case a.G[b.T]:
    15  	case int:
    16  		panic("bad")
    17  	case float64:
    18  		panic("bad")
    19  	default:
    20  		panic("bad")
    21  	}
    22  
    23  	b.F(a.G[b.T]{})
    24  }
    25  

View as plain text