(fn: FuncIR)
| 131 | |
| 132 | |
| 133 | def assert_func_ir_valid(fn: FuncIR) -> None: |
| 134 | errors = check_func_ir(fn) |
| 135 | if errors: |
| 136 | raise IrCheckException( |
| 137 | "Internal error: Generated invalid IR: \n" |
| 138 | + "\n".join(format_func(fn, [(e.source, e.desc) for e in errors])) |
| 139 | ) |
| 140 | |
| 141 | |
| 142 | def check_op_sources_valid(fn: FuncIR) -> list[FnError]: |
searching dependent graphs…