Skip to content

Commit

Permalink
doc/go1.19: document Resolver.PreferGo
Browse files Browse the repository at this point in the history
Updates #51400

Change-Id: I61733574362d4cf3cb65122bd13361e5c0f6728c
Reviewed-on: https://go-review.googlesource.com/c/go/+/410375
Run-TryBot: Heschi Kreinick <heschi@google.com>
TryBot-Result: Gopher Robot <gobot@golang.org>
Reviewed-by: Michael Pratt <mpratt@google.com>
Run-TryBot: Michael Pratt <mpratt@google.com>
Reviewed-by: Heschi Kreinick <heschi@google.com>
Auto-Submit: Michael Pratt <mpratt@google.com>
  • Loading branch information
bradfitz authored and gopherbot committed Jun 6, 2022
1 parent 11195c6 commit c1e2ecb
Showing 1 changed file with 14 additions and 1 deletion.
15 changes: 14 additions & 1 deletion doc/go1.19.html
Expand Up @@ -343,7 +343,20 @@ <h3 id="minor_library_changes">Minor changes to the library</h3>
</dd>
<dd>
<p><!-- CL 400654 -->
TODO: <a href="https://go.dev/cl/400654">https://go.dev/cl/400654</a>: permit use of Resolver.PreferGo, netgo on Windows and Plan 9
<a href="/pkg/net/#Resolver.PreferGo"><code>Resolver.PreferGo</code></a>
is now implemented on Windows and Plan 9. It previously only worked on Unix
platforms. Combined with
<a href="/pkg/net/#Dialer.Resolver"><code>Dialer.Resolver</code></a> and
<a href="/pkg/net/#Resolver.Dial"><code>Resolver.Dial</code></a>, it's now
possible to write portable programs and be in control of all DNS name lookups
when dialing.
</p>
<p>
The <code>net</code> package now has initial support for the <code>netgo</code>
build tag on Windows. When used, the package uses the Go DNS client (as used
by <code>Resolver.PreferGo</code>) instead of asking Windows for
DNS results. The upstream DNS server it discovers from Windows
may not yet be correct with complex system network configurations, however.
</p>
</dd>
</dl><!-- net -->
Expand Down

0 comments on commit c1e2ecb

Please sign in to comment.