mirror of
https://github.com/gohugoio/hugo.git
synced 2025-08-30 22:39:58 +02:00
@@ -217,7 +217,11 @@ func (p *PipeNode) writeTo(sb *strings.Builder) {
|
||||
}
|
||||
v.writeTo(sb)
|
||||
}
|
||||
sb.WriteString(" := ")
|
||||
if p.IsAssign {
|
||||
sb.WriteString(" = ")
|
||||
} else {
|
||||
sb.WriteString(" := ")
|
||||
}
|
||||
}
|
||||
for i, c := range p.Cmds {
|
||||
if i > 0 {
|
||||
@@ -346,12 +350,12 @@ type IdentifierNode struct {
|
||||
Ident string // The identifier's name.
|
||||
}
|
||||
|
||||
// NewIdentifier returns a new IdentifierNode with the given identifier name.
|
||||
// NewIdentifier returns a new [IdentifierNode] with the given identifier name.
|
||||
func NewIdentifier(ident string) *IdentifierNode {
|
||||
return &IdentifierNode{NodeType: NodeIdentifier, Ident: ident}
|
||||
}
|
||||
|
||||
// SetPos sets the position. NewIdentifier is a public method so we can't modify its signature.
|
||||
// SetPos sets the position. [NewIdentifier] is a public method so we can't modify its signature.
|
||||
// Chained for convenience.
|
||||
// TODO: fix one day?
|
||||
func (i *IdentifierNode) SetPos(pos Pos) *IdentifierNode {
|
||||
@@ -359,7 +363,7 @@ func (i *IdentifierNode) SetPos(pos Pos) *IdentifierNode {
|
||||
return i
|
||||
}
|
||||
|
||||
// SetTree sets the parent tree for the node. NewIdentifier is a public method so we can't modify its signature.
|
||||
// SetTree sets the parent tree for the node. [NewIdentifier] is a public method so we can't modify its signature.
|
||||
// Chained for convenience.
|
||||
// TODO: fix one day?
|
||||
func (i *IdentifierNode) SetTree(t *Tree) *IdentifierNode {
|
||||
|
Reference in New Issue
Block a user