From 2a0cfdb68e2c5482bceaff85925af1342b1ad253 Mon Sep 17 00:00:00 2001 From: xnpster Date: Wed, 18 Feb 2026 23:20:58 +0300 Subject: [PATCH] fix some compiler warnings --- src/Transformations/GlobalVariables/fix_common_blocks.cpp | 2 ++ src/Utils/module_utils.cpp | 2 +- src/Utils/module_utils.h | 2 +- src/Utils/utils.cpp | 4 ++-- 4 files changed, 6 insertions(+), 4 deletions(-) diff --git a/src/Transformations/GlobalVariables/fix_common_blocks.cpp b/src/Transformations/GlobalVariables/fix_common_blocks.cpp index cd3ce6e..80ce1ec 100644 --- a/src/Transformations/GlobalVariables/fix_common_blocks.cpp +++ b/src/Transformations/GlobalVariables/fix_common_blocks.cpp @@ -224,6 +224,8 @@ bool equalDims(const CommConstraint& a, const CommConstraint& b) if (adim[i].second - adim[i].first != bdim[i].second - bdim[i].first) return false; } + + return true; } diff --git a/src/Utils/module_utils.cpp b/src/Utils/module_utils.cpp index 9e72cff..df3479f 100644 --- a/src/Utils/module_utils.cpp +++ b/src/Utils/module_utils.cpp @@ -325,7 +325,7 @@ static void getModuleSymbols(SgStatement* func, set& symbs) } } -const set& getModuleSymbols(SgStatement *func) +set getModuleSymbols(SgStatement *func) { auto it = symbolsForFunc.find(func->symbol()->identifier()); if (it != symbolsForFunc.end()) diff --git a/src/Utils/module_utils.h b/src/Utils/module_utils.h index e78b8e5..dba36e9 100644 --- a/src/Utils/module_utils.h +++ b/src/Utils/module_utils.h @@ -1,7 +1,7 @@ #pragma once std::string correctSymbolModuleName(const std::string& origFull); -const std::set& getModuleSymbols(SgStatement* func); +std::set getModuleSymbols(SgStatement* func); void getModulesAndFunctions(SgFile* file, std::vector& modulesAndFunctions); void findModulesInFile(SgFile* file, std::vector& modules); std::map> createMapOfModuleUses(SgFile* file); diff --git a/src/Utils/utils.cpp b/src/Utils/utils.cpp index 08c0aed..ba5b520 100644 --- a/src/Utils/utils.cpp +++ b/src/Utils/utils.cpp @@ -569,8 +569,8 @@ void copyIncludes(const set &allIncludeFiles, const map