<table border="1" cellspacing="0" cellpadding="8">
    <tr>
        <th>Issue</th>
        <td>
            <a href=https://github.com/llvm/llvm-project/issues/74162>74162</a>
        </td>
    </tr>

    <tr>
        <th>Summary</th>
        <td>
            [mlir][transform] Add expensive check to detect invalid API usage
        </td>
    </tr>

    <tr>
      <th>Labels</th>
      <td>
            mlir:transform_dialect
      </td>
    </tr>

    <tr>
      <th>Assignees</th>
      <td>
            matthias-springer
      </td>
    </tr>

    <tr>
      <th>Reporter</th>
      <td>
          matthias-springer
      </td>
    </tr>
</table>

<pre>
    #73961 removed the `cachedNames` check because it reported false positive. Find a safe way to implement such a check.

</pre>
<img width="1px" height="1px" alt="" src="http://email.email.llvm.org/o/eJxkkc2O1TAMhZ8m3VhTJU5_poss7uiqEhvEG6A0cdtA2lRxemHeHk25wIKVF5Y--3zHModlJzKifROImy1lDZZf-MhhXygLRNHeK3uWNWXz37qakn83AnWvh05Bpi09yENZCUQnnXUr-c92IxadBLeS-w4TOXsyQSiQ6Ui5kIfZRiY4EocSHlTDGHYPFtjOBD_sO5QEYTsibbQX4NOtYH_TaiHvQt4qb7Qf9GArMqqXqnlVsmur1ah-Qtf0TllynUc_K62w7xutCbHBoQoGJWqFEqXSfdPWg5fYvOrZtdhoGmbRSNpsiHWMj61OeakC80mmb1SHVbQTRf4jL4Ys9K1ku_Oc8vbVBxvJlafDbD4QL9O5sGhkDFz4H7SEEq8SLkh7F-3bX45o73DzHujnQTuHBz1NlgSeCrkCYX_YGDzcvnyCk-1C1ZmjWUs5WOibwFHguISynlPt0iZw_Lj7HC9HTt-uL8crGQscr3C_AgAA__-PjK-1">