Skip to content

Commit 16b4623

Browse files
committed
fix
1 parent dcd5e31 commit 16b4623

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

cpp/prtree.h

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1282,12 +1282,12 @@ class PRTree
12821282
vec<T> find(const BB<D> &target)
12831283
{
12841284
vec<T> out;
1285-
auto func = [&](std::unique_ptr<PRTreeLeaf<T, B, D>> &leaf)
1285+
auto find_func = [&](std::unique_ptr<PRTreeLeaf<T, B, D>> &leaf)
12861286
{
12871287
(*leaf)(target, out);
12881288
};
12891289

1290-
bfs<T, B, D>(func, flat_tree, target);
1290+
bfs<T, B, D>(std::move(find_func), flat_tree, target);
12911291
return out;
12921292
}
12931293

@@ -1300,12 +1300,12 @@ class PRTree
13001300
}
13011301
BB<D> target = it->second;
13021302

1303-
auto func = [&](std::unique_ptr<PRTreeLeaf<T, B, D>> &leaf)
1303+
auto erase_func = [&](std::unique_ptr<PRTreeLeaf<T, B, D>> &leaf)
13041304
{
13051305
leaf->del(idx, target);
13061306
};
13071307

1308-
bfs<T, B, D>(func, flat_tree, target);
1308+
bfs<T, B, D>(std::move(erase_func), flat_tree, target);
13091309

13101310
idx2bb.erase(idx);
13111311
idx2data.erase(idx);

0 commit comments

Comments
 (0)