From 0e2e8e54ab85889d3c42cf8b0744c3253065983b Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 3 Mar 2025 09:51:42 +0000 Subject: [chore]: Bump github.com/ncruces/go-sqlite3 from 0.23.0 to 0.24.0 (#3862) Bumps [github.com/ncruces/go-sqlite3](https://github.com/ncruces/go-sqlite3) from 0.23.0 to 0.24.0. - [Release notes](https://github.com/ncruces/go-sqlite3/releases) - [Commits](https://github.com/ncruces/go-sqlite3/compare/v0.23.0...v0.24.0) --- updated-dependencies: - dependency-name: github.com/ncruces/go-sqlite3 dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> --- vendor/github.com/ncruces/go-sqlite3/conn.go | 21 ++++++++++++++------- 1 file changed, 14 insertions(+), 7 deletions(-) (limited to 'vendor/github.com/ncruces/go-sqlite3/conn.go') diff --git a/vendor/github.com/ncruces/go-sqlite3/conn.go b/vendor/github.com/ncruces/go-sqlite3/conn.go index fffc7416a..9f9251e9f 100644 --- a/vendor/github.com/ncruces/go-sqlite3/conn.go +++ b/vendor/github.com/ncruces/go-sqlite3/conn.go @@ -3,6 +3,7 @@ package sqlite3 import ( "context" "fmt" + "iter" "math" "math/rand" "net/url" @@ -492,9 +493,9 @@ func (c *Conn) TableColumnMetadata(schema, table, column string) (declType, coll if ptr := util.Read32[ptr_t](c.mod, collSeqPtr); ptr != 0 { collSeq = util.ReadString(c.mod, ptr, _MAX_NAME) } - notNull = util.Read32[uint32](c.mod, notNullPtr) != 0 - autoInc = util.Read32[uint32](c.mod, autoIncPtr) != 0 - primaryKey = util.Read32[uint32](c.mod, primaryKeyPtr) != 0 + notNull = util.ReadBool(c.mod, notNullPtr) + autoInc = util.ReadBool(c.mod, autoIncPtr) + primaryKey = util.ReadBool(c.mod, primaryKeyPtr) } return } @@ -503,10 +504,16 @@ func (c *Conn) error(rc res_t, sql ...string) error { return c.sqlite.error(rc, c.handle, sql...) } -func (c *Conn) stmtsIter(yield func(*Stmt) bool) { - for _, s := range c.stmts { - if !yield(s) { - break +// Stmts returns an iterator for the prepared statements +// associated with the database connection. +// +// https://sqlite.org/c3ref/next_stmt.html +func (c *Conn) Stmts() iter.Seq[*Stmt] { + return func(yield func(*Stmt) bool) { + for _, s := range c.stmts { + if !yield(s) { + break + } } } } -- cgit v1.2.3