code: def parent_of(self, node):
          
          parent = node.parent
          while parent is not None:
              if self is parent:
                  return True
              parent = parent.parent
          return False
docs: Check if this node is the parent of the given node.
  
          :param node: The node to check if it is the child.
          :type node: NodeNG
  
          :returns: True if this node is the parent of the given node,
              False otherwise.
          :rtype: bool