[core] Switch to ankerl::unordered_dense

Signed-off-by: x7z4w <x7z4w@noreply.codeberg.org>
This commit is contained in:
x7z4w
2025-11-24 17:34:56 +00:00
parent 046fe903d1
commit b4e9bbb8d2
303 changed files with 4506 additions and 1577 deletions

View File

@@ -583,7 +583,8 @@ void Editor::UploadChanges(string const & oauthToken, ChangesetTags tags, Finish
}
std::unique_lock<std::mutex> uploadingEditsLock(m_uploadingEditsMutex, std::defer_lock);
if (!uploadingEditsLock.try_lock()) {
if (!uploadingEditsLock.try_lock())
{
// Do not run more than one uploading task at a time.
LOG(LDEBUG, ("OSM edits upload is already running"));
return;
@@ -630,8 +631,7 @@ void Editor::UploadChanges(string const & oauthToken, ChangesetTags tags, Finish
ASSERT(createEntry.journalEntryType == JournalEntryType::ObjectCreated,
("First item should have type ObjectCreated"));
ObjCreateData const & objCreateData = std::get<ObjCreateData>(createEntry.data);
XMLFeature feature =
editor::TypeToXML(objCreateData.type, objCreateData.geomType, objCreateData.mercator);
XMLFeature feature = editor::TypeToXML(objCreateData.type, objCreateData.geomType, objCreateData.mercator);
// Check if place already exists
bool mergeSameLocation = false;
@@ -982,7 +982,8 @@ void Editor::CreateNote(ms::LatLon const & latLon, FeatureID const & fid, featur
"but was not found on the ground.\n";
auto const features = m_features.Get();
auto const isCreated = GetFeatureStatusImpl(*features, fid.m_mwmId, fid.m_index) == FeatureStatus::Created;
auto const createdAndUploaded = (isCreated && AreSomeFeatureChangesUploadedImpl(*features, fid.m_mwmId, fid.m_index));
auto const createdAndUploaded =
(isCreated && AreSomeFeatureChangesUploadedImpl(*features, fid.m_mwmId, fid.m_index));
CHECK(!isCreated || createdAndUploaded, ());
if (createdAndUploaded)