XML:goPrev([name])

Move to the previous sibling element. Returns true on success or false otherwise. Does not move if there is no previous sibling element to move to. If the optional name is specified, move to the previous sibling element that has the given name, skipping over any elements that do not match the given name.

Example

doc = XML.parse(str)
doc:goPath('/foo/bar')
if doc:goPrev() then
    return doc:value()
end