[Mlir-commits] [mlir] cb9f9df - [mlir] Fix GCC5 compilation problem in MLIR->LLVM type translation
Alex Zinenko
llvmlistbot at llvm.org
Tue Aug 4 05:43:37 PDT 2020
Author: Alex Zinenko
Date: 2020-08-04T14:42:17+02:00
New Revision: cb9f9df5f8239e291a62934b0f64eb795b26d84a
URL: https://github.com/llvm/llvm-project/commit/cb9f9df5f8239e291a62934b0f64eb795b26d84a
DIFF: https://github.com/llvm/llvm-project/commit/cb9f9df5f8239e291a62934b0f64eb795b26d84a.diff
LOG: [mlir] Fix GCC5 compilation problem in MLIR->LLVM type translation
GCC5 seems to dislike generic lambdas calling a method of the class
containing the lambda without explicit `this`.
Added:
Modified:
mlir/lib/Target/LLVMIR/TypeTranslation.cpp
Removed:
################################################################################
diff --git a/mlir/lib/Target/LLVMIR/TypeTranslation.cpp b/mlir/lib/Target/LLVMIR/TypeTranslation.cpp
index 15e0f158007a..b327e9ed8d2c 100644
--- a/mlir/lib/Target/LLVMIR/TypeTranslation.cpp
+++ b/mlir/lib/Target/LLVMIR/TypeTranslation.cpp
@@ -72,7 +72,7 @@ class TypeToLLVMIRTranslator {
LLVM::LLVMFunctionType, LLVM::LLVMPointerType,
LLVM::LLVMStructType, LLVM::LLVMFixedVectorType,
LLVM::LLVMScalableVectorType>(
- [this](auto array) { return translate(array); })
+ [this](auto type) { return this->translate(type); })
.Default([](LLVM::LLVMType t) -> llvm::Type * {
llvm_unreachable("unknown LLVM dialect type");
});
@@ -187,7 +187,7 @@ class TypeFromLLVMIRTranslator {
.Case<llvm::ArrayType, llvm::FunctionType, llvm::IntegerType,
llvm::PointerType, llvm::StructType, llvm::FixedVectorType,
llvm::ScalableVectorType>(
- [this](auto *type) { return translate(type); })
+ [this](auto *type) { return this->translate(type); })
.Default([this](llvm::Type *type) {
return translatePrimitiveType(type);
});
More information about the Mlir-commits
mailing list