From 5e2ddecdcc11fe1127e27cee6c941a60045ebf10 Mon Sep 17 00:00:00 2001 From: jake Date: Tue, 30 Sep 2025 11:41:28 -0400 Subject: [PATCH] dont elem slice --- lazy.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lazy.go b/lazy.go index 1976601..ec2a0cd 100644 --- a/lazy.go +++ b/lazy.go @@ -129,7 +129,8 @@ func RandomStruct(c Config) (*StructMock, error) { maxFieldCount := retType.NumField() //create slice of structs ft := reflect.SliceOf(retType) - filled := reflect.MakeSlice(ft, 0, c.RowCount).Elem() + filled := reflect.MakeSlice(ft, 0, c.RowCount) + // filled := reflect.MakeSlice(ft, 0, c.RowCount).Elem() args := make([]driver.Value, 0, maxFieldCount) for x := 0; x < c.RowCount; x++ {