]> Cypherpunks repositories - gostls13.git/commitdiff
[dev.ssa] clarify ODCL todo, remove irrelevant colas todo
authorDaniel Morsing <daniel.morsing@gmail.com>
Thu, 11 Jun 2015 19:37:01 +0000 (20:37 +0100)
committerDaniel Morsing <daniel.morsing@gmail.com>
Fri, 12 Jun 2015 09:24:08 +0000 (09:24 +0000)
ODCL nodes are used as the point where the variable is allocated in
the old pass. colas is irrelevant at this point of the compile. All
the checks on it happen at parse time and an ODCL node will have been
inserted right before it.

Change-Id: I1aca053aaa4363bacd12e1156de86fa7b6190a55
Reviewed-on: https://go-review.googlesource.com/10901
Reviewed-by: Keith Randall <khr@golang.org>
src/cmd/compile/internal/gc/ssa.go

index b97764e0cf78e25c3d9c345475feca00f9287542..131e97ff48e604902ccdda50a6ae9742ddb6bbd2 100644 (file)
@@ -206,7 +206,8 @@ func (s *state) stmt(n *Node) {
                s.stmtList(n.List)
 
        case ODCL:
-               // TODO: ???  Assign 0?
+               // TODO: old gen pass uses dcl node as the point where
+               // escaping variables' new functions are called. Do that here
 
        case OLABEL, OGOTO:
                // get block at label, or make one
@@ -225,7 +226,6 @@ func (s *state) stmt(n *Node) {
                }
 
        case OAS, OASWB:
-               // TODO(khr): colas?
                // TODO: do write barrier
                var val *ssa.Value
                if n.Right == nil {