[flang-commits] [flang] e0fed04 - [Flang][OpenMP] Fix unused variable warning for task depend

Prabhdeep Singh Soni via flang-commits flang-commits at lists.llvm.org
Tue Jun 6 09:30:02 PDT 2023


Author: Prabhdeep Singh Soni
Date: 2023-06-06T12:29:42-04:00
New Revision: e0fed043662cb2410858ad82002f22e64ee552dd

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

LOG: [Flang][OpenMP] Fix unused variable warning for task depend

This patch fixes an unused variable warning that was caused by the task
depend patch.

Original Commit: 3373c8405c5e144567c2b25c28b54b4ac63b09b6

Original Differential Revision: https://reviews.llvm.org/D146766

Added: 
    

Modified: 
    flang/lib/Lower/OpenMP.cpp

Removed: 
    


################################################################################
diff  --git a/flang/lib/Lower/OpenMP.cpp b/flang/lib/Lower/OpenMP.cpp
index 94bd8fb4ed860..2a3fc19a5512a 100644
--- a/flang/lib/Lower/OpenMP.cpp
+++ b/flang/lib/Lower/OpenMP.cpp
@@ -1193,11 +1193,9 @@ genOMP(Fortran::lower::AbstractConverter &converter,
                   if (const Fortran::parser::Name *name =
                           std::get_if<Fortran::parser::Name>(&designator.u)) {
                     sym = name->symbol;
-                  } else if (const Fortran::common::Indirection<
-                                 Fortran::parser::ArrayElement> *a =
-                                 std::get_if<Fortran::common::Indirection<
-                                     Fortran::parser::ArrayElement>>(
-                                     &designator.u)) {
+                  } else if (std::get_if<Fortran::common::Indirection<
+                                 Fortran::parser::ArrayElement>>(
+                                 &designator.u)) {
                     TODO(converter.getCurrentLocation(),
                          "array sections not supported for task depend");
                   }


        


More information about the flang-commits mailing list