From: Ludovic Rousseau <rousseau@debian.org>
Subject: fix FTBFS #1143673
 Use the C++20 version of allocate()
Last-Update: 2026-08-23
Forwarded: https://github.com/libofx/libofx/pull/106

--- a/lib/tree.hh
+++ b/lib/tree.hh
@@ -467,8 +467,8 @@
 template <class T, class tree_node_allocator>
 void tree<T, tree_node_allocator>::head_initialise_()
 {
-  head = alloc_.allocate(1, 0); // MSVC does not have default second argument
-  feet = alloc_.allocate(1, 0);
+  head = alloc_.allocate(1);
+  feet = alloc_.allocate(1);
 
   head->parent = 0;
   head->first_child = 0;
@@ -743,7 +743,7 @@
 {
   assert(position.node != head);
 
-  tree_node* tmp = alloc_.allocate(1, 0);
+  tree_node* tmp = alloc_.allocate(1);
   kp::constructor(&tmp->data);
   tmp->first_child = 0;
   tmp->last_child = 0;
@@ -773,7 +773,7 @@
   // the API change.
   assert(position.node != head);
 
-  tree_node* tmp = alloc_.allocate(1, 0);
+  tree_node* tmp = alloc_.allocate(1);
   kp::constructor(&tmp->data, x);
   tmp->first_child = 0;
   tmp->last_child = 0;
@@ -833,7 +833,7 @@
     position.node = feet; // Backward compatibility: when calling insert on a null node,
     // insert before the feet.
   }
-  tree_node* tmp = alloc_.allocate(1, 0);
+  tree_node* tmp = alloc_.allocate(1);
   kp::constructor(&tmp->data, x);
   tmp->first_child = 0;
   tmp->last_child = 0;
@@ -856,7 +856,7 @@
 template <class T, class tree_node_allocator>
 typename tree<T, tree_node_allocator>::sibling_iterator tree<T, tree_node_allocator>::insert(sibling_iterator position, const T& x)
 {
-  tree_node* tmp = alloc_.allocate(1, 0);
+  tree_node* tmp = alloc_.allocate(1);
   kp::constructor(&tmp->data, x);
   tmp->first_child = 0;
   tmp->last_child = 0;
@@ -889,7 +889,7 @@
 template <class iter>
 iter tree<T, tree_node_allocator>::insert_after(iter position, const T& x)
 {
-  tree_node* tmp = alloc_.allocate(1, 0);
+  tree_node* tmp = alloc_.allocate(1);
   kp::constructor(&tmp->data, x);
   tmp->first_child = 0;
   tmp->last_child = 0;
@@ -951,7 +951,7 @@
 
   // replace the node at position with head of the replacement tree at from
   erase_children(position);
-  tree_node* tmp = alloc_.allocate(1, 0);
+  tree_node* tmp = alloc_.allocate(1);
   kp::constructor(&tmp->data, (*from));
   tmp->first_child = 0;
   tmp->last_child = 0;
