class_docstr: AST visitor that annotates each symbol name with its reaching definitions.
  
  Simultaneously, the visitor runs the dataflow analysis on each function node,
  accounting for the effect of closures. For example:
  
    def foo():
      bar = 1
      def baz():
        # bar = 1 reaches here
class_docstr_tok: ["AST","visitor","that","annotates","each","symbol","name","with","its","reaching","definitions",".","Simultaneously",",","the","visitor","runs","the","dataflow","analysis","on","each","function","node",",","accounting","for","the","effect","of","closures",".","For","example",":","def","foo","(",")",":","bar","=","1","def","baz","(",")",":","#","bar","=","1","reaches","here"]
code: def visit_Name(self, node):
      if self.current_analyzer is None:
          # Names may appear outside function defs - for example in class
          # definitions.
          return node
  
      analyzer = self.current_analyzer
      cfg_node = self.current_cfg_node
  
      assert cfg_node is not None, (
          "name node, %s, outside of any statement?" % node.id
      )
  
      qn = anno.getanno(node, anno.Basic.QN)
      if isinstance(node.ctx, gast.Load):
          anno.setanno(
              node,
              anno.Static.DEFINITIONS,
              tuple(analyzer.in_[cfg_node].value.get(qn, ())),
          )
      else:
          anno.setanno(
              node,
              anno.Static.DEFINITIONS,
              tuple(analyzer.out[cfg_node].value.get(qn, ())),
          )
  
      return node
  
imports: import weakref
  import gast
  from nvidia.dali._autograph.pyct import anno
  from nvidia.dali._autograph.pyct import cfg
  from nvidia.dali._autograph.pyct import transformer
label_desc: Use image node_id 3 for calling the TreeAnnotator obj's underlying member method code with example usage: obj.visit_Name(node) and returns: node, node