def transform_Assign(self, stmt):
    # TODO: Allow possibility of indexing into variables that are read-only
    if stmt.lhs.__class__ is Var and stmt.rhs.__class__ is not Index:
      name = stmt.lhs.name
      if name in self.safe_to_move:
        deps = self.analysis.depends_on[name]

        if all(d in self.binding_depth for d in deps):
          if len(deps) > 0:
            target_level = max(self.binding_depth[d] for d in deps)
          else:
            target_level = 0
 
          if target_level >= 0 and target_level < self.blocks.depth():
            self.blocks._blocks[target_level].append(stmt)
            self.binding_depth[name] = target_level
            return None
    self.mark_binding_depths(collect_binding_names(stmt.lhs))
    return stmt
dataset/ETHPy150Open iskandr/parakeet/parakeet/transforms/licm.py/LoopInvariantCodeMotion.transform_Assign/original