22.1.2021, 9:00 - 11:00: Due to updates GitLab may be unavailable for some minutes between 09:00 and 11:00.

Commit 588474ca authored by eckhart's avatar eckhart

- cython compatibility restored

parent 7d533d69
......@@ -16,14 +16,14 @@ cdef class Node:
cpdef is_anonymous(self)
cpdef _content(self)
cpdef with_pos(self, pos)
cpdef has_attr(self)
# cpdef has_attr(self, attr)
# cpdef compare_attr(self, other)
# cpdef _tree_repr(self, tab, open_fn, close_fn, data_fn, density, inline, inline_fn)
# cpdef as_sxpr(self, src, indentation, compact)
# cpdef as_xml(self, src, indentation, inline_tags, omit_tags, empty_tags)
# cpdef select_if(self, match_function, include_root, reverse)
# cpdef select(self, tag_names, include_root)
cpdef pick(self, tag_names)
# cpdef pick(self, criterion, reverse)
# cpdef tree_size(self)
cpdef to_json_obj(self)
......@@ -614,8 +614,7 @@ class Node: # (collections.abc.Sized): Base class omitted for cython-compatibil
return self.select_if(create_match_function(criterion), include_root, reverse)
def pick(self, criterion: CriteriaType,
reverse: bool = False) -> Optional['Node']:
def pick(self, criterion: CriteriaType, reverse: bool = False) -> Optional['Node']:
Picks the first (or last if run in reverse mode) descendant that fulfills
the given criterion which can be either a match-function or a tag-name or
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment