mirror of
https://github.com/bitcoin/bitcoin.git
synced 2026-01-20 15:19:07 +01:00
scripted-diff: remove MakeUnique<T>()
-BEGIN VERIFY SCRIPT- git rm src/util/memory.h sed -i -e 's/MakeUnique/std::make_unique/g' $(git grep -l MakeUnique src) sed -i -e '/#include <util\/memory.h>/d' $(git grep -l '#include <util/memory.h>' src) sed -i -e '/util\/memory.h \\/d' src/Makefile.am -END VERIFY SCRIPT-
This commit is contained in:
@@ -1287,7 +1287,7 @@ CoinsViews::CoinsViews(
|
||||
|
||||
void CoinsViews::InitCache()
|
||||
{
|
||||
m_cacheview = MakeUnique<CCoinsViewCache>(&m_catcherview);
|
||||
m_cacheview = std::make_unique<CCoinsViewCache>(&m_catcherview);
|
||||
}
|
||||
|
||||
CChainState::CChainState(CTxMemPool& mempool, BlockManager& blockman, uint256 from_snapshot_blockhash)
|
||||
@@ -1305,7 +1305,7 @@ void CChainState::InitCoinsDB(
|
||||
leveldb_name += "_" + m_from_snapshot_blockhash.ToString();
|
||||
}
|
||||
|
||||
m_coins_views = MakeUnique<CoinsViews>(
|
||||
m_coins_views = std::make_unique<CoinsViews>(
|
||||
leveldb_name, cache_size_bytes, in_memory, should_wipe);
|
||||
}
|
||||
|
||||
@@ -5279,7 +5279,7 @@ bool ChainstateManager::ActivateSnapshot(
|
||||
static_cast<size_t>(current_coinsdb_cache_size * IBD_CACHE_PERC));
|
||||
}
|
||||
|
||||
auto snapshot_chainstate = WITH_LOCK(::cs_main, return MakeUnique<CChainState>(
|
||||
auto snapshot_chainstate = WITH_LOCK(::cs_main, return std::make_unique<CChainState>(
|
||||
this->ActiveChainstate().m_mempool, m_blockman, base_blockhash));
|
||||
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user