code: def visit_and_get_function_nodes(
          self,
          definition,
          first_node
      ):
          
          len_before_visiting_func = len(self.nodes)
          previous_node = self.nodes[-1]
          entry_node = self.append_node(EntryOrExitNode('Function Entry ' +
                                                        definition.name))
          if not first_node:
              first_node = entry_node
          self.connect_if_allowed(previous_node, entry_node)
  
          function_body_connect_statements = self.stmt_star_handler(definition.node.body)
          entry_node.connect(function_body_connect_statements.first_statement)
  
          exit_node = self.append_node(EntryOrExitNode('Exit ' + definition.name))
          exit_node.connect_predecessors(function_body_connect_statements.last_statements)
  
          the_new_nodes = self.nodes[len_before_visiting_func:]
          return_connection_handler(the_new_nodes, exit_node)
  
          return (the_new_nodes, first_node)
docs: Visits the nodes of a user defined function.
  
          Args:
              definition(LocalModuleDefinition): Definition of the function being added.
              first_node(EntryOrExitNode or None or RestoreNode): Used to connect previous statements to this function.
  
          Returns:
              the_new_nodes(list[Node]): The nodes added while visiting the function.
              first_node(EntryOrExitNode or None or RestoreNode): Used to connect previous statements to this function.