You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
26 lines
348 B
26 lines
348 B
package main
|
|
|
|
import (
|
|
"fmt"
|
|
"os/exec"
|
|
)
|
|
|
|
func reassignments() {
|
|
// START OMIT
|
|
|
|
//f := func() {
|
|
// f() // undeclared name: f
|
|
//}
|
|
|
|
var f func()
|
|
f = func() {
|
|
f()
|
|
}
|
|
// END OMIT
|
|
}
|
|
func main() {
|
|
cmd := exec.Command("/go/bin/funcheck", "./code/reassignments/funcliterals")
|
|
out, err := cmd.CombinedOutput()
|
|
fmt.Printf("%s\n%s", out, err)
|
|
}
|