From ad549c067a5a5081e9f461ce7f375efbaaee122f Mon Sep 17 00:00:00 2001 From: Marc Horowitz Date: Wed, 1 Feb 2017 14:10:34 -0800 Subject: [PATCH] small fixes to ReactCommon Summary: unneeded or overly generic header files, stuff like that. Reviewed By: javache Differential Revision: D4434029 fbshipit-source-id: f25c702e7fc8d8debbd865cf3822696bf9b61c81 --- ReactCommon/cxxreact/JSCExecutor.cpp | 1 - ReactCommon/cxxreact/JSIndexedRAMBundle.cpp | 2 +- ReactCommon/cxxreact/JSIndexedRAMBundle.h | 4 ++-- ReactCommon/cxxreact/oss-compat-util.h | 4 ++-- ReactCommon/jschelpers/JSCHelpers.cpp | 1 - 5 files changed, 5 insertions(+), 7 deletions(-) diff --git a/ReactCommon/cxxreact/JSCExecutor.cpp b/ReactCommon/cxxreact/JSCExecutor.cpp index 14cd25664..532e3f57f 100644 --- a/ReactCommon/cxxreact/JSCExecutor.cpp +++ b/ReactCommon/cxxreact/JSCExecutor.cpp @@ -11,7 +11,6 @@ #include #include #include -#include #include #include #include diff --git a/ReactCommon/cxxreact/JSIndexedRAMBundle.cpp b/ReactCommon/cxxreact/JSIndexedRAMBundle.cpp index 80e528df4..282f2d91b 100644 --- a/ReactCommon/cxxreact/JSIndexedRAMBundle.cpp +++ b/ReactCommon/cxxreact/JSIndexedRAMBundle.cpp @@ -45,7 +45,7 @@ JSIndexedRAMBundle::Module JSIndexedRAMBundle::getModule(uint32_t moduleId) cons return ret; } -std::unique_ptr JSIndexedRAMBundle::getStartupCode() { +std::unique_ptr JSIndexedRAMBundle::getStartupCode() { CHECK(m_startupCode) << "startup code for a RAM Bundle can only be retrieved once"; return std::move(m_startupCode); } diff --git a/ReactCommon/cxxreact/JSIndexedRAMBundle.h b/ReactCommon/cxxreact/JSIndexedRAMBundle.h index 1a642ea1b..d243e6f70 100644 --- a/ReactCommon/cxxreact/JSIndexedRAMBundle.h +++ b/ReactCommon/cxxreact/JSIndexedRAMBundle.h @@ -21,7 +21,7 @@ public: JSIndexedRAMBundle(const char *sourceURL); // Throws std::runtime_error on failure. - std::unique_ptr getStartupCode(); + std::unique_ptr getStartupCode(); // Throws std::runtime_error on failure. Module getModule(uint32_t moduleId) const override; @@ -56,7 +56,7 @@ private: mutable std::ifstream m_bundle; ModuleTable m_table; size_t m_baseOffset; - std::unique_ptr m_startupCode; + std::unique_ptr m_startupCode; }; } // namespace react diff --git a/ReactCommon/cxxreact/oss-compat-util.h b/ReactCommon/cxxreact/oss-compat-util.h index 5c8f4fbd6..0f7127cb4 100644 --- a/ReactCommon/cxxreact/oss-compat-util.h +++ b/ReactCommon/cxxreact/oss-compat-util.h @@ -9,7 +9,7 @@ #define USE_FOLLY_FOR_TO_STRING 1 #elif defined(__has_include) #define USE_FOLLY_FOR_ENDIAN_SWAP __has_include() - #define USE_FOLLY_FOR_TO_STRING __has_include() + #define USE_FOLLY_FOR_TO_STRING __has_include() #else #define USE_FOLLY_FOR_ENDIAN_SWAP 0 #define USE_FOLLY_FOR_TO_STRING 0 @@ -23,7 +23,7 @@ #endif // USE_FOLLY_FOR_ENDIAN_SWAP #if USE_FOLLY_FOR_TO_STRING -#include +#include #else #include #include diff --git a/ReactCommon/jschelpers/JSCHelpers.cpp b/ReactCommon/jschelpers/JSCHelpers.cpp index db6609a91..975e12376 100644 --- a/ReactCommon/jschelpers/JSCHelpers.cpp +++ b/ReactCommon/jschelpers/JSCHelpers.cpp @@ -6,7 +6,6 @@ #include #endif -#include #include #include "JavaScriptCore.h"