code: func (g *Graph) flow() {
  	n := 0
  	var nod *Graph
  
  	for i := 0; i < g.Len(); i++ {
  
  		node := g.Out[i]
  		s := node.ThisString()
  
  		if s == TypeIf || s == TypeFor {
  			n++
  			if n == 1 {
  				nod = node.Add(TypeTemplate)
  				continue
  			}
  		}
  
  		if s == TypeElse {
  			if n == 1 {
  				nod.flow()
  				nod = node
  				continue
  			}
  		}
  
  		if s == TypeEnd {
  			n--
  			if n == 0 {
  				nod.flow()
  				g.DeleteAt(i)
  				i--
  				continue
  			}
  		}
  
  		if n > 0 {
  			nod.Add(node)
  			g.DeleteAt(i)
  			i--
  		}
  	}
  
  }
docs: // flow nests 'if' and 'for' loops.