go/src/database/sql
Brad Fitzpatrick 08c3299829 database/sql: remove a distracting alloc, use atomic.Bool
This removes an allocation in Conn.grabConn that, while not super
important, was distracting me when optimizing code elsewhere.

While here, convert an atomic that was forgotten when this package was
earlier updated to use the new Go 1.19 typed atomics.

Change-Id: I4666256b4c0512e2162bd485c389130699f9d5ed
Reviewed-on: https://go-review.googlesource.com/c/go/+/475415
Reviewed-by: David Crawshaw <crawshaw@golang.org>
Reviewed-by: Ian Lance Taylor <iant@google.com>
TryBot-Result: Gopher Robot <gobot@golang.org>
Reviewed-by: Cherry Mui <cherryyz@google.com>
Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org>
2023-03-14 20:34:27 +00:00
..
driver database/sql/driver: fix typo in driver.go 2022-06-04 21:17:03 +00:00
convert.go database: use bytes.Clone 2022-09-28 03:16:54 +00:00
convert_test.go
ctxutil.go
doc.txt
example_cli_test.go
example_service_test.go
example_test.go
fakedb_test.go database/sql: fix close rows error ignored in Next 2022-05-19 20:21:12 +00:00
sql.go database/sql: remove a distracting alloc, use atomic.Bool 2023-03-14 20:34:27 +00:00
sql_test.go database/sql: remove a distracting alloc, use atomic.Bool 2023-03-14 20:34:27 +00:00