From: Scott Snyder Date: Wed, 2 Dec 2020 14:42:56 +0000 (+0100) Subject: vec.h: Fix GCC build with -std=gnu++20 [PR98059] X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=bad800c03d00a57fc21718c160459d9a1e8d747a;p=gcc.git vec.h: Fix GCC build with -std=gnu++20 [PR98059] Apparently vec.h doesn't build with -std=c++20/gnu++20, since the DR2237 r11-532 change. template class auto_delete_vec { private: auto_vec_delete (const auto_delete_vec &) = delete; }; which vec.h uses is invalid C++20, one needs to use auto_vec_delete (const auto_delete_vec &) = delete; instead which is valid all the way back to C++11 (and without = delete to C++98). 2020-12-02 Scott Snyder PR plugins/98059 * vec.h (auto_delete_vec): Use DISABLE_COPY_AND_ASSIGN(auto_delete_vec) instead of DISABLE_COPY_AND_ASSIGN(auto_delete_vec) to make it valid C++20 after DR2237. --- diff --git a/gcc/vec.h b/gcc/vec.h index 14d77e87342..90904515ea0 100644 --- a/gcc/vec.h +++ b/gcc/vec.h @@ -1602,7 +1602,7 @@ class auto_delete_vec : public auto_vec ~auto_delete_vec (); private: - DISABLE_COPY_AND_ASSIGN(auto_delete_vec); + DISABLE_COPY_AND_ASSIGN(auto_delete_vec); }; /* Conditionally allocate heap memory for VEC and its internal vector. */