[llvm] [PatternMatch] Add support for capture-and-match (NFC) (PR #149825)
Nikita Popov via llvm-commits
llvm-commits at lists.llvm.org
Tue Jul 22 01:00:36 PDT 2025
================
@@ -822,12 +822,47 @@ template <typename Class> struct bind_ty {
}
};
+template <typename Class, typename MatchTy> struct bind_and_match_ty {
----------------
nikic wrote:
Hm, that should work, though with slightly different behavior: For `m_Instruction(I, m_XYZ)` the current implementation will not execute `m_XYZ` if the value is not an `Instruction`. If `m_CombineAnd` is used it would be executed.
https://github.com/llvm/llvm-project/pull/149825
More information about the llvm-commits
mailing list