2
0
mirror of https://github.com/AxioDL/metaforce.git synced 2025-12-09 16:27:42 +00:00

Merge pull request #14 from lioncash/emplace

General: Use emplace_back's return value where applicable
This commit is contained in:
2019-09-05 19:31:35 -07:00
committed by GitHub
5 changed files with 23 additions and 34 deletions

View File

@@ -335,8 +335,7 @@ void FileBrowser::FileListingDataBind::updateListing(const hecl::DirectoryEnumer
m_entries.reserve(dEnum.size());
for (const hecl::DirectoryEnumerator::Entry& d : dEnum) {
m_entries.emplace_back();
Entry& ent = m_entries.back();
Entry& ent = m_entries.emplace_back();
ent.m_path = d.m_path;
hecl::SystemUTF8Conv nameUtf8(d.m_name);
ent.m_name = nameUtf8.str();