From 60a4faa5783f61288a249cb3115943a45be4e48d Mon Sep 17 00:00:00 2001 From: Valentin Shergin Date: Mon, 24 Sep 2018 12:54:24 -0700 Subject: [PATCH] Fabric: Proper includes in ContextContainer Summary: Trivial. Suddenly, compiler is unhappy without all proper headers. Reviewed By: mdvacca Differential Revision: D9884891 fbshipit-source-id: 7a5b175923f06bdb87bff8c9aad9f4ee40febbe9 --- ReactCommon/fabric/uimanager/ContextContainer.h | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/ReactCommon/fabric/uimanager/ContextContainer.h b/ReactCommon/fabric/uimanager/ContextContainer.h index d1a56454d3f..0b76b861be9 100644 --- a/ReactCommon/fabric/uimanager/ContextContainer.h +++ b/ReactCommon/fabric/uimanager/ContextContainer.h @@ -7,9 +7,11 @@ #include #include +#include #include #include #include +#include namespace facebook { namespace react { @@ -31,7 +33,7 @@ public: * by `{type, key}` pair. */ template - void registerInstance(const T &instance, const std::string &key = "") { + void registerInstance(const T &instance, const std::string &key = {}) { std::lock_guard lock(mutex_); instances_.insert({ @@ -46,7 +48,7 @@ public: * by {type, key} pair. */ template - T getInstance(const std::string &key = "") const { + T getInstance(const std::string &key = {}) const { std::lock_guard lock(mutex_); return *std::static_pointer_cast(instances_.at({std::type_index(typeid(T)), key}));