]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
test/common/test_allocate_unique: drop hint parameter from allocate()
authorKefu Chai <tchaikov@gmail.com>
Thu, 3 Mar 2022 07:18:34 +0000 (15:18 +0800)
committerKefu Chai <tchaikov@gmail.com>
Sat, 30 Jul 2022 05:02:15 +0000 (13:02 +0800)
the "hint" parameter was dropped from C++20.

Signed-off-by: Kefu Chai <tchaikov@gmail.com>
src/test/common/test_allocate_unique.cc

index 09944951baa3e55573cb3407290e19e12bdb5f36..94cb025a49da331b36b59ce94c311f7e80615700 100644 (file)
@@ -38,9 +38,9 @@ struct logging_allocator {
   template <typename U>
   logging_allocator(const logging_allocator<U>& other) : log(other.log) {}
 
-  T* allocate(size_t n, const void* hint=0)
+  T* allocate(size_t n)
   {
-    auto p = std::allocator<T>{}.allocate(n, hint);
+    auto p = std::allocator<T>{}.allocate(n);
     log->emplace_back(event{n * sizeof(T), true});
     return p;
   }