Skip to content

Commit

Permalink
[dev.boringcrypto] all: merge master into dev.boringcrypto
Browse files Browse the repository at this point in the history
Change-Id: Ia661c871e14445672b7d36a443455302e47cc2a1
  • Loading branch information
FiloSottile committed Oct 25, 2018
2 parents 623650b + ab51b1d commit 13bf5b8
Show file tree
Hide file tree
Showing 534 changed files with 25,004 additions and 6,720 deletions.
100 changes: 100 additions & 0 deletions api/except.txt
Expand Up @@ -6,6 +6,8 @@ pkg os, const ModeType = 2399141888
pkg os, const ModeType = 2399666176
pkg os (linux-arm), const O_SYNC = 4096
pkg os (linux-arm-cgo), const O_SYNC = 4096
pkg os (linux-arm), const O_SYNC = 1052672
pkg os (linux-arm-cgo), const O_SYNC = 1052672
pkg syscall (darwin-386), const ImplementsGetwd = false
pkg syscall (darwin-386), func Fchflags(string, int) error
pkg syscall (darwin-386-cgo), const ImplementsGetwd = false
Expand Down Expand Up @@ -381,3 +383,101 @@ pkg syscall (windows-amd64), type CertRevocationInfo struct, CrlInfo uintptr
pkg syscall (windows-amd64), type CertRevocationInfo struct, OidSpecificInfo uintptr
pkg syscall (windows-amd64), type CertSimpleChain struct, TrustListInfo uintptr
pkg syscall (windows-amd64), type RawSockaddrAny struct, Pad [96]int8
pkg syscall (freebsd-386), func Mknod(string, uint32, int) error
pkg syscall (freebsd-386), type Dirent struct, Fileno uint32
pkg syscall (freebsd-386), type Dirent struct, Namlen uint8
pkg syscall (freebsd-386), type Stat_t struct, Atimespec Timespec
pkg syscall (freebsd-386), type Stat_t struct, Birthtimespec Timespec
pkg syscall (freebsd-386), type Stat_t struct, Blksize uint32
pkg syscall (freebsd-386), type Stat_t struct, Ctimespec Timespec
pkg syscall (freebsd-386), type Stat_t struct, Dev uint32
pkg syscall (freebsd-386), type Stat_t struct, Gen uint32
pkg syscall (freebsd-386), type Stat_t struct, Ino uint32
pkg syscall (freebsd-386), type Stat_t struct, Lspare int32
pkg syscall (freebsd-386), type Stat_t struct, Mtimespec Timespec
pkg syscall (freebsd-386), type Stat_t struct, Nlink uint16
pkg syscall (freebsd-386), type Stat_t struct, Pad_cgo_0 [8]uint8
pkg syscall (freebsd-386), type Stat_t struct, Rdev uint32
pkg syscall (freebsd-386), type Statfs_t struct, Mntfromname [88]int8
pkg syscall (freebsd-386), type Statfs_t struct, Mntonname [88]int8
pkg syscall (freebsd-386-cgo), func Mknod(string, uint32, int) error
pkg syscall (freebsd-386-cgo), type Dirent struct, Fileno uint32
pkg syscall (freebsd-386-cgo), type Dirent struct, Namlen uint8
pkg syscall (freebsd-386-cgo), type Stat_t struct, Atimespec Timespec
pkg syscall (freebsd-386-cgo), type Stat_t struct, Birthtimespec Timespec
pkg syscall (freebsd-386-cgo), type Stat_t struct, Blksize uint32
pkg syscall (freebsd-386-cgo), type Stat_t struct, Ctimespec Timespec
pkg syscall (freebsd-386-cgo), type Stat_t struct, Dev uint32
pkg syscall (freebsd-386-cgo), type Stat_t struct, Gen uint32
pkg syscall (freebsd-386-cgo), type Stat_t struct, Ino uint32
pkg syscall (freebsd-386-cgo), type Stat_t struct, Lspare int32
pkg syscall (freebsd-386-cgo), type Stat_t struct, Mtimespec Timespec
pkg syscall (freebsd-386-cgo), type Stat_t struct, Nlink uint16
pkg syscall (freebsd-386-cgo), type Stat_t struct, Pad_cgo_0 [8]uint8
pkg syscall (freebsd-386-cgo), type Stat_t struct, Rdev uint32
pkg syscall (freebsd-386-cgo), type Statfs_t struct, Mntfromname [88]int8
pkg syscall (freebsd-386-cgo), type Statfs_t struct, Mntonname [88]int8
pkg syscall (freebsd-amd64), func Mknod(string, uint32, int) error
pkg syscall (freebsd-amd64), type Dirent struct, Fileno uint32
pkg syscall (freebsd-amd64), type Dirent struct, Namlen uint8
pkg syscall (freebsd-amd64), type Stat_t struct, Atimespec Timespec
pkg syscall (freebsd-amd64), type Stat_t struct, Birthtimespec Timespec
pkg syscall (freebsd-amd64), type Stat_t struct, Blksize uint32
pkg syscall (freebsd-amd64), type Stat_t struct, Ctimespec Timespec
pkg syscall (freebsd-amd64), type Stat_t struct, Dev uint32
pkg syscall (freebsd-amd64), type Stat_t struct, Gen uint32
pkg syscall (freebsd-amd64), type Stat_t struct, Ino uint32
pkg syscall (freebsd-amd64), type Stat_t struct, Lspare int32
pkg syscall (freebsd-amd64), type Stat_t struct, Mtimespec Timespec
pkg syscall (freebsd-amd64), type Stat_t struct, Nlink uint16
pkg syscall (freebsd-amd64), type Stat_t struct, Rdev uint32
pkg syscall (freebsd-amd64), type Statfs_t struct, Mntfromname [88]int8
pkg syscall (freebsd-amd64), type Statfs_t struct, Mntonname [88]int8
pkg syscall (freebsd-amd64-cgo), func Mknod(string, uint32, int) error
pkg syscall (freebsd-amd64-cgo), type Dirent struct, Fileno uint32
pkg syscall (freebsd-amd64-cgo), type Dirent struct, Namlen uint8
pkg syscall (freebsd-amd64-cgo), type Stat_t struct, Atimespec Timespec
pkg syscall (freebsd-amd64-cgo), type Stat_t struct, Birthtimespec Timespec
pkg syscall (freebsd-amd64-cgo), type Stat_t struct, Blksize uint32
pkg syscall (freebsd-amd64-cgo), type Stat_t struct, Ctimespec Timespec
pkg syscall (freebsd-amd64-cgo), type Stat_t struct, Dev uint32
pkg syscall (freebsd-amd64-cgo), type Stat_t struct, Gen uint32
pkg syscall (freebsd-amd64-cgo), type Stat_t struct, Ino uint32
pkg syscall (freebsd-amd64-cgo), type Stat_t struct, Lspare int32
pkg syscall (freebsd-amd64-cgo), type Stat_t struct, Mtimespec Timespec
pkg syscall (freebsd-amd64-cgo), type Stat_t struct, Nlink uint16
pkg syscall (freebsd-amd64-cgo), type Stat_t struct, Rdev uint32
pkg syscall (freebsd-amd64-cgo), type Statfs_t struct, Mntfromname [88]int8
pkg syscall (freebsd-amd64-cgo), type Statfs_t struct, Mntonname [88]int8
pkg syscall (freebsd-arm), func Mknod(string, uint32, int) error
pkg syscall (freebsd-arm), type Dirent struct, Fileno uint32
pkg syscall (freebsd-arm), type Dirent struct, Namlen uint8
pkg syscall (freebsd-arm), type Stat_t struct, Atimespec Timespec
pkg syscall (freebsd-arm), type Stat_t struct, Birthtimespec Timespec
pkg syscall (freebsd-arm), type Stat_t struct, Blksize uint32
pkg syscall (freebsd-arm), type Stat_t struct, Ctimespec Timespec
pkg syscall (freebsd-arm), type Stat_t struct, Dev uint32
pkg syscall (freebsd-arm), type Stat_t struct, Gen uint32
pkg syscall (freebsd-arm), type Stat_t struct, Ino uint32
pkg syscall (freebsd-arm), type Stat_t struct, Lspare int32
pkg syscall (freebsd-arm), type Stat_t struct, Mtimespec Timespec
pkg syscall (freebsd-arm), type Stat_t struct, Nlink uint16
pkg syscall (freebsd-arm), type Stat_t struct, Rdev uint32
pkg syscall (freebsd-arm), type Statfs_t struct, Mntfromname [88]int8
pkg syscall (freebsd-arm), type Statfs_t struct, Mntonname [88]int8
pkg syscall (freebsd-arm-cgo), func Mknod(string, uint32, int) error
pkg syscall (freebsd-arm-cgo), type Dirent struct, Fileno uint32
pkg syscall (freebsd-arm-cgo), type Dirent struct, Namlen uint8
pkg syscall (freebsd-arm-cgo), type Stat_t struct, Atimespec Timespec
pkg syscall (freebsd-arm-cgo), type Stat_t struct, Birthtimespec Timespec
pkg syscall (freebsd-arm-cgo), type Stat_t struct, Blksize uint32
pkg syscall (freebsd-arm-cgo), type Stat_t struct, Ctimespec Timespec
pkg syscall (freebsd-arm-cgo), type Stat_t struct, Dev uint32
pkg syscall (freebsd-arm-cgo), type Stat_t struct, Gen uint32
pkg syscall (freebsd-arm-cgo), type Stat_t struct, Ino uint32
pkg syscall (freebsd-arm-cgo), type Stat_t struct, Lspare int32
pkg syscall (freebsd-arm-cgo), type Stat_t struct, Mtimespec Timespec
pkg syscall (freebsd-arm-cgo), type Stat_t struct, Nlink uint16
pkg syscall (freebsd-arm-cgo), type Stat_t struct, Rdev uint32
pkg syscall (freebsd-arm-cgo), type Statfs_t struct, Mntfromname [88]int8
pkg syscall (freebsd-arm-cgo), type Statfs_t struct, Mntonname [88]int8
4 changes: 2 additions & 2 deletions doc/docs.html
Expand Up @@ -50,10 +50,10 @@ <h3 id="go_tour">
online</a> or{{end}} install it locally with:
</p>
<pre>
$ go get golang.org/x/tour/gotour
$ go get golang.org/x/tour
</pre>
<p>
This will place the <code>gotour</code> binary in your workspace's <code>bin</code> directory.
This will place the <code>tour</code> binary in your workspace's <code>bin</code> directory.
</p>

