mirror of
https://github.com/golang/go
synced 2024-11-22 03:14:41 -07:00
exp/template: add missing dotNode case.
R=r CC=golang-dev https://golang.org/cl/4672044
This commit is contained in:
parent
9495dd31d2
commit
9d5ed1744a
@ -447,6 +447,8 @@ func (s *state) evalEmptyInterface(data reflect.Value, typ reflect.Type, n node)
|
|||||||
switch n := n.(type) {
|
switch n := n.(type) {
|
||||||
case *boolNode:
|
case *boolNode:
|
||||||
return reflect.ValueOf(n.true)
|
return reflect.ValueOf(n.true)
|
||||||
|
case *dotNode:
|
||||||
|
return data
|
||||||
case *fieldNode:
|
case *fieldNode:
|
||||||
return s.evalFieldNode(data, n, nil, reflect.Value{})
|
return s.evalFieldNode(data, n, nil, reflect.Value{})
|
||||||
case *identifierNode:
|
case *identifierNode:
|
||||||
|
Loading…
Reference in New Issue
Block a user