class_docstr: Converts lists and related operations to their TF counterpart.
class_docstr_tok: ["Converts","lists","and","related","operations","to","their","TF","counterpart","."]
code: def _replace_pop_call(self, node):
      # Expressions that use pop() are converted to a statement + expression.
      #
      # For example:
      #
      #   print(target.pop())
      #
      # ... is converted to:
      #
      #   target, target_pop = ag__.list_pop(target)
      #   print(target_pop)
      #
      # Here, we just generate the variable name and swap it in,
      # and _generate_pop_operation will handle the rest.
      #
      # Multiple uses of pop() are allowed:
      #
      #   print(tartget.pop(), target.pop())
      #   print(tartget.pop().pop())
      #
      assert isinstance(node.func, gast.Attribute)
      scope = anno.getanno(node, NodeAnno.ARGS_SCOPE)
      target_node = node.func.value
  
      # Attempt to use a related name if one exists. Otherwise use something
      # generic.
      if anno.hasanno(target_node, anno.Basic.QN):
          target_name = anno.getanno(target_node, anno.Basic.QN).ssf()
      else:
          target_name = "list_"
      pop_var_name = self.ctx.namer.new_symbol(
          target_name, scope.referenced
      )
  
      stmt = self.state[_Statement]
      if stmt.pop_uses is None:
          stmt.pop_uses = []
      stmt.pop_uses.append((node, pop_var_name))
  
      return templates.replace_as_expression(
          "var_name", var_name=pop_var_name
      )
  
imports: import gast
  from tensorflow.python.autograph.core import converter
  from tensorflow.python.autograph.lang import directives
  from tensorflow.python.autograph.pyct import anno
  from tensorflow.python.autograph.pyct import parser
  from tensorflow.python.autograph.pyct import qual_names
  from tensorflow.python.autograph.pyct import templates
  from tensorflow.python.autograph.pyct.static_analysis import activity
  from tensorflow.python.autograph.pyct.static_analysis.annos import NodeAnno
label_desc: Use image node_id 3 for calling the ListTransformer obj's underlying member method code with example usage: obj._replace_pop_call(node) and returns: templates