Dario Mariani - 2021-03-10

Ok, I have a quick hack but I'll see if I can clean and complete it. It
will take some time as it's not a critical issue for me right now.
Regards.

On Wed, Mar 10, 2021 at 8:34 AM Sylvain Bougerel sylvain.bougerel@gmail.com
wrote:

Hi Dario,

Thanks for the notification, I have not updated the library for a while
now, and I definitely should but do not have much time. Would you like to
do it?

Regards,
Sylvain

On Sat, Mar 6, 2021 at 11:07 PM Dario Mariani via Spatial-main spatial-main@lists.sourceforge.net wrote:


Status: open
Milestone: 2.1.9
Created: Sat Mar 06, 2021 03:07 PM UTC by Dario Mariani
Last Updated: Sat Mar 06, 2021 03:07 PM UTC
Owner: nobody

In std::allocator, the member rebind, construct and destroy were
deprecated in C++20 and other allocators are doing the same (e.g. Intel
OneTBB). A possible solution is:

  • typedef typename Alloc::template rebind- <kdtree_link<key, value=""> >::other Link_allocator;- typedef typename Alloc::template rebind- <value_type>::other Value_allocator;+ using Link_allocator = std::allocator_traits<alloc>::template rebind_alloc<kdtree_link<key, value="">>;+ using Value_allocator = std::allocator_traits<alloc>::template rebind_alloc<value_type>;</value_type></alloc></kdtree_link<key,></alloc></value_type></kdtree_link<key,>

and

  • get_value_allocator().construct(mutate_pointer(&safe.link->value),- value);+ Value_allocator v_alloc = get_value_allocator();+ std::allocator_traits<value_allocator>::construct(v_alloc, mutate_pointer(&safe.link->value), value);</value_allocator>

Sent from sourceforge.net because spatial-main@lists.sourceforge.net is
subscribed to https://sourceforge.net/p/spatial/tickets/

To unsubscribe from further messages, a project admin can change settings
at https://sourceforge.net/p/spatial/admin/tickets/options. Or, if this
is a mailing list, you can unsubscribe from the mailing list.


Spatial-main mailing list
Spatial-main@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/spatial-main

 

Related

Bug Report: #6