Skip to content

Commit 21adaf1

Browse files
committed
Update Node.jl
Define Base.copy for a node
1 parent 238a1be commit 21adaf1

1 file changed

Lines changed: 3 additions & 0 deletions

File tree

src/types/Node.jl

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -127,6 +127,9 @@ function Node(parent::Node{N,A}, MTG::T) where {N<:AbstractNodeMTG,A,T<:Abstract
127127
Node(parent, MTG, A())
128128
end
129129

130+
# Copying a node returns the node:
131+
Base.copy(node::Node) = node
132+
130133
## AbstractTrees compatibility:
131134

132135
# Set the methods for Node:

0 commit comments

Comments
 (0)