pgx
pgx copied to clipboard
`driver.Valuer` not handled properly on pointer receivers
Because the encodePreparedStatementArgument
dereferences the pointer before checking for the driver.Valuer
interface, it will never be used for types which define Value()
on a pointer receiver.
i.e. this works:
type MyType struct {}
func (m MyType) Value() (driver.Value, error)
but this doesn't
type MyType struct {}
func (m *MyType) Value() (driver.Value, error)