From: Jonathan Wakely Date: Thu, 20 Jun 2024 15:13:10 +0000 (+0100) Subject: libstdc++: Initialize base in test allocator's constructor X-Git-Tag: releases/gcc-12.5.0~506 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=595e3fa77115559343655cc0ab53cde5e4f82b86;p=thirdparty%2Fgcc.git libstdc++: Initialize base in test allocator's constructor This fixes a warning from one of the test allocators: warning: base class 'class std::allocator<__gnu_test::copy_tracker>' should be explicitly initialized in the copy constructor [-Wextra] libstdc++-v3/ChangeLog: * testsuite/util/testsuite_allocator.h (tracker_allocator): Initialize base class in copy constructor. (cherry picked from commit e2fb245b07f489ed5bfd9a945e0053b4a3211245) --- diff --git a/libstdc++-v3/testsuite/util/testsuite_allocator.h b/libstdc++-v3/testsuite/util/testsuite_allocator.h index 0c41181b4a5c..74eae87dbf67 100644 --- a/libstdc++-v3/testsuite/util/testsuite_allocator.h +++ b/libstdc++-v3/testsuite/util/testsuite_allocator.h @@ -154,7 +154,7 @@ namespace __gnu_test tracker_allocator() { } - tracker_allocator(const tracker_allocator&) + tracker_allocator(const tracker_allocator& a) : Alloc(a) { } ~tracker_allocator()