@@ -89,7 +89,7 @@ function prev(o::LazyNode)
8989 n. type === RawElementClose ? prev (LazyNode (n)) : LazyNode (n)
9090end
9191
92- # -----------------------------------------------------------------------------# Node
92+ # -----------------------------------------------------------------------------?de
9393"""
9494 Node(nodetype, tag, attributes, value, children)
9595 Node(node::Node; kw...) # copy node with keyword overrides
135135
136136Base. read (filename:: AbstractString , :: Type{Node} ) = Node (read (filename, Raw))
137137Base. read (io:: IO , :: Type{Node} ) = Node (read (io, Raw))
138- Base. parse (x:: AbstractString , :: Type{Node} = Node ) = Node (parse (x, Raw))
138+ Base. parse (x:: AbstractString , :: Type{Node} ) = Node (parse (x, Raw))
139139
140140Base. setindex! (o:: Node , val, i:: Integer ) = o. children[i] = Node (val)
141141Base. push! (a:: Node , b:: Node ) = push! (a. children, b)
210210Base.:(== )(a:: AbstractXMLNode , b:: AbstractXMLNode ) = nodes_equal (a, b)
211211
212212# -----------------------------------------------------------------------------# parse
213- Base. parse (:: Type{T} , str:: AbstractString ) where {T} = parse (str, T)
213+ Base. parse (:: Type{T} , str:: AbstractString ) where {T <: AbstractXMLNode } = parse (str, T)
214214
215215# -----------------------------------------------------------------------------# indexing
216216Base. getindex (o:: Union{Raw, AbstractXMLNode} ) = o
0 commit comments