From bb1f9b23e7ff8b48153f486e24be2122a4604ac7 Mon Sep 17 00:00:00 2001 From: Valentin Shergin Date: Sun, 1 Dec 2019 19:21:29 -0800 Subject: [PATCH] Fabric: Using better::map instead of std::unordered_map in ShadowTreeRegistry Summary: Becasue better one is more efficient. Changelog: [Internal] Fabric-specific internal change. Reviewed By: sammy-SC Differential Revision: D18626666 fbshipit-source-id: 143dab1dd4c2e168368d2ca14bf2ffc8367d71ea --- ReactCommon/fabric/core/primitives/ReactPrimitives.h | 1 - ReactCommon/fabric/mounting/ShadowTreeRegistry.h | 3 ++- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/ReactCommon/fabric/core/primitives/ReactPrimitives.h b/ReactCommon/fabric/core/primitives/ReactPrimitives.h index 85bdb3a7d45..f38489dc3c7 100644 --- a/ReactCommon/fabric/core/primitives/ReactPrimitives.h +++ b/ReactCommon/fabric/core/primitives/ReactPrimitives.h @@ -12,7 +12,6 @@ #include #include #include -#include namespace facebook { namespace react { diff --git a/ReactCommon/fabric/mounting/ShadowTreeRegistry.h b/ReactCommon/fabric/mounting/ShadowTreeRegistry.h index 5fc69bb5d1f..4ccc306021f 100644 --- a/ReactCommon/fabric/mounting/ShadowTreeRegistry.h +++ b/ReactCommon/fabric/mounting/ShadowTreeRegistry.h @@ -7,6 +7,7 @@ #pragma once +#include #include #include @@ -60,7 +61,7 @@ class ShadowTreeRegistry final { private: mutable better::shared_mutex mutex_; - mutable std::unordered_map> + mutable better::map> registry_; // Protected by `mutex_`. };