Skip to content

Commit fd6afa3

Browse files
Mark Freemangopherbot
authored andcommitted
cmd/compile/internal/noder: mark Sync as a primitive
Sync is used in the definition of primitives and documented by pkgbits. It's not much help to also document it here. Change-Id: I18bd0c7816f8249483550a1f0af7c76b9cfe09fb Reviewed-on: https://go-review.googlesource.com/c/go/+/674156 Auto-Submit: Mark Freeman <mark@golang.org> Reviewed-by: Robert Griesemer <gri@google.com> TryBot-Bypass: Mark Freeman <mark@golang.org>
1 parent db95626 commit fd6afa3

File tree

1 file changed

+9
-8
lines changed
  • src/cmd/compile/internal/noder

1 file changed

+9
-8
lines changed

src/cmd/compile/internal/noder/doc.go

Lines changed: 9 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ The public root element identifies the package and provides references
6060
for all exported objects it contains.
6161
6262
PublicRoot = Relocs
63-
[ SyncPublic ] // TODO(markfreeman): Define.
63+
[ Sync ]
6464
PkgRef
6565
[ HasInit ]
6666
ObjectRefCount // TODO(markfreeman): Define.
@@ -80,7 +80,7 @@ directive). Every base has a position, line, and column; these are
8080
constant for file bases and hence not encoded.
8181
8282
PosBase = Relocs
83-
[ SyncPosBase ] // TODO(markfreeman): Define.
83+
[ Sync ]
8484
StringRef // the (absolute) file name for the base
8585
Bool // true if a file base, else a line base
8686
// The below is ommitted for file bases.
@@ -93,7 +93,7 @@ A source position Pos represents a file-absolute (line, column) pair
9393
and a PosBase indicating the position Pos is relative to. Positions
9494
without a PosBase have no line or column.
9595
96-
Pos = [ SyncPos ] // TODO(markfreeman): Define.
96+
Pos = [ Sync ]
9797
Bool // true if the position has a base
9898
// The below is ommitted if the position has no base.
9999
[ Ref[PosBase]
@@ -119,7 +119,7 @@ packages. The below package paths have special meaning.
119119
+--------------+-----------------------------------+
120120
121121
Pkg = Relocs
122-
[ SyncPkgDef ] // TODO(markfreeman): Define.
122+
[ Sync ]
123123
StringRef // path
124124
// The below is ommitted for the special package paths
125125
// "builtin" and "unsafe".
@@ -132,7 +132,7 @@ packages. The below package paths have special meaning.
132132
133133
Note, a PkgRef is *not* equivalent to Ref[Pkg] due to an extra marker.
134134
135-
PkgRef = [ SyncPkg ] // TODO(markfreeman): Define.
135+
PkgRef = [ Sync ]
136136
Ref[Pkg]
137137
.
138138
@@ -142,14 +142,14 @@ contains a section / index pair denoting the location of the referenced
142142
element.
143143
144144
// TODO(markfreeman): Rename to RefTable.
145-
Relocs = [ SyncRelocs ] // TODO(markfreeman): Define.
145+
Relocs = [ Sync ]
146146
RelocCount
147147
{ Reloc }
148148
.
149149
// TODO(markfreeman): Rename to RefTableEntryCount.
150150
RelocCount = Uint64 .
151151
// TODO(markfreeman): Rename to RefTableEntry.
152-
Reloc = [ SyncReloc ] // TODO(markfreeman): Define.
152+
Reloc = [ Sync ]
153153
SectionKind
154154
RelIndex
155155
.
@@ -158,7 +158,7 @@ Elements encode references to other elements as an index in the
158158
reference table — not the location of the referenced element directly.
159159
160160
// TODO(markfreeman): Rename to RefUse.
161-
UseReloc = [ SyncUseReloc ] // TODO(markfreeman): Define.
161+
UseReloc = [ Sync ]
162162
RelIndex
163163
.
164164
@@ -170,6 +170,7 @@ there for definitions of the below productions.
170170
* Int64
171171
* Uint64
172172
* String
173+
* Sync
173174
*/
174175

175176
package noder

0 commit comments

Comments
 (0)