Replace folly::make_unique with std::make_unique (#26730)

Summary:
There is a mixed usage of `folly::make_unique` and `std::make_unique`. Soon, `folly::make_unique` may be removed (see [this PR](https://github.com/facebook/folly/pull/1150)). Since `react-native` only supports C++14-compilers and later, switch to always using `std::make_unique`.

## Changelog

[Internal] [Removed] - Replace folly::make_unique with std::make_unique
Pull Request resolved: https://github.com/facebook/react-native/pull/26730

Test Plan:
Running the existing test suite. No change in behavior is expected.

Joshua Gross: buck install -r fb4a, make sure MP Home and forced teardown works okay on android

Reviewed By: shergin

Differential Revision: D18062400

Pulled By: JoshuaGross

fbshipit-source-id: 978ca794c7e972db872a8dcc57c31bdec7451481
This commit is contained in:
Joe Loser
2019-10-22 12:19:37 -07:00
committed by Facebook Github Bot
parent 468d1a2d2e
commit ba18ee9b87
20 changed files with 412 additions and 341 deletions
+3 -1
View File
@@ -16,6 +16,8 @@
#include <folly/portability/SysStat.h>
#include <folly/portability/Unistd.h>
#include <memory>
namespace facebook {
namespace react {
@@ -148,7 +150,7 @@ std::unique_ptr<const JSBigFileString> JSBigFileString::fromPath(
struct stat fileInfo;
folly::checkUnixError(::fstat(fd, &fileInfo), "fstat on bundle failed.");
return folly::make_unique<const JSBigFileString>(fd, fileInfo.st_size);
return std::make_unique<const JSBigFileString>(fd, fileInfo.st_size);
}
} // namespace react