refactor(ksuid): replace BinExpr with top-level expr helpers

Adds StringKSUIDExpr and BinaryKSUIDExpr for use with ExprValues, plus
Expr() methods on both types. Removes ExprStringKSUIDs and BinExpr.

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
2026-06-29 18:47:18 -07:00
parent eafe84ef31
commit a712ccc38f
8 changed files with 75 additions and 35 deletions
+5
View File
@@ -48,6 +48,11 @@ func (s StringKSUID) AsBinaryKSUID() BinaryKSUID {
return BinaryKSUID{KSUID: s.KSUID}
}
// Expr returns a Jet expression for this StringKSUID. See [StringKSUIDExpr].
func (s StringKSUID) Expr() Expression {
return StringKSUIDExpr(s)
}
// Scan implements sql.Scanner for string-backed KSUID columns.
func (s *StringKSUID) Scan(src any) error {
switch v := src.(type) {