Summary
Several types in field/interface.go use an *Interface suffix that doesn't follow Go naming conventions. Go interfaces are named after the behavior they describe (e.g. io.Reader, io.Closer), not with an Interface suffix.
Current
type QueryInterface = clause.Expression
type AssociationInterface interface { ... }
type ColumnInterface interface { ... }
type OrderableInterface interface { ... }
type DistinctInterface interface { ... }
Proposed
| Current |
Proposed |
Notes |
QueryInterface |
Query |
Type alias — rename to Query or remove and use clause.Expression directly |
AssociationInterface |
Association |
Free name, no clash |
ColumnInterface |
Column |
Free name, no clash |
OrderableInterface |
Orderable |
Free name, no clash |
DistinctInterface |
Remove |
Duplicate of Selectable (same method: buildSelectArg() any) |
Affected Files
field/interface.go — type definitions
- All files referencing the renamed types
References
Summary
Several types in
field/interface.gouse an*Interfacesuffix that doesn't follow Go naming conventions. Go interfaces are named after the behavior they describe (e.g.io.Reader,io.Closer), not with anInterfacesuffix.Current
Proposed
QueryInterfaceQueryQueryor remove and useclause.ExpressiondirectlyAssociationInterfaceAssociationColumnInterfaceColumnOrderableInterfaceOrderableDistinctInterfaceSelectable(same method:buildSelectArg() any)Affected Files
field/interface.go— type definitionsReferences