[all-commits] [llvm/llvm-project] 5c30a1: [mlir-c] Expose hard-failure state in 1:N type con...

Maksim Levental via All-commits all-commits at lists.llvm.org
Sat Jul 18 11:58:15 PDT 2026


  Branch: refs/heads/users/makslevental/mlir-c-typeconverter-1ton
  Home:   https://github.com/llvm/llvm-project
  Commit: 5c30a1e03b30af3853f61ca97b1dc710ce0ee971
      https://github.com/llvm/llvm-project/commit/5c30a1e03b30af3853f61ca97b1dc710ce0ee971
  Author: makslevental <maksim.levental at gmail.com>
  Date:   2026-07-18 (Sat, 18 Jul 2026)

  Changed paths:
    M mlir/include/mlir-c/Rewrite.h
    M mlir/lib/CAPI/Transforms/Rewrite.cpp
    M mlir/test/CAPI/rewrite.c

  Log Message:
  -----------
  [mlir-c] Expose hard-failure state in 1:N type conversion callback

The 1:N conversion callback returned MlirLogicalResult, which the binding
could only map to success or nullopt (try-another), leaving the C++
failure() state (fail without trying another conversion) unreachable.

Return a MlirTypeConverterConversionStatus enum instead, with Success,
Failure, and Declined states mapped to success(), failure(), and
std::nullopt respectively. Add a test covering the hard-failure path.



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