<h3 id="code"><a href="code.html">How to write Go code</a></h3>
Expand Down
2 changes: 1 addition & 1 deletion doc/editors.html
Expand Up @@ -28,7 +28,7 @@ <h2 id="options">Options</h2>
</ul>

<p>
Note that these are only a few top solutions; a more comphensive
Note that these are only a few top solutions; a more comprehensive
community-maintained list of
<a href="https://github.com/golang/go/wiki/IDEsAndTextEditorPlugins">IDEs and text editor plugins</a>
is available at the Wiki.
Expand Down
10 changes: 5 additions & 5 deletions doc/effective_go.html
Expand Up @@ -1402,11 +1402,11 @@ <h3 id="slices">Slices</h3>
var err error
for i := 0; i &lt; 32; i++ {
nbytes, e := f.Read(buf[i:i+1]) // Read one byte.
n += nbytes
if nbytes == 0 || e != nil {
err = e
break
}
n += nbytes
}
</pre>
<p>
Expand Down Expand Up @@ -2762,15 +2762,15 @@ <h2 id="embedding">Embedding</h2>
}
</pre>
<p>
The <code>Job</code> type now has the <code>Log</code>, <code>Logf</code>
The <code>Job</code> type now has the <code>Print</code>, <code>Printf</code>, <code>Println</code>
and other
methods of <code>*log.Logger</code>. We could have given the <code>Logger</code>
a field name, of course, but it's not necessary to do so. And now, once
initialized, we can
log to the <code>Job</code>:
</p>
<pre>
job.Log("starting now...")
job.Println("starting now...")
</pre>
<p>
The <code>Logger</code> is a regular field of the <code>Job</code> struct,
Expand All @@ -2797,8 +2797,8 @@ <h2 id="embedding">Embedding</h2>
which would be useful if we wanted to refine the methods of <code>Logger</code>.
</p>
<pre>
func (job *Job) Logf(format string, args ...interface{}) {
job.Logger.Logf("%q: %s", job.Command, fmt.Sprintf(format, args...))
func (job *Job) Printf(format string, args ...interface{}) {
job.Logger.Printf("%q: %s", job.Command, fmt.Sprintf(format, args...))
}
</pre>
<p>
Expand Down
55 changes: 31 additions & 24 deletions doc/go_spec.html
@@ -1,6 +1,6 @@
<!--{
"Title": "The Go Programming Language Specification",
"Subtitle": "Version of September 24, 2018",
"Subtitle": "Version of October 23, 2018",
"Path": "/ref/spec"
}-->

Expand Down Expand Up @@ -811,7 +811,7 @@ <h3 id="Numeric_types">Numeric types</h3>
types</a> and thus distinct except
<code>byte</code>, which is an <a href="#Alias_declarations">alias</a> for <code>uint8</code>, and
<code>rune</code>, which is an alias for <code>int32</code>.
Conversions
Explicit conversions
are required when different numeric types are mixed in an expression
or assignment. For instance, <code>int32</code> and <code>int</code>
are not the same type even though they may have the same size on a
Expand Down Expand Up @@ -1348,7 +1348,7 @@ <h3 id="Channel_types">Channel types</h3>
The optional <code>&lt;-</code> operator specifies the channel <i>direction</i>,
<i>send</i> or <i>receive</i>. If no direction is given, the channel is
<i>bidirectional</i>.
A channel may be constrained only to send or only to receive by
A channel may be constrained only to send or only to receive by explicit
<a href="#Conversions">conversion</a> or <a href="#Assignments">assignment</a>.
</p>

Expand Down Expand Up @@ -2069,9 +2069,9 @@ <h3 id="Variable_declarations">Variable declarations</h3>
If a type is present, each variable is given that type.
Otherwise, each variable is given the type of the corresponding
initialization value in the assignment.
If that value is an untyped constant, it is first
If that value is an untyped constant, it is first implicitly
<a href="#Conversions">converted</a> to its <a href="#Constants">default type</a>;
if it is an untyped boolean value, it is first converted to type <code>bool</code>.
if it is an untyped boolean value, it is first implicitly converted to type <code>bool</code>.
The predeclared value <code>nil</code> cannot be used to initialize a variable
with no explicit type.
</p>
Expand Down Expand Up @@ -2202,11 +2202,11 @@ <h3 id="Method_declarations">Method declarations</h3>
<p>
The receiver is specified via an extra parameter section preceding the method
name. That parameter section must declare a single non-variadic parameter, the receiver.
Its type must be of the form <code>T</code> or <code>*T</code> (possibly using
parentheses) where <code>T</code> is a type name. The type denoted by <code>T</code> is called
the receiver <i>base type</i>; it must not be a pointer or interface type and
it must be <a href="#Type_definitions">defined</a> in the same package as the method.
The method is said to be <i>bound</i> to the base type and the method name
Its type must be a <a href="#Type_definitions">defined</a> type <code>T</code> or a
pointer to a defined type <code>T</code>. <code>T</code> is called the receiver
<i>base type</i>. A receiver base type cannot be a pointer or interface type and
it must be defined in the same package as the method.
The method is said to be <i>bound</i> to its receiver base type and the method name
is visible only within <a href="#Selectors">selectors</a> for type <code>T</code>
or <code>*T</code>.
</p>
Expand All @@ -2226,7 +2226,7 @@ <h3 id="Method_declarations">Method declarations</h3>
</p>

<p>
Given type <code>Point</code>, the declarations
Given defined type <code>Point</code>, the declarations
</p>

<pre>
Expand Down Expand Up @@ -3260,7 +3260,7 @@ <h3 id="Type_assertions">Type assertions</h3>
yields an additional untyped boolean value. The value of <code>ok</code> is <code>true</code>
if the assertion holds. Otherwise it is <code>false</code> and the value of <code>v</code> is
the <a href="#The_zero_value">zero value</a> for type <code>T</code>.
No run-time panic occurs in this case.
No <a href="#Run_time_panics">run-time panic</a> occurs in this case.
</p>


Expand Down Expand Up @@ -3433,7 +3433,7 @@ <h3 id="Operators">Operators</h3>

<p>
Except for shift operations, if one operand is an untyped <a href="#Constants">constant</a>
and the other operand is not, the constant is <a href="#Conversions">converted</a>
and the other operand is not, the constant is implicitly <a href="#Conversions">converted</a>
to the type of the other operand.
</p>

Expand All @@ -3442,7 +3442,7 @@ <h3 id="Operators">Operators</h3>
or be an untyped constant <a href="#Representability">representable</a> by a
value of type <code>uint</code>.
If the left operand of a non-constant shift expression is an untyped constant,
it is first converted to the type it would assume if the shift expression were
it is first implicitly converted to the type it would assume if the shift expression were
replaced by its left operand alone.
</p>

Expand Down Expand Up @@ -3624,7 +3624,7 @@ <h4 id="Integer_overflow">Integer overflow</h4>
<code>-</code>, <code>*</code>, <code>/</code>, and <code>&lt;&lt;</code> may legally
overflow and the resulting value exists and is deterministically defined
by the signed integer representation, the operation, and its operands.
No exception is raised as a result of overflow.
Overflow does not cause a <a href="#Run_time_panics">run-time panic</a>.
A compiler may not optimize code under the assumption that overflow does
not occur. For instance, it may not assume that <code>x &lt; x + 1</code> is always true.
</p>
Expand All @@ -3645,7 +3645,7 @@ <h4 id="Floating_point_operators">Floating-point operators</h4>
An implementation may combine multiple floating-point operations into a single
fused operation, possibly across statements, and produce a result that differs
from the value obtained by executing and rounding the instructions individually.
A floating-point type <a href="#Conversions">conversion</a> explicitly rounds to
An explicit floating-point type <a href="#Conversions">conversion</a> rounds to
the precision of the target type, preventing fusion that would discard that rounding.
</p>

Expand Down Expand Up @@ -3907,7 +3907,14 @@ <h3 id="Receive_operator">Receive operator</h3>
<h3 id="Conversions">Conversions</h3>

<p>
Conversions are expressions of the form <code>T(x)</code>
A conversion changes the <a href="#Types">type</a> of an expression
to the type specified by the conversion.
A conversion may appear literally in the source, or it may be <i>implied</i>
by the context in which an expression appears.
</p>

<p>
An <i>explicit</i> conversion is an expression of the form <code>T(x)</code>
where <code>T</code> is a type and <code>x</code> is an expression
that can be converted to type <code>T</code>.
</p>
Expand Down Expand Up @@ -3938,7 +3945,7 @@ <h3 id="Conversions">Conversions</h3>
A <a href="#Constants">constant</a> value <code>x</code> can be converted to
type <code>T</code> if <code>x</code> is <a href="#Representability">representable</a>
by a value of <code>T</code>.
As a special case, an integer constant <code>x</code> can be converted to a
As a special case, an integer constant <code>x</code> can be explicitly converted to a
<a href="#String_types">string type</a> using the
<a href="#Conversions_to_and_from_a_string_type">same rule</a>
as for non-constant <code>x</code>.
Expand Down Expand Up @@ -4672,13 +4679,13 @@ <h3 id="Assignments">Assignments</h3>
<li>
If an untyped constant
is assigned to a variable of interface type or the blank identifier,
the constant is first <a href="#Conversions">converted</a> to its
the constant is first implicitly <a href="#Conversions">converted</a> to its
<a href="#Constants">default type</a>.
</li>

<li>
If an untyped boolean value is assigned to a variable of interface type or
the blank identifier, it is first converted to type <code>bool</code>.
the blank identifier, it is first implicitly converted to type <code>bool</code>.
</li>
</ol>

Expand Down Expand Up @@ -4764,14 +4771,14 @@ <h4 id="Expression_switches">Expression switches</h4>
</pre>

<p>
If the switch expression evaluates to an untyped constant, it is first
If the switch expression evaluates to an untyped constant, it is first implicitly
<a href="#Conversions">converted</a> to its <a href="#Constants">default type</a>;
if it is an untyped boolean value, it is first converted to type <code>bool</code>.
if it is an untyped boolean value, it is first implicitly converted to type <code>bool</code>.
The predeclared untyped value <code>nil</code> cannot be used as a switch expression.
</p>

<p>
If a case expression is untyped, it is first <a href="#Conversions">converted</a>
If a case expression is untyped, it is first implicitly <a href="#Conversions">converted</a>
to the type of the switch expression.
For each (possibly converted) case expression <code>x</code> and the value <code>t</code>
of the switch expression, <code>x == t</code> must be a valid <a href="#Comparison_operators">comparison</a>.
Expand Down Expand Up @@ -5881,7 +5888,7 @@ <h3 id="Complex_numbers">Manipulating complex numbers</h3>
with the corresponding floating-point constituents:
<code>complex64</code> for <code>float32</code> arguments, and
<code>complex128</code> for <code>float64</code> arguments.
If one of the arguments evaluates to an untyped constant, it is first
If one of the arguments evaluates to an untyped constant, it is first implicitly
<a href="#Conversions">converted</a> to the type of the other argument.
If both arguments evaluate to untyped constants, they must be non-complex
numbers or their imaginary parts must be zero, and the return value of
Expand Down
5 changes: 5 additions & 0 deletions doc/help.html
Expand Up @@ -27,6 +27,11 @@ <h3 id="forum"><a href="https://forum.golangbridge.org/">Go Forum</a></h3>
forum for Go programmers.
</p>

<h3 id="discord"><a href="https://discord.gg/64C346U">Gophers Discord</a></h3>
<p>
Get live support and talk with other gophers on the Go Discord.
</p>

<h3 id="slack"><a href="https://blog.gopheracademy.com/gophers-slack-community/">Gopher Slack</a></h3>
<p>Get live support from other users in the Go slack channel.</p>

Expand Down
2 changes: 1 addition & 1 deletion misc/cgo/test/callback.go
Expand Up @@ -295,7 +295,7 @@ func goWithString(s string) {
}

func testCallbackStack(t *testing.T) {
// Make cgo call and callback with different amount of stack stack available.
// Make cgo call and callback with different amount of stack available.
// We do not do any explicit checks, just ensure that it does not crash.
for _, f := range splitTests {
f()
Expand Down
2 changes: 1 addition & 1 deletion misc/cgo/testplugin/unnamed1/main.go
Expand Up @@ -9,7 +9,7 @@ import "C"

func FuncInt() int { return 1 }

// Add a recursive type to to check that type equality across plugins doesn't
// Add a recursive type to check that type equality across plugins doesn't
// crash. See https://golang.org/issues/19258
func FuncRecursive() X { return X{} }

Expand Down
2 changes: 1 addition & 1 deletion misc/cgo/testsanitizers/cc_test.go
Expand Up @@ -374,7 +374,7 @@ func (c *config) checkRuntime() (skip bool, err error) {
}

// libcgo.h sets CGO_TSAN if it detects TSAN support in the C compiler.
// Dump the preprocessor defines to check that that works.
// Dump the preprocessor defines to check that works.
// (Sometimes it doesn't: see https://golang.org/issue/15983.)
cmd, err := cc(c.cFlags...)
if err != nil {
Expand Down

0 comments on commit 13bf5b8

Please sign in to comment.