]> Cypherpunks repositories - gostls13.git/commitdiff
cmd/compile: fix typos
authorwangyuntao <ytcoode@gmail.com>
Tue, 17 Aug 2021 03:24:15 +0000 (03:24 +0000)
committerIan Lance Taylor <iant@golang.org>
Tue, 17 Aug 2021 03:47:47 +0000 (03:47 +0000)
Change-Id: I88a3e69e232bf94296fe97621c5d395fc1296bbb
GitHub-Last-Rev: f1cc29dc287eb02881fead0b815e1b45e23adfa4
GitHub-Pull-Request: golang/go#47482
Reviewed-on: https://go-review.googlesource.com/c/go/+/338751
Reviewed-by: Matthew Dempsky <mdempsky@google.com>
Trust: Josh Bleecher Snyder <josharian@gmail.com>

src/cmd/compile/internal/escape/graph.go
src/cmd/compile/internal/ir/expr.go
src/cmd/compile/internal/ir/stmt.go

index d3ae1da693e5833de105eaf563d56878f5bb0dfe..cc3d078adddf8796349ab5aa813c81615450806b 100644 (file)
@@ -117,7 +117,7 @@ func (l *location) isName(c ir.Class) bool {
        return l.n != nil && l.n.Op() == ir.ONAME && l.n.(*ir.Name).Class == c
 }
 
-// An hole represents a context for evaluation a Go
+// A hole represents a context for evaluation of a Go
 // expression. E.g., when evaluating p in "x = **p", we'd have a hole
 // with dst==x and derefs==2.
 type hole struct {
index dc28483907a8120a44353ed75ebe7f138cd20526..f526d987a7b20e6318655445319c30a7a1cda058 100644 (file)
@@ -275,7 +275,7 @@ func (n *ConvExpr) SetOp(op Op) {
        }
 }
 
-// An IndexExpr is an index expression X[Y].
+// An IndexExpr is an index expression X[Index].
 type IndexExpr struct {
        miniExpr
        X        Node
index 8115012f97852c030d59b0e74bdd0cad17825916..69a74b9fdd6c402a7f6d619a18dde68df07fea8f 100644 (file)
@@ -244,7 +244,7 @@ func NewGoDeferStmt(pos src.XPos, op Op, call Node) *GoDeferStmt {
        return n
 }
 
-// A IfStmt is a return statement: if Init; Cond { Then } else { Else }.
+// An IfStmt is a return statement: if Init; Cond { Body } else { Else }.
 type IfStmt struct {
        miniStmt
        Cond   Node