From 652ec0ceef105f9cdf673e189120e5a1a4eefe67 Mon Sep 17 00:00:00 2001 From: j2gg0s Date: Wed, 27 Nov 2024 14:46:43 +0800 Subject: [PATCH] feat(schema): scan field with alloc --- schema/field.go | 7 ------- 1 file changed, 7 deletions(-) diff --git a/schema/field.go b/schema/field.go index 06d0a5094..b5fd27f2b 100644 --- a/schema/field.go +++ b/schema/field.go @@ -113,13 +113,6 @@ func (f *Field) AppendValue(fmter Formatter, b []byte, strct reflect.Value) []by } func (f *Field) ScanValue(strct reflect.Value, src interface{}) error { - if src == nil { - if fv, ok := fieldByIndex(strct, f.Index); ok { - return f.ScanWithCheck(fv, src) - } - return nil - } - fv := internal.FieldByIndexAlloc(strct, f.Index) return f.ScanWithCheck(fv, src) }