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/debug | |
parent | 8b4deb448e587802f67930b765c9598fc8cd36e5 (diff) | |
download | go-git-5fea2ccc77eb50a9704fa04b7c61755fe34e1d95.tar.gz |
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/debug')
-rw-r--r-- | src/debug/dwarf/buf.go | 6 | ||||
-rw-r--r-- | src/debug/dwarf/entry.go | 8 | ||||
-rw-r--r-- | src/debug/dwarf/open.go | 4 | ||||
-rw-r--r-- | src/debug/dwarf/type.go | 6 | ||||
-rw-r--r-- | src/debug/dwarf/type_test.go | 2 | ||||
-rw-r--r-- | src/debug/dwarf/typeunit.go | 4 | ||||
-rw-r--r-- | src/debug/elf/elf.go | 4 | ||||
-rw-r--r-- | src/debug/gosym/pclntab.go | 2 | ||||
-rw-r--r-- | src/debug/gosym/symtab.go | 6 |
9 files changed, 21 insertions, 21 deletions
diff --git a/src/debug/dwarf/buf.go b/src/debug/dwarf/buf.go index 98fe7a6ec6..7443043c11 100644 --- a/src/debug/dwarf/buf.go +++ b/src/debug/dwarf/buf.go @@ -22,16 +22,16 @@ type buf struct { err error } -// Data format, other than byte order. This affects the handling of +// Data format, other than byte order. This affects the handling of // certain field formats. type dataFormat interface { - // DWARF version number. Zero means unknown. + // DWARF version number. Zero means unknown. version() int // 64-bit DWARF format? dwarf64() (dwarf64 bool, isKnown bool) - // Size of an address, in bytes. Zero means unknown. + // Size of an address, in bytes. Zero means unknown. addrsize() int } diff --git a/src/debug/dwarf/entry.go b/src/debug/dwarf/entry.go index 5001bf85a2..6f72005e72 100644 --- a/src/debug/dwarf/entry.go +++ b/src/debug/dwarf/entry.go @@ -506,7 +506,7 @@ func (b *buf) entry(atab abbrevTable, ubase Offset) *Entry { } // A Reader allows reading Entry structures from a DWARF ``info'' section. -// The Entry structures are arranged in a tree. The Reader's Next function +// The Entry structures are arranged in a tree. The Reader's Next function // return successive entries from a pre-order traversal of the tree. // If an entry has children, its Children field will be true, and the children // follow, terminated by an Entry with Tag 0. @@ -598,7 +598,7 @@ func (r *Reader) Next() (*Entry, error) { } // SkipChildren skips over the child entries associated with -// the last Entry returned by Next. If that Entry did not have +// the last Entry returned by Next. If that Entry did not have // children or Next has not been called, SkipChildren is a no-op. func (r *Reader) SkipChildren() { if r.err != nil || !r.lastChildren { @@ -625,13 +625,13 @@ func (r *Reader) SkipChildren() { } } -// clone returns a copy of the reader. This is used by the typeReader +// clone returns a copy of the reader. This is used by the typeReader // interface. func (r *Reader) clone() typeReader { return r.d.Reader() } -// offset returns the current buffer offset. This is used by the +// offset returns the current buffer offset. This is used by the // typeReader interface. func (r *Reader) offset() Offset { return r.b.off diff --git a/src/debug/dwarf/open.go b/src/debug/dwarf/open.go index 7255195031..0e9c01c2e9 100644 --- a/src/debug/dwarf/open.go +++ b/src/debug/dwarf/open.go @@ -78,9 +78,9 @@ func New(abbrev, aranges, frame, info, line, pubnames, ranges, str []byte) (*Dat return d, nil } -// AddTypes will add one .debug_types section to the DWARF data. A +// AddTypes will add one .debug_types section to the DWARF data. A // typical object with DWARF version 4 debug info will have multiple -// .debug_types sections. The name is used for error reporting only, +// .debug_types sections. The name is used for error reporting only, // and serves to distinguish one .debug_types section from another. func (d *Data) AddTypes(name string, types []byte) error { return d.parseTypes(name, types) diff --git a/src/debug/dwarf/type.go b/src/debug/dwarf/type.go index e4dc6480d8..9b39078a6f 100644 --- a/src/debug/dwarf/type.go +++ b/src/debug/dwarf/type.go @@ -356,7 +356,7 @@ func (d *Data) readType(name string, r typeReader, off Offset, typeCache map[Off } // Get Type referred to by Entry's AttrType field. - // Set err if error happens. Not having a type is an error. + // Set err if error happens. Not having a type is an error. typeOf := func(e *Entry) Type { tval := e.Val(AttrType) var t Type @@ -549,7 +549,7 @@ func (d *Data) readType(name string, r typeReader, off Offset, typeCache map[Off bito = f.ByteOffset * 8 } if bito == lastFieldBitOffset && t.Kind != "union" { - // Last field was zero width. Fix array length. + // Last field was zero width. Fix array length. // (DWARF writes out 0-length arrays as if they were 1-length arrays.) zeroArray(lastFieldType) } @@ -560,7 +560,7 @@ func (d *Data) readType(name string, r typeReader, off Offset, typeCache map[Off if t.Kind != "union" { b, ok := e.Val(AttrByteSize).(int64) if ok && b*8 == lastFieldBitOffset { - // Final field must be zero width. Fix array length. + // Final field must be zero width. Fix array length. zeroArray(lastFieldType) } } diff --git a/src/debug/dwarf/type_test.go b/src/debug/dwarf/type_test.go index 2bd7a48961..0283466f08 100644 --- a/src/debug/dwarf/type_test.go +++ b/src/debug/dwarf/type_test.go @@ -34,7 +34,7 @@ var typedefTests = map[string]string{ } // As Apple converts gcc to a clang-based front end -// they keep breaking the DWARF output. This map lists the +// they keep breaking the DWARF output. This map lists the // conversion from real answer to Apple answer. var machoBug = map[string]string{ "func(*char, ...) void": "func(*char) void", diff --git a/src/debug/dwarf/typeunit.go b/src/debug/dwarf/typeunit.go index 4032cd4745..ed42547386 100644 --- a/src/debug/dwarf/typeunit.go +++ b/src/debug/dwarf/typeunit.go @@ -9,11 +9,11 @@ import ( "strconv" ) -// Parse the type units stored in a DWARF4 .debug_types section. Each +// Parse the type units stored in a DWARF4 .debug_types section. Each // type unit defines a single primary type and an 8-byte signature. // Other sections may then use formRefSig8 to refer to the type. -// The typeUnit format is a single type with a signature. It holds +// The typeUnit format is a single type with a signature. It holds // the same data as a compilation unit. type typeUnit struct { unit diff --git a/src/debug/elf/elf.go b/src/debug/elf/elf.go index f53ba0079a..613b8c501d 100644 --- a/src/debug/elf/elf.go +++ b/src/debug/elf/elf.go @@ -1896,7 +1896,7 @@ type Prog32 struct { Align uint32 /* Alignment in memory and file. */ } -// ELF32 Dynamic structure. The ".dynamic" section contains an array of them. +// ELF32 Dynamic structure. The ".dynamic" section contains an array of them. type Dyn32 struct { Tag int32 /* Entry type. */ Val uint32 /* Integer/Address value. */ @@ -1997,7 +1997,7 @@ type Prog64 struct { Align uint64 /* Alignment in memory and file. */ } -// ELF64 Dynamic structure. The ".dynamic" section contains an array of them. +// ELF64 Dynamic structure. The ".dynamic" section contains an array of them. type Dyn64 struct { Tag int64 /* Entry type. */ Val uint64 /* Integer/address value */ diff --git a/src/debug/gosym/pclntab.go b/src/debug/gosym/pclntab.go index 3aad41fe06..01a9f11f05 100644 --- a/src/debug/gosym/pclntab.go +++ b/src/debug/gosym/pclntab.go @@ -53,7 +53,7 @@ const oldQuantum = 1 func (t *LineTable) parse(targetPC uint64, targetLine int) (b []byte, pc uint64, line int) { // The PC/line table can be thought of as a sequence of // <pc update>* <line update> - // batches. Each update batch results in a (pc, line) pair, + // batches. Each update batch results in a (pc, line) pair, // where line applies to every PC from pc up to but not // including the pc of the next pair. // diff --git a/src/debug/gosym/symtab.go b/src/debug/gosym/symtab.go index aab53752ea..bde4cc7ac5 100644 --- a/src/debug/gosym/symtab.go +++ b/src/debug/gosym/symtab.go @@ -103,7 +103,7 @@ type Obj struct { * Symbol tables */ -// Table represents a Go symbol table. It stores all of the +// Table represents a Go symbol table. It stores all of the // symbols decoded from the program and provides methods to translate // between symbols, names, and addresses. type Table struct { @@ -353,7 +353,7 @@ func NewTable(symtab []byte, pcln *LineTable) (*Table, error) { } // Count text symbols and attach frame sizes, parameters, and - // locals to them. Also, find object file boundaries. + // locals to them. Also, find object file boundaries. lastf := 0 for i := 0; i < len(t.Syms); i++ { sym := &t.Syms[i] @@ -503,7 +503,7 @@ func (t *Table) PCToLine(pc uint64) (file string, line int, fn *Func) { } // LineToPC looks up the first program counter on the given line in -// the named file. It returns UnknownPathError or UnknownLineError if +// the named file. It returns UnknownPathError or UnknownLineError if // there is an error looking up this line. func (t *Table) LineToPC(file string, line int) (pc uint64, fn *Func, err error) { obj, ok := t.Files[file] |