[Mlir-commits] [mlir] fb75afd - [mlir][support] Fix msvc build.

Michael Kruse llvmlistbot at llvm.org
Sun Mar 6 15:02:34 PST 2022


Author: Michael Kruse
Date: 2022-03-06T16:59:23-06:00
New Revision: fb75afd730fc43474dcfba68d718410226c662ac

URL: https://github.com/llvm/llvm-project/commit/fb75afd730fc43474dcfba68d718410226c662ac
DIFF: https://github.com/llvm/llvm-project/commit/fb75afd730fc43474dcfba68d718410226c662ac.diff

LOG: [mlir][support] Fix msvc build.

Add typename keyword to help the C++ parser to disambiguate dependent
qualified name after D120852/1c941d. Fixes the msvc build.

Added: 
    

Modified: 
    mlir/include/mlir/Support/DebugAction.h

Removed: 
    


################################################################################
diff  --git a/mlir/include/mlir/Support/DebugAction.h b/mlir/include/mlir/Support/DebugAction.h
index 82cd08ee72c34..ceb74fe5fd82e 100644
--- a/mlir/include/mlir/Support/DebugAction.h
+++ b/mlir/include/mlir/Support/DebugAction.h
@@ -194,7 +194,8 @@ template <typename... ParameterTs> class DebugAction {
   class Handler : public DebugActionManager::HandlerBase {
   public:
     Handler()
-        : HandlerBase(TypeID::get<DebugAction<ParameterTs...>::Handler>()) {}
+        : HandlerBase(
+              TypeID::get<typename DebugAction<ParameterTs...>::Handler>()) {}
 
     /// This hook allows for controlling whether an action should execute or
     /// not. `parameters` correspond to the set of values provided by the
@@ -207,7 +208,7 @@ template <typename... ParameterTs> class DebugAction {
     /// Provide classof to allow casting between handler types.
     static bool classof(const DebugActionManager::HandlerBase *handler) {
       return handler->getHandlerID() ==
-             TypeID::get<DebugAction<ParameterTs...>::Handler>();
+             TypeID::get<typename DebugAction<ParameterTs...>::Handler>();
     }
   };
 


        


More information about the Mlir-commits mailing list