[all-commits] [llvm/llvm-project] 1b3545: [mlir][irdl] Fix crash in TypeOp/AttributeOp verif...
Mehdi Amini via All-commits
all-commits at lists.llvm.org
Wed Mar 4 05:27:13 PST 2026
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: 1b3545117df0dfcea164d33a2432c66aa3b7f559
https://github.com/llvm/llvm-project/commit/1b3545117df0dfcea164d33a2432c66aa3b7f559
Author: Mehdi Amini <joker.eph at gmail.com>
Date: 2026-03-04 (Wed, 04 Mar 2026)
Changed paths:
M mlir/lib/Dialect/IRDL/IR/IRDL.cpp
M mlir/test/Dialect/IRDL/invalid_names.irdl.mlir
Log Message:
-----------
[mlir][irdl] Fix crash in TypeOp/AttributeOp verify on empty sym_name (#184598)
TypeOp::verify() and AttributeOp::verify() called StringRef::front() to
check for leading '\!' or '#' sigils before passing the name to
isValidName(). When sym_name is empty, front() triggers an assertion
failure:
Assertion `\!empty()' failed.
Fix: guard the front() calls with an emptiness check. An empty sym_name
then falls through to isValidName(), which already emits a proper
diagnostic:
error: name of type is empty
Fixes #159949
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