]> Cypherpunks repositories - gostls13.git/commitdiff
doc/go1.17: document database/sql changes for Go 1.17
authorsryoya <ryoyasekino1993@gmail.com>
Sun, 16 May 2021 14:36:05 +0000 (23:36 +0900)
committerHeschi Kreinick <heschi@google.com>
Fri, 21 May 2021 17:43:46 +0000 (17:43 +0000)
For #44513
Fixes #46008

Change-Id: If80d484f73a0eb6946abdc654eb2c0d3dd6db416
Reviewed-on: https://go-review.googlesource.com/c/go/+/320251
Reviewed-by: Heschi Kreinick <heschi@google.com>
Trust: Robert Findley <rfindley@google.com>

doc/go1.17.html

index 4561b6ccf52e795ce7c511dd4993fbe187977876..3534f7be040ee6bcc77cfb42546f5623f47640df 100644 (file)
@@ -320,11 +320,19 @@ Do not send CLs removing the interior tags from such phrases.
 <dl id="database/sql"><dt><a href="/pkg/database/sql/">database/sql</a></dt>
   <dd>
     <p><!-- CL 258360 -->
-      TODO: <a href="https://golang.org/cl/258360">https://golang.org/cl/258360</a>: close driver.Connector if it implements io.Closer
+      The <a href="/pkg/database/sql/#DB.Close"><code>DB.Close</code></a> method now closes
+      the <code>connector</code> field if the type in this field implements the
+      <a href="/pkg/io/#Closer"><code>io.Closer</code></a> interface.
     </p>
 
     <p><!-- CL 311572 -->
-      TODO: <a href="https://golang.org/cl/311572">https://golang.org/cl/311572</a>: add NullInt16 and NullByte
+      The new
+      <a href="/pkg/database/sql/#NullInt16"><code>NullInt16</code></a> 
+      and 
+      <a href="/pkg/database/sql/#NullByte"><code>NullByte</code></a> 
+      structs represent the int16 and byte values that may be null. These can be used as
+      destinations of the <a href="/pkg/database/sql/#Scan"><code>Scan</code></a> method,
+      similar to NullString.
     </p>
   </dd>
 </dl><!-- database/sql -->