Files
moxa/_test/redeclaration3.go
mpl 6f878052f8 interp: detect local redeclaration (#673)
* interp: detect local redecleration

Fixes #666

* make make check happy

* fix typo in filenames, add them to the exclusion list

Co-authored-by: Marc Vertes <mvertes@free.fr>
2020-06-03 17:21:00 +02:00

14 lines
174 B
Go

package main
func main() {
var foo int
foo = 2
type foo struct{}
var bar foo
println(bar)
}
// Error:
// ../_test/redeclaration3.go:7:7: foo redeclared in this block