From bd53297a6cd9d9c21852b432640fba461053a1b1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Matczuk?= Date: Fri, 17 Jan 2020 14:46:06 +0100 Subject: [PATCH] iterx: Change field order MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: MichaƂ Matczuk --- iterx.go | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/iterx.go b/iterx.go index 74d0287..e56ae64 100644 --- a/iterx.go +++ b/iterx.go @@ -34,14 +34,15 @@ func Select(dest interface{}, q *gocql.Query) error { // Iterx is a wrapper around gocql.Iter which adds struct scanning capabilities. type Iterx struct { *gocql.Iter - err error - - unsafe bool Mapper *reflectx.Mapper - // these fields cache memory use for a rows during iteration w/ structScan + + unsafe bool started bool - fields [][]int - values []interface{} + err error + + // Cache memory for a rows during iteration in StructScan. + fields [][]int + values []interface{} } // Iter creates a new Iterx from gocql.Query using a default mapper.