[all-commits] [llvm/llvm-project] 25c523: assert with more information to help debug (#132194)

drazi via All-commits all-commits at lists.llvm.org
Wed May 28 21:14:58 PDT 2025


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 25c5235f30f22b9a95e440f16d1671970554df75
      https://github.com/llvm/llvm-project/commit/25c5235f30f22b9a95e440f16d1671970554df75
  Author: drazi <fengxie83 at gmail.com>
  Date:   2025-05-29 (Thu, 29 May 2025)

  Changed paths:
    M mlir/python/mlir/dialects/_ods_common.py

  Log Message:
  -----------
  assert with more information to help debug (#132194)

This PR output debug message to assertion to help debug user python
code. Will print out more friendly information

```
>           assert isinstance(arg, _cext.ir.Value), f"expects Value, got {type(arg)}"                                                          
E           AssertionError: expected Value, got <class 'UserDefinedClass'>       
```



To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications


More information about the All-commits mailing list