...

Text file src/cmd/go/testdata/script/embed_fmt.txt

Documentation: cmd/go/testdata/script

     1# go fmt ignores file not found
     2go fmt xnofmt.go
     3cmp xnofmt.go xfmt.ref
     4! go build xnofmt.go
     5stderr 'xnofmt.go:5:12: pattern missing.txt: no matching files found'
     6
     7-- xnofmt.go --
     8package p
     9
    10import "embed"
    11
    12//go:embed missing.txt
    13var X  embed.FS
    14-- xfmt.ref --
    15package p
    16
    17import "embed"
    18
    19//go:embed missing.txt
    20var X embed.FS
    21-- go.mod --
    22module m

View as plain text