[flang-commits] [flang] 625fc4b - [flang][NFC] Fix typo getFuncElementAttrName -> getFuncElementalAttrName (#95998)

via flang-commits flang-commits at lists.llvm.org
Tue Jun 18 15:03:11 PDT 2024


Author: Valentin Clement (バレンタイン クレメン)
Date: 2024-06-18T15:03:08-07:00
New Revision: 625fc4b3f2463355053f57baebc76a672935c50b

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

LOG: [flang][NFC] Fix typo getFuncElementAttrName -> getFuncElementalAttrName (#95998)

Fix type in the getter for the attribute name

Added: 
    

Modified: 
    flang/include/flang/Optimizer/Dialect/FIROpsSupport.h
    flang/lib/Lower/CallInterface.cpp

Removed: 
    


################################################################################
diff  --git a/flang/include/flang/Optimizer/Dialect/FIROpsSupport.h b/flang/include/flang/Optimizer/Dialect/FIROpsSupport.h
index 116c1dfea51b4..50e18792a167a 100644
--- a/flang/include/flang/Optimizer/Dialect/FIROpsSupport.h
+++ b/flang/include/flang/Optimizer/Dialect/FIROpsSupport.h
@@ -152,7 +152,7 @@ static constexpr llvm::StringRef getFuncPureAttrName() {
   return "fir.func_pure";
 }
 
-static constexpr llvm::StringRef getFuncElementAttrName() {
+static constexpr llvm::StringRef getFuncElementalAttrName() {
   return "fir.func_elemental";
 }
 

diff  --git a/flang/lib/Lower/CallInterface.cpp b/flang/lib/Lower/CallInterface.cpp
index 75a86273250d1..30f985804d2ae 100644
--- a/flang/lib/Lower/CallInterface.cpp
+++ b/flang/lib/Lower/CallInterface.cpp
@@ -615,7 +615,7 @@ static void addSymbolAttribute(mlir::func::FuncOp func,
     func->setAttr(fir::getFuncPureAttrName(),
                   mlir::UnitAttr::get(&mlirContext));
   if (IsElementalProcedure(sym))
-    func->setAttr(fir::getFuncElementAttrName(),
+    func->setAttr(fir::getFuncElementalAttrName(),
                   mlir::UnitAttr::get(&mlirContext));
   if (sym.attrs().test(Fortran::semantics::Attr::RECURSIVE))
     func->setAttr(fir::getFuncRecursiveAttrName(),


        


More information about the flang-commits mailing list