Skip to content
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.

Commit f705a2b

Browse files
committedMay 13, 2025··
chore: use any in place of interface{}
This addresses the lint raised by gopls for modernizing the usage of an empty interface for the `any` type. Signed-off-by: Prajwal S N <[email protected]>
1 parent 34f8c1b commit f705a2b

File tree

985 files changed

+2949
-2949
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

985 files changed

+2949
-2949
lines changed
 

‎internal/codegen/golang/go_type.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -87,6 +87,6 @@ func goInnerType(req *plugin.GenerateRequest, options *opts.Options, col *plugin
8787
case "sqlite":
8888
return sqliteType(req, options, col)
8989
default:
90-
return "interface{}"
90+
return "any"
9191
}
9292
}

‎internal/codegen/golang/mysql_type.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -111,7 +111,7 @@ func mysqlType(req *plugin.GenerateRequest, options *opts.Options, col *plugin.C
111111
return "json.RawMessage"
112112

113113
case "any":
114-
return "interface{}"
114+
return "any"
115115

116116
default:
117117
for _, schema := range req.Catalog.Schemas {
@@ -134,7 +134,7 @@ func mysqlType(req *plugin.GenerateRequest, options *opts.Options, col *plugin.C
134134
if debug.Active {
135135
log.Printf("Unknown MySQL type: %s\n", columnType)
136136
}
137-
return "interface{}"
137+
return "any"
138138

139139
}
140140
}

0 commit comments

Comments
 (0)
Please sign in to comment.