]> git.ipfire.org Git - thirdparty/gcc.git/blobdiff - libstdc++-v3/testsuite/25_algorithms/minmax/3.cc
libstdc++: Add nodiscard in <algorithm>
[thirdparty/gcc.git] / libstdc++-v3 / testsuite / 25_algorithms / minmax / 3.cc
index 159421c17a466ca81ef957d8a188406632a8e3f2..a6620b9fa0d8acbc10a1ff8f6c4fdea6e2ed2082 100644 (file)
@@ -43,6 +43,7 @@ int compare_counter::count = 0;
 void test01()
 {
   std::minmax({1, 2, 3, 4, 5, 6, 7, 8}, compare_counter());
+  // { dg-warning "ignoring return value" "" { target c++17 } 45 }
 
   // If N is the number of arguments in the minmax function call, 
   // 25.3.7 specifies that at most 3N/2 comparisons are allowed.