mirror of
https://github.com/wpilibsuite/allwpilib
synced 2026-06-27 02:01:42 +00:00
[wpiutil] Change StringExtras split() to template (#7636)
It now calls back a function for each part rather than creating a SmallVector.
This commit is contained in:
@@ -1015,7 +1015,8 @@ void NetworkTablesModel::RebuildTreeImpl(std::vector<TreeNode>* tree,
|
||||
continue;
|
||||
}
|
||||
parts.clear();
|
||||
wpi::split(entry->info.name, parts, '/', -1, false);
|
||||
wpi::split(entry->info.name, '/', -1, false,
|
||||
[&](auto part) { parts.emplace_back(part); });
|
||||
|
||||
// ignore a raw "/" key
|
||||
if (parts.empty()) {
|
||||
|
||||
Reference in New Issue
Block a user