aboutsummaryrefslogtreecommitdiff
path: root/src/runtime/cgo
diff options
context:
space:
mode:
authorBrad Fitzpatrick <bradfitz@golang.org>2016-03-01 23:21:55 +0000
committerBrad Fitzpatrick <bradfitz@golang.org>2016-03-02 00:13:47 +0000
commit5fea2ccc77eb50a9704fa04b7c61755fe34e1d95 (patch)
tree00137f90183ae2a01ca42249e04e9e4dabdf6249 /src/runtime/cgo
parent8b4deb448e587802f67930b765c9598fc8cd36e5 (diff)
downloadgo-5fea2ccc77eb50a9704fa04b7c61755fe34e1d95.tar.xz
all: single space after period.
The tree's pretty inconsistent about single space vs double space after a period in documentation. Make it consistently a single space, per earlier decisions. This means contributors won't be confused by misleading precedence. This CL doesn't use go/doc to parse. It only addresses // comments. It was generated with: $ perl -i -npe 's,^(\s*// .+[a-z]\.) +([A-Z]),$1 $2,' $(git grep -l -E '^\s*//(.+\.) +([A-Z])') $ go test go/doc -update Change-Id: Iccdb99c37c797ef1f804a94b22ba5ee4b500c4f7 Reviewed-on: https://go-review.googlesource.com/20022 Reviewed-by: Rob Pike <r@golang.org> Reviewed-by: Dave Day <djd@golang.org> Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org>
Diffstat (limited to 'src/runtime/cgo')
-rw-r--r--src/runtime/cgo/callbacks.go6
-rw-r--r--src/runtime/cgo/gcc_dragonfly_amd64.c6
-rw-r--r--src/runtime/cgo/gcc_freebsd_arm.c2
-rw-r--r--src/runtime/cgo/gcc_linux_386.c2
-rw-r--r--src/runtime/cgo/gcc_linux_arm.c2
-rw-r--r--src/runtime/cgo/gcc_linux_arm64.c2
-rw-r--r--src/runtime/cgo/gcc_netbsd_386.c6
-rw-r--r--src/runtime/cgo/gcc_netbsd_amd64.c6
-rw-r--r--src/runtime/cgo/gcc_netbsd_arm.c6
-rw-r--r--src/runtime/cgo/iscgo.go4
-rw-r--r--src/runtime/cgo/mmap.go4
11 files changed, 23 insertions, 23 deletions
diff --git a/src/runtime/cgo/callbacks.go b/src/runtime/cgo/callbacks.go
index eea0371c87..47bd2b0edc 100644
--- a/src/runtime/cgo/callbacks.go
+++ b/src/runtime/cgo/callbacks.go
@@ -22,7 +22,7 @@ func _runtime_cgocallback(unsafe.Pointer, unsafe.Pointer, uintptr)
//go:cgo_export_static crosscall2
//go:cgo_export_dynamic crosscall2
-// Panic. The argument is converted into a Go string.
+// Panic. The argument is converted into a Go string.
// Call like this in code compiled with gcc:
// struct { const char *p; } a;
@@ -69,7 +69,7 @@ var _cgo_thread_start = &x_cgo_thread_start
// Creates a new system thread without updating any Go state.
//
// This method is invoked during shared library loading to create a new OS
-// thread to perform the runtime initialization. This method is similar to
+// thread to perform the runtime initialization. This method is similar to
// _cgo_sys_thread_start except that it doesn't update any Go state.
//go:cgo_import_static x_cgo_sys_thread_create
@@ -82,7 +82,7 @@ var _cgo_sys_thread_create = &x_cgo_sys_thread_create
//
// We currently block at every CGO entry point (via _cgo_wait_runtime_init_done)
// to ensure that the runtime has been initialized before the CGO call is
-// executed. This is necessary for shared libraries where we kickoff runtime
+// executed. This is necessary for shared libraries where we kickoff runtime
// initialization in a separate thread and return without waiting for this
// thread to complete the init.
diff --git a/src/runtime/cgo/gcc_dragonfly_amd64.c b/src/runtime/cgo/gcc_dragonfly_amd64.c
index 5f26136916..85c53ca707 100644
--- a/src/runtime/cgo/gcc_dragonfly_amd64.c
+++ b/src/runtime/cgo/gcc_dragonfly_amd64.c
@@ -69,11 +69,11 @@ threadentry(void *v)
setg_gcc((void*)ts.g);
// On DragonFly, a new thread inherits the signal stack of the
- // creating thread. That confuses minit, so we remove that
- // signal stack here before calling the regular mstart. It's
+ // creating thread. That confuses minit, so we remove that
+ // signal stack here before calling the regular mstart. It's
// a bit baroque to remove a signal stack here only to add one
// in minit, but it's a simple change that keeps DragonFly
- // working like other OS's. At this point all signals are
+ // working like other OS's. At this point all signals are
// blocked, so there is no race.
memset(&ss, 0, sizeof ss);
ss.ss_flags = SS_DISABLE;
diff --git a/src/runtime/cgo/gcc_freebsd_arm.c b/src/runtime/cgo/gcc_freebsd_arm.c
index 8c294aa6d7..73f32792c5 100644
--- a/src/runtime/cgo/gcc_freebsd_arm.c
+++ b/src/runtime/cgo/gcc_freebsd_arm.c
@@ -53,7 +53,7 @@ _cgo_sys_thread_start(ThreadStart *ts)
// Not sure why the memset is necessary here,
// but without it, we get a bogus stack size
- // out of pthread_attr_getstacksize. C'est la Linux.
+ // out of pthread_attr_getstacksize. C'est la Linux.
memset(&attr, 0, sizeof attr);
pthread_attr_init(&attr);
size = 0;
diff --git a/src/runtime/cgo/gcc_linux_386.c b/src/runtime/cgo/gcc_linux_386.c
index 380441c0d4..15e0a8a302 100644
--- a/src/runtime/cgo/gcc_linux_386.c
+++ b/src/runtime/cgo/gcc_linux_386.c
@@ -48,7 +48,7 @@ _cgo_sys_thread_start(ThreadStart *ts)
// Not sure why the memset is necessary here,
// but without it, we get a bogus stack size
- // out of pthread_attr_getstacksize. C'est la Linux.
+ // out of pthread_attr_getstacksize. C'est la Linux.
memset(&attr, 0, sizeof attr);
pthread_attr_init(&attr);
size = 0;
diff --git a/src/runtime/cgo/gcc_linux_arm.c b/src/runtime/cgo/gcc_linux_arm.c
index fdcc343d19..f552421957 100644
--- a/src/runtime/cgo/gcc_linux_arm.c
+++ b/src/runtime/cgo/gcc_linux_arm.c
@@ -28,7 +28,7 @@ _cgo_sys_thread_start(ThreadStart *ts)
// Not sure why the memset is necessary here,
// but without it, we get a bogus stack size
- // out of pthread_attr_getstacksize. C'est la Linux.
+ // out of pthread_attr_getstacksize. C'est la Linux.
memset(&attr, 0, sizeof attr);
pthread_attr_init(&attr);
size = 0;
diff --git a/src/runtime/cgo/gcc_linux_arm64.c b/src/runtime/cgo/gcc_linux_arm64.c
index a7b5ddf5b6..84bd7c0b49 100644
--- a/src/runtime/cgo/gcc_linux_arm64.c
+++ b/src/runtime/cgo/gcc_linux_arm64.c
@@ -28,7 +28,7 @@ _cgo_sys_thread_start(ThreadStart *ts)
// Not sure why the memset is necessary here,
// but without it, we get a bogus stack size
- // out of pthread_attr_getstacksize. C'est la Linux.
+ // out of pthread_attr_getstacksize. C'est la Linux.
memset(&attr, 0, sizeof attr);
pthread_attr_init(&attr);
size = 0;
diff --git a/src/runtime/cgo/gcc_netbsd_386.c b/src/runtime/cgo/gcc_netbsd_386.c
index ba4fa6e425..32f2e15678 100644
--- a/src/runtime/cgo/gcc_netbsd_386.c
+++ b/src/runtime/cgo/gcc_netbsd_386.c
@@ -68,11 +68,11 @@ threadentry(void *v)
setg_gcc((void*)ts.g);
// On NetBSD, a new thread inherits the signal stack of the
- // creating thread. That confuses minit, so we remove that
- // signal stack here before calling the regular mstart. It's
+ // creating thread. That confuses minit, so we remove that
+ // signal stack here before calling the regular mstart. It's
// a bit baroque to remove a signal stack here only to add one
// in minit, but it's a simple change that keeps NetBSD
- // working like other OS's. At this point all signals are
+ // working like other OS's. At this point all signals are
// blocked, so there is no race.
memset(&ss, 0, sizeof ss);
ss.ss_flags = SS_DISABLE;
diff --git a/src/runtime/cgo/gcc_netbsd_amd64.c b/src/runtime/cgo/gcc_netbsd_amd64.c
index 035c4ff482..aa357459c7 100644
--- a/src/runtime/cgo/gcc_netbsd_amd64.c
+++ b/src/runtime/cgo/gcc_netbsd_amd64.c
@@ -69,11 +69,11 @@ threadentry(void *v)
setg_gcc((void*)ts.g);
// On NetBSD, a new thread inherits the signal stack of the
- // creating thread. That confuses minit, so we remove that
- // signal stack here before calling the regular mstart. It's
+ // creating thread. That confuses minit, so we remove that
+ // signal stack here before calling the regular mstart. It's
// a bit baroque to remove a signal stack here only to add one
// in minit, but it's a simple change that keeps NetBSD
- // working like other OS's. At this point all signals are
+ // working like other OS's. At this point all signals are
// blocked, so there is no race.
memset(&ss, 0, sizeof ss);
ss.ss_flags = SS_DISABLE;
diff --git a/src/runtime/cgo/gcc_netbsd_arm.c b/src/runtime/cgo/gcc_netbsd_arm.c
index 5b8553e830..9589780ac8 100644
--- a/src/runtime/cgo/gcc_netbsd_arm.c
+++ b/src/runtime/cgo/gcc_netbsd_arm.c
@@ -65,11 +65,11 @@ threadentry(void *v)
free(v);
// On NetBSD, a new thread inherits the signal stack of the
- // creating thread. That confuses minit, so we remove that
- // signal stack here before calling the regular mstart. It's
+ // creating thread. That confuses minit, so we remove that
+ // signal stack here before calling the regular mstart. It's
// a bit baroque to remove a signal stack here only to add one
// in minit, but it's a simple change that keeps NetBSD
- // working like other OS's. At this point all signals are
+ // working like other OS's. At this point all signals are
// blocked, so there is no race.
memset(&ss, 0, sizeof ss);
ss.ss_flags = SS_DISABLE;
diff --git a/src/runtime/cgo/iscgo.go b/src/runtime/cgo/iscgo.go
index 7604132170..e12d0f4b95 100644
--- a/src/runtime/cgo/iscgo.go
+++ b/src/runtime/cgo/iscgo.go
@@ -3,10 +3,10 @@
// license that can be found in the LICENSE file.
// The runtime package contains an uninitialized definition
-// for runtime·iscgo. Override it to tell the runtime we're here.
+// for runtime·iscgo. Override it to tell the runtime we're here.
// There are various function pointers that should be set too,
// but those depend on dynamic linker magic to get initialized
-// correctly, and sometimes they break. This variable is a
+// correctly, and sometimes they break. This variable is a
// backup: it depends only on old C style static linking rules.
package cgo
diff --git a/src/runtime/cgo/mmap.go b/src/runtime/cgo/mmap.go
index 6a4dc1562d..ff983599be 100644
--- a/src/runtime/cgo/mmap.go
+++ b/src/runtime/cgo/mmap.go
@@ -10,8 +10,8 @@ package cgo
import _ "unsafe"
// When using cgo, call the C library for mmap, so that we call into
-// any sanitizer interceptors. This supports using the memory
-// sanitizer with Go programs. The memory sanitizer only applies to
+// any sanitizer interceptors. This supports using the memory
+// sanitizer with Go programs. The memory sanitizer only applies to
// C/C++ code; this permits that code to see the Go code as normal
// program addresses that have been initialized.