Skip to content

Commit 4a65588

Browse files
committed
Ignore false positive free-nonheap-object warning
1 parent 80a5747 commit 4a65588

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

src_cpp/MPI1/MPI1_suite.cpp

+7
Original file line numberDiff line numberDiff line change
@@ -840,6 +840,10 @@ template <> void BenchmarkSuite<BS_MPI1>::get_bench_list(vector<string> &benchs,
840840
result.detach_ptr(); }
841841

842842

843+
#ifdef __GNUC__
844+
#pragma GCC diagnostic push
845+
#pragma GCC diagnostic ignored "-Wfree-nonheap-object"
846+
#endif
843847
template<> any BenchmarkSuite<BS_MPI1>::get_parameter(const std::string &key) {
844848
using namespace NS_MPI1;
845849
any result;
@@ -848,6 +852,9 @@ template<> any BenchmarkSuite<BS_MPI1>::get_parameter(const std::string &key) {
848852
HANDLE_PARAMETER(GLOBALS, glob);
849853
return result;
850854
}
855+
#ifdef __GNUC__
856+
#pragma GCC diagnostic pop
857+
#endif
851858

852859
#ifdef WIN32
853860
template BenchmarkSuite<BS_MPI1>;

0 commit comments

Comments
 (0)