issue18452.go 390 B

123456789101112131415161718
  1. // Copyright 2017 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.
  4. // Issue 18452: show pos info in undefined name errors
  5. package p
  6. import (
  7. "C"
  8. "fmt"
  9. )
  10. func a() {
  11. fmt.Println("Hello, world!")
  12. C.function_that_does_not_exist() // ERROR HERE
  13. C.pi // ERROR HERE
  14. }