]> Cypherpunks repositories - gostls13.git/commitdiff
exp/html: remove unused forTag function.
authorNigel Tao <nigeltao@golang.org>
Fri, 24 Aug 2012 04:15:55 +0000 (14:15 +1000)
committerNigel Tao <nigeltao@golang.org>
Fri, 24 Aug 2012 04:15:55 +0000 (14:15 +1000)
R=adg
CC=golang-dev
https://golang.org/cl/6480051

src/pkg/exp/html/node.go

index 65fa558b2487075b994b7965e8823dca9d3a0a42..46c21417d76727304d0cff1a2dabc769acef89a0 100644 (file)
@@ -146,16 +146,3 @@ func (s *nodeStack) remove(n *Node) {
        (*s)[j] = nil
        *s = (*s)[:j]
 }
-
-// TODO(nigeltao): forTag no longer used. Should it be deleted?
-
-// forTag returns the top-most element node with the given tag.
-func (s *nodeStack) forTag(tag string) *Node {
-       for i := len(*s) - 1; i >= 0; i-- {
-               n := (*s)[i]
-               if n.Type == ElementNode && n.Data == tag {
-                       return n
-               }
-       }
-       return nil
-}