github.com/amarpal/go-tools@v0.0.0-20240422043104-40142f59f616/staticcheck/sa1019/testdata/src/example.com/CheckDeprecated_go13/CheckDeprecated.go (about)

     1  package pkg
     2  
     3  import (
     4  	"crypto/x509"
     5  	"net/http/httputil"
     6  	"path/filepath"
     7  )
     8  
     9  func fn() {
    10  	filepath.HasPrefix("", "") //@ diag(`filepath.HasPrefix has been deprecated since Go 1.0 because it shouldn't be used:`)
    11  	_ = httputil.ErrPersistEOF //@ diag(`httputil.ErrPersistEOF has been deprecated since Go 1.0:`)
    12  	_ = httputil.ServerConn{}  //@ diag(`httputil.ServerConn has been deprecated since Go 1.0:`)
    13  	_ = x509.CertificateRequest{}.Attributes
    14  }