diff options
author | Brad Fitzpatrick <bradfitz@golang.org> | 2016-03-01 23:21:55 +0000 |
---|---|---|
committer | Brad Fitzpatrick <bradfitz@golang.org> | 2016-03-02 00:13:47 +0000 |
commit | 5fea2ccc77eb50a9704fa04b7c61755fe34e1d95 (patch) | |
tree | 00137f90183ae2a01ca42249e04e9e4dabdf6249 /src/log | |
parent | 8b4deb448e587802f67930b765c9598fc8cd36e5 (diff) | |
download | go-5fea2ccc77eb50a9704fa04b7c61755fe34e1d95.tar.gz go-5fea2ccc77eb50a9704fa04b7c61755fe34e1d95.zip |
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/log')
-rw-r--r-- | src/log/log.go | 18 | ||||
-rw-r--r-- | src/log/syslog/syslog.go | 8 |
2 files changed, 13 insertions, 13 deletions
diff --git a/src/log/log.go b/src/log/log.go index 4cfe550300..26cdb532df 100644 --- a/src/log/log.go +++ b/src/log/log.go @@ -42,8 +42,8 @@ const ( ) // A Logger represents an active logging object that generates lines of -// output to an io.Writer. Each logging operation makes a single call to -// the Writer's Write method. A Logger can be used simultaneously from +// output to an io.Writer. Each logging operation makes a single call to +// the Writer's Write method. A Logger can be used simultaneously from // multiple goroutines; it guarantees to serialize access to the Writer. type Logger struct { mu sync.Mutex // ensures atomic writes; protects the following fields @@ -53,7 +53,7 @@ type Logger struct { buf []byte // for accumulating text to write } -// New creates a new Logger. The out variable sets the +// New creates a new Logger. The out variable sets the // destination to which log data will be written. // The prefix appears at the beginning of each generated log line. // The flag argument defines the logging properties. @@ -134,10 +134,10 @@ func (l *Logger) formatHeader(buf *[]byte, t time.Time, file string, line int) { } } -// Output writes the output for a logging event. The string s contains +// Output writes the output for a logging event. The string s contains // the text to print after the prefix specified by the flags of the -// Logger. A newline is appended if the last character of s is not -// already a newline. Calldepth is used to recover the PC and is +// Logger. A newline is appended if the last character of s is not +// already a newline. Calldepth is used to recover the PC and is // provided for generality, although at the moment on all pre-defined // paths it will be 2. func (l *Logger) Output(calldepth int, s string) error { @@ -334,10 +334,10 @@ func Panicln(v ...interface{}) { panic(s) } -// Output writes the output for a logging event. The string s contains +// Output writes the output for a logging event. The string s contains // the text to print after the prefix specified by the flags of the -// Logger. A newline is appended if the last character of s is not -// already a newline. Calldepth is the count of the number of +// Logger. A newline is appended if the last character of s is not +// already a newline. Calldepth is the count of the number of // frames to skip when computing the file name and line number // if Llongfile or Lshortfile is set; a value of 1 will print the details // for the caller of Output. diff --git a/src/log/syslog/syslog.go b/src/log/syslog/syslog.go index f489059d5a..9e888dd1d9 100644 --- a/src/log/syslog/syslog.go +++ b/src/log/syslog/syslog.go @@ -85,8 +85,8 @@ type Writer struct { } // This interface and the separate syslog_unix.go file exist for -// Solaris support as implemented by gccgo. On Solaris you cannot -// simply open a TCP connection to the syslog daemon. The gccgo +// Solaris support as implemented by gccgo. On Solaris you cannot +// simply open a TCP connection to the syslog daemon. The gccgo // sources have a syslog_solaris.go file that implements unixSyslog to // return a type that satisfies this interface and simply calls the C // library syslog function. @@ -100,7 +100,7 @@ type netConn struct { conn net.Conn } -// New establishes a new connection to the system log daemon. Each +// New establishes a new connection to the system log daemon. Each // write to the returned writer sends a log message with the given // priority and prefix. func New(priority Priority, tag string) (*Writer, error) { @@ -108,7 +108,7 @@ func New(priority Priority, tag string) (*Writer, error) { } // Dial establishes a connection to a log daemon by connecting to -// address raddr on the specified network. Each write to the returned +// address raddr on the specified network. Each write to the returned // writer sends a log message with the given facility, severity and // tag. // If network is empty, Dial will connect to the local syslog server. |