diff options
Diffstat (limited to 'src/cmd/compile/internal/base/print.go')
-rw-r--r-- | src/cmd/compile/internal/base/print.go | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/cmd/compile/internal/base/print.go b/src/cmd/compile/internal/base/print.go index 21fa001457..6d21c33254 100644 --- a/src/cmd/compile/internal/base/print.go +++ b/src/cmd/compile/internal/base/print.go @@ -7,6 +7,7 @@ package base import ( "fmt" "internal/buildcfg" + "internal/types/errors" "os" "runtime/debug" "sort" @@ -105,11 +106,11 @@ func sameline(a, b src.XPos) bool { // Errorf reports a formatted error at the current line. func Errorf(format string, args ...interface{}) { - ErrorfAt(Pos, format, args...) + ErrorfAt(Pos, 0, format, args...) } // ErrorfAt reports a formatted error message at pos. -func ErrorfAt(pos src.XPos, format string, args ...interface{}) { +func ErrorfAt(pos src.XPos, code errors.Code, format string, args ...interface{}) { msg := fmt.Sprintf(format, args...) if strings.HasPrefix(msg, "syntax error") { |