1 // Copyright 2009 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.
5 // Verify that various kinds of "imported and not used"
6 // errors are caught by the compiler.
12 import "fmt" // ERROR "imported and not used.*fmt|\x22fmt\x22 imported and not used"
15 import X "math" // ERROR "imported and not used.*math|\x22math\x22 imported as X and not used"
18 import . "bufio" // ERROR "imported and not used.*bufio|imported and not used"
20 // again, package without anything in it
21 import "./empty" // ERROR "imported and not used.*empty|imported and not used"
22 import Z "./empty" // ERROR "imported and not used.*empty|imported as Z and not used"
23 import . "./empty" // ERROR "imported and not used.*empty|imported and not used"