[graph] Add a pre-alloc to map

This commit is contained in:
Behdad Esfahbod committed 2023-07-15 13:11:04 -06:00
1 parent d1ddfc4d10
commit 09706b04fc
1 file changed
+1
+1
View File
@@ -154,6 +154,7 @@ struct graph_t
{
hb_hashmap_t<unsigned, unsigned> result;
result.alloc (obj.real_links.length);
for (const auto& l : obj.real_links) {
result.set (l.position, l.objidx);
}