-
Notifications
You must be signed in to change notification settings - Fork 18.4k
Closed
Labels
Description
What steps will reproduce the problem? 1. Compile the following programs: a.go: package a var X = 0 b.go: package main import . "a" var X = 0 What is the expected output? What do you see instead? Expected: b.go:3: X redeclared in this block previous declaration at a.go:2 or perhaps: b.go:2: imported and not used: a Actual: (no errors) What is your $GOOS? $GOARCH? GOARCH=386 GOOS=linux Which revision are you using? (hg identify) 7929874a70ae tip Please provide any additional information below. The spec for import . says "all the package's exported identifiers will be declared in the current file's file block", so the example above should probably be diagnosed with a redeclaration error.