aboutsummaryrefslogtreecommitdiff
path: root/doc/go1.15.html
blob: d5b583291337ae0ff3df7cb569812c0e85a4c515 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
<!--{
        "Title": "Go 1.15 Release Notes",
        "Path":  "/doc/go1.15"
}-->

<!--
NOTE: In this document and others in this directory, the convention is to
set fixed-width phrases with non-fixed-width spaces, as in
<code>hello</code> <code>world</code>.
Do not send CLs removing the interior tags from such phrases.
-->

<style>
  main ul li { margin: 0.5em 0; }
</style>

<h2 id="introduction">DRAFT RELEASE NOTES — Introduction to Go 1.15</h2>

<p>
  <strong>
    Go 1.15 is not yet released. These are work-in-progress
    release notes. Go 1.15 is expected to be released in August 2020.
  </strong>
</p>

<h2 id="language">Changes to the language</h2>

<p>
TODO
</p>

<h2 id="ports">Ports</h2>

<p>
TODO
</p>

<h2 id="tools">Tools</h2>

<p>
TODO
</p>

<h3 id="go-command">Go command</h3>

<p><!-- golang.org/issue/37367 -->
  The <code>GOPROXY</code> environment variable now supports skipping proxies
  that return errors. Proxy URLs may now be separated with either commas
  (<code>,</code>) or pipe characters (<code>|</code>). If a proxy URL is
  followed by a comma, the <code>go</code> command will only try the next proxy
  in the list after a 404 or 410 HTTP response. If a proxy URL is followed by a
  pipe character, the <code>go</code> command will try the next proxy in the
  list after any error. Note that the default value of <code>GOPROXY</code>
  remains <code>https://proxy.golang.org,direct</code>, which does not fall
  back to <code>direct</code> in case of errors.
</p>

<p>
TODO
</p>

<h4 id="go-test"><code>go</code> <code>test</code></h4>

<p><!-- https://golang.org/issue/36134 -->
  Changing the <code>-timeout</code> flag now invalidates cached test results. A
  cached result for a test run with a long timeout will no longer count as
  passing when <code>go</code> <code>test</code> is re-invoked with a short one.
</p>

<h4 id="go-flag-parsing">Flag parsing</h4>

<p><!-- https://golang.org/cl/211358 -->
  Various flag parsing issues in <code>go</code> <code>test</code> and
  <code>go</code> <code>vet</code> have been fixed. Notably, flags specified
  in <code>GOFLAGS</code> are handled more consistently, and
  the <code>-outputdir</code> flag now interprets relative paths relative to the
  working directory of the <code>go</code> command (rather than the working
  directory of each individual test).
</p>

<h2 id="runtime">Runtime</h2>

<p>
TODO
</p>


<h2 id="library">Core library</h2>

<p>
TODO
</p>

<dl id="testing"><dt><a href="/pkg/testing/">testing</a></dt>
  <dd>
    <p><!-- golang.org/issue/28135 -->
      The <code>testing.T</code> type now has a <code>Deadline</code> method
      that reports the time at which the test binary will have exceeded its
      timeout.
    </p>
    <p><!-- golang.org/issue/34129 -->
      A <code>TestMain</code> function is no longer required to call
      <code>os.Exit</code>. If a <code>TestMain</code> function returns,
      the test binary will call <code>os.Exit</code> with the value returned
      by <code>m.Run</code>.
    </p>
  </dd>
</dl><!-- testing -->

<h3 id="minor_library_changes">Minor changes to the library</h3>

<p>
  As always, there are various minor changes and updates to the library,
  made with the Go 1 <a href="/doc/go1compat">promise of compatibility</a>
  in mind.
</p>

<p>
TODO
</p>

<dl id="flag"><dt><a href="/pkg/flag/">flag</a></dt>
  <dd>
    <p><!-- CL 221427 -->
      When the flag package sees <code>-h</code> or <code>-help</code>, and
      those flags are not defined, the flag package prints a usage message.
      If the <a href=/pkg/flag/#FlagSet><code>FlagSet</code></a> was created with
      <a href=/pkg/flag/#ExitOnError><code>ExitOnError</code></a>,
      <a href=/pkg/flag/#FlagSet.Parse><code>FlagSet.Parse</code></a> would then
      exit with a status of 2. In this release, the exit status for <code>-h</code>
      or <code>-help</code> has been changed to 0. In particular, this applies to
      the default handling of command line flags.
    </p>
  </dd>
</dl>

<dl id="pkg-runtime"><dt><a href="/pkg/runtime/">runtime</a></dt>
  <dd>
    <p><!-- CL 221779 -->
      If <code>panic</code> is invoked with a value whose type is derived from any
      of: <code>bool</code>, <code>complex64</code>, <code>complex128</code>, <code>float32</code>, <code>float64</code>,
      <code>int</code>, <code>int8</code>, <code>int16</code>, <code>int32</code>, <code>int64</code>, <code>string</code>,
      <code>uint</code>, <code>uint8</code>, <code>uint16</code>, <code>uint32</code>, <code>uint64</code>, <code>uintptr</code>,
      then the value will be printed, instead of just its address.
    </p>
  </dd>
</dl>

<dl id="sync"><dt><a href="/pkg/sync/">sync</a></dt>
  <dd>
    <p><!-- golang.org/issue/33762 -->
      The new method
      <a href="/pkg/sync#Map.LoadAndDelete"><code>Map.LoadAndDelete</code></a>
      atomically deletes a key and returns the previous value if present.
    </p>
    <p><!-- CL 205899 -->
      The method
      <a href="/pkg/sync#Map.Delete"><code>Map.Delete</code></a>
      is more efficient.
    </p>
</dl><!-- sync -->

<dl id="time"><dt><a href="/pkg/time/">time</a></dt>
  <dd>
    <p><!-- golang.org/issue/33184 -->
       The new method
       <a href="/pkg/time#Ticker.Reset"><code>Ticker.Reset</code></a>
       supports changing the duration of a ticker.
    </p>
  </dd>
</dl><!-- time -->