Renames an imported operation in the global namespace. Args: old_name (str): The original name of the operation in the global namespace. new_name (str): The new name to be given to the operation. global_ns (dict): The global namespace where the operation is stored.
(old_name, new_name, global_ns)
| 49 | |
| 50 | |
| 51 | def rename_imported_op(old_name, new_name, global_ns): |
| 52 | """ |
| 53 | Renames an imported operation in the global namespace. |
| 54 | |
| 55 | Args: |
| 56 | old_name (str): The original name of the operation in the global namespace. |
| 57 | new_name (str): The new name to be given to the operation. |
| 58 | global_ns (dict): The global namespace where the operation is stored. |
| 59 | """ |
| 60 | if old_name not in global_ns: |
| 61 | return |
| 62 | global_ns[new_name] = global_ns[old_name] |
| 63 | del global_ns[old_name] |
| 64 | |
| 65 | |
| 66 | def wrap_unified_op(original_cpp_ext_op, original_custom_op): |
no outgoing calls
no test coverage detected