refactor: use dialect-neutral Jet type aliases

Replace mysql/postgres intersection interfaces with mysql type aliases
per go-jet/jet#555 and generalize Apply/Expr signatures.

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
2026-06-29 17:47:56 -07:00
parent a303e025b2
commit 8053aafa6f
5 changed files with 30 additions and 40 deletions
+10 -19
View File
@@ -1,24 +1,15 @@
package dbx
import (
"github.com/go-jet/jet/v2/mysql"
"github.com/go-jet/jet/v2/postgres"
)
import "github.com/go-jet/jet/v2/mysql"
// Column is a union type for mysql.Column and postgres.Column
type Column interface {
mysql.Column
postgres.Column
}
// Column is a dialect-neutral alias for Jet column expressions.
type Column = mysql.Column
// ColumnList is a union type for mysql.ColumnList and postgres.ColumnList
type ColumnList interface {
mysql.ColumnList
postgres.ColumnList
}
// ColumnList is a dialect-neutral alias for Jet column lists.
type ColumnList = mysql.ColumnList
// BoolExpression is a union type for mysql.BoolExpression and postgres.BoolExpression
type BoolExpression interface {
mysql.BoolExpression
postgres.BoolExpression
}
// Expression is a dialect-neutral alias for Jet SQL expressions.
type Expression = mysql.Expression
// BoolExpression is a dialect-neutral alias for Jet boolean expressions.
type BoolExpression = mysql.BoolExpression