aboutsummaryrefslogtreecommitdiffstats
path: root/pkg/compiler/compiler.go
diff options
context:
space:
mode:
authorDmitry Vyukov <dvyukov@google.com>2025-12-19 12:52:30 +0100
committerAleksandr Nogikh <nogikh@google.com>2025-12-22 02:13:00 +0000
commita83befa0d111a0ba6fac52d763e93c76a2ef94d4 (patch)
tree7d3c28b24229429936a631e8ceb24135856b257d /pkg/compiler/compiler.go
parent8fb7048c5117ccb592deb5e8e4a62027e6d399cf (diff)
all: use any instead of interface{}
Any is the preferred over interface{} now in Go.
Diffstat (limited to 'pkg/compiler/compiler.go')
-rw-r--r--pkg/compiler/compiler.go4
1 files changed, 2 insertions, 2 deletions
diff --git a/pkg/compiler/compiler.go b/pkg/compiler/compiler.go
index 3022def7f..7b22cef42 100644
--- a/pkg/compiler/compiler.go
+++ b/pkg/compiler/compiler.go
@@ -148,12 +148,12 @@ type warn struct {
msg string
}
-func (comp *compiler) error(pos ast.Pos, msg string, args ...interface{}) {
+func (comp *compiler) error(pos ast.Pos, msg string, args ...any) {
comp.errors++
comp.eh(pos, fmt.Sprintf(msg, args...))
}
-func (comp *compiler) warning(pos ast.Pos, msg string, args ...interface{}) {
+func (comp *compiler) warning(pos ast.Pos, msg string, args ...any) {
comp.warnings = append(comp.warnings, warn{pos, fmt.Sprintf(msg, args...)})
}