From 4145ad2bac4bb99d5034d60c74bb2789f6c6e802 Mon Sep 17 00:00:00 2001 From: paperchalice Date: Sat, 22 Jun 2024 17:59:30 +0800 Subject: [PATCH] [NewPM] Add deduction guide to `MFPropsModifier` to suppress warning (#96384) Buildbot `clang-ppc64le-rhel` failed with: ```sh error: 'MFPropsModifier' may not intend to support class template argument deduction [-Werror,-Wctad-maybe-unsupported] note: add a deduction guide to suppress this warning ``` after #94854. This PR adds deduction guide explicitly to suppress warning. --- llvm/include/llvm/CodeGen/MachinePassManager.h | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/llvm/include/llvm/CodeGen/MachinePassManager.h b/llvm/include/llvm/CodeGen/MachinePassManager.h index 8c4a70493383ad..253fabdac0019d 100644 --- a/llvm/include/llvm/CodeGen/MachinePassManager.h +++ b/llvm/include/llvm/CodeGen/MachinePassManager.h @@ -99,6 +99,10 @@ template class MFPropsModifier { is_detected::value; }; +// Additional deduction guide to suppress warning. +template +MFPropsModifier(PassT &P, MachineFunction &MF) -> MFPropsModifier; + using MachineFunctionAnalysisManagerModuleProxy = InnerAnalysisManagerProxy;