From 2068f089c8b7b90eb4557d3f67ea0f0ed2059a23 Mon Sep 17 00:00:00 2001 From: Jim Posen Date: Mon, 22 Oct 2018 15:51:11 -0700 Subject: [PATCH] scripted-diff: Move util files to separate directory. -BEGIN VERIFY SCRIPT- mkdir -p src/util git mv src/util.h src/util/system.h git mv src/util.cpp src/util/system.cpp git mv src/utilmemory.h src/util/memory.h git mv src/utilmoneystr.h src/util/moneystr.h git mv src/utilmoneystr.cpp src/util/moneystr.cpp git mv src/utilstrencodings.h src/util/strencodings.h git mv src/utilstrencodings.cpp src/util/strencodings.cpp git mv src/utiltime.h src/util/time.h git mv src/utiltime.cpp src/util/time.cpp sed -i 's///g' $(git ls-files 'src/*.h' 'src/*.cpp') sed -i 's///g' $(git ls-files 'src/*.h' 'src/*.cpp') sed -i 's///g' $(git ls-files 'src/*.h' 'src/*.cpp') sed -i 's///g' $(git ls-files 'src/*.h' 'src/*.cpp') sed -i 's///g' $(git ls-files 'src/*.h' 'src/*.cpp') sed -i 's/BITCOIN_UTIL_H/BITCOIN_UTIL_SYSTEM_H/g' src/util/system.h sed -i 's/BITCOIN_UTILMEMORY_H/BITCOIN_UTIL_MEMORY_H/g' src/util/memory.h sed -i 's/BITCOIN_UTILMONEYSTR_H/BITCOIN_UTIL_MONEYSTR_H/g' src/util/moneystr.h sed -i 's/BITCOIN_UTILSTRENCODINGS_H/BITCOIN_UTIL_STRENCODINGS_H/g' src/util/strencodings.h sed -i 's/BITCOIN_UTILTIME_H/BITCOIN_UTIL_TIME_H/g' src/util/time.h sed -i 's/ util\.\(h\|cpp\)/ util\/system\.\1/g' src/Makefile.am sed -i 's/utilmemory\.\(h\|cpp\)/util\/memory\.\1/g' src/Makefile.am sed -i 's/utilmoneystr\.\(h\|cpp\)/util\/moneystr\.\1/g' src/Makefile.am sed -i 's/utilstrencodings\.\(h\|cpp\)/util\/strencodings\.\1/g' src/Makefile.am sed -i 's/utiltime\.\(h\|cpp\)/util\/time\.\1/g' src/Makefile.am sed -i 's/-> util ->/-> util\/system ->/' test/lint/lint-circular-dependencies.sh sed -i 's/src\/util\.cpp/src\/util\/system\.cpp/g' test/lint/lint-format-strings.py test/lint/lint-locale-dependence.sh sed -i 's/src\/utilmoneystr\.cpp/src\/util\/moneystr\.cpp/g' test/lint/lint-locale-dependence.sh sed -i 's/src\/utilstrencodings\.\(h\|cpp\)/src\/util\/strencodings\.\1/g' test/lint/lint-locale-dependence.sh sed -i 's/src\\utilstrencodings\.cpp/src\\util\\strencodings\.cpp/' build_msvc/libbitcoinconsensus/libbitcoinconsensus.vcxproj -END VERIFY SCRIPT- --- .../libbitcoinconsensus.vcxproj | 2 +- src/Makefile.am | 20 +++++++++---------- src/addrdb.cpp | 2 +- src/addrman.h | 2 +- src/arith_uint256.cpp | 2 +- src/base58.cpp | 2 +- src/bench/bech32.cpp | 2 +- src/bench/bench_bitcoin.cpp | 4 ++-- src/bench/block_assemble.cpp | 2 +- src/bench/checkqueue.cpp | 2 +- src/bench/crypto_hash.cpp | 2 +- src/bench/examples.cpp | 2 +- src/bitcoin-cli.cpp | 4 ++-- src/bitcoin-tx.cpp | 6 +++--- src/bitcoind.cpp | 4 ++-- src/blockencodings.cpp | 2 +- src/chainparams.cpp | 4 ++-- src/chainparamsbase.cpp | 4 ++-- src/consensus/merkle.cpp | 2 +- src/consensus/tx_verify.cpp | 2 +- src/core_read.cpp | 4 ++-- src/core_write.cpp | 6 +++--- src/dbwrapper.h | 4 ++-- src/dummywallet.cpp | 2 +- src/httprpc.cpp | 4 ++-- src/httpserver.cpp | 4 ++-- src/index/base.cpp | 2 +- src/index/txindex.cpp | 2 +- src/init.cpp | 4 ++-- src/init.h | 2 +- src/interfaces/handler.cpp | 2 +- src/interfaces/node.cpp | 2 +- src/key_io.cpp | 2 +- src/keystore.cpp | 2 +- src/logging.cpp | 2 +- src/merkleblock.cpp | 2 +- src/miner.cpp | 4 ++-- src/net.cpp | 2 +- src/net_processing.cpp | 6 +++--- src/netaddress.cpp | 2 +- src/netbase.cpp | 4 ++-- src/noui.cpp | 2 +- src/policy/fees.cpp | 2 +- src/policy/policy.cpp | 4 ++-- src/primitives/block.cpp | 2 +- src/primitives/transaction.cpp | 2 +- src/protocol.cpp | 4 ++-- src/qt/bantablemodel.cpp | 2 +- src/qt/bitcoin.cpp | 2 +- src/qt/bitcoingui.cpp | 2 +- src/qt/clientmodel.cpp | 2 +- src/qt/guiutil.cpp | 2 +- src/qt/intro.cpp | 2 +- src/qt/paymentrequestplus.cpp | 2 +- src/qt/paymentserver.cpp | 2 +- src/qt/rpcconsole.cpp | 2 +- src/qt/splashscreen.cpp | 2 +- src/qt/test/paymentservertests.cpp | 4 ++-- src/qt/test/rpcnestedtests.cpp | 2 +- src/qt/test/test_main.cpp | 2 +- src/qt/transactiondesc.cpp | 2 +- src/qt/transactiontablemodel.cpp | 2 +- src/qt/utilitydialog.cpp | 2 +- src/qt/walletmodel.cpp | 2 +- src/qt/winshutdownmonitor.cpp | 2 +- src/random.cpp | 4 ++-- src/rest.cpp | 2 +- src/rpc/blockchain.cpp | 4 ++-- src/rpc/client.cpp | 2 +- src/rpc/mining.cpp | 4 ++-- src/rpc/misc.cpp | 4 ++-- src/rpc/net.cpp | 4 ++-- src/rpc/protocol.cpp | 6 +++--- src/rpc/rawtransaction.cpp | 2 +- src/rpc/server.cpp | 4 ++-- src/rpc/util.cpp | 2 +- src/script/descriptor.cpp | 4 ++-- src/script/script.cpp | 2 +- src/script/sigcache.cpp | 2 +- src/script/standard.cpp | 4 ++-- src/sync.cpp | 2 +- src/test/allocator_tests.cpp | 2 +- src/test/base32_tests.cpp | 2 +- src/test/base58_tests.cpp | 2 +- src/test/base64_tests.cpp | 2 +- src/test/bip32_tests.cpp | 4 ++-- src/test/blockfilter_tests.cpp | 2 +- src/test/bloom_tests.cpp | 4 ++-- src/test/checkqueue_tests.cpp | 4 ++-- src/test/coins_tests.cpp | 2 +- src/test/compress_tests.cpp | 2 +- src/test/crypto_tests.cpp | 2 +- src/test/denialofservice_tests.cpp | 2 +- src/test/descriptor_tests.cpp | 2 +- src/test/getarg_tests.cpp | 2 +- src/test/hash_tests.cpp | 2 +- src/test/key_io_tests.cpp | 2 +- src/test/key_properties.cpp | 4 ++-- src/test/key_tests.cpp | 4 ++-- src/test/mempool_tests.cpp | 2 +- src/test/miner_tests.cpp | 4 ++-- src/test/net_tests.cpp | 2 +- src/test/netbase_tests.cpp | 2 +- src/test/policyestimator_tests.cpp | 2 +- src/test/pow_tests.cpp | 2 +- src/test/script_tests.cpp | 4 ++-- src/test/sighash_tests.cpp | 4 ++-- src/test/skiplist_tests.cpp | 2 +- src/test/transaction_tests.cpp | 2 +- src/test/txindex_tests.cpp | 4 ++-- src/test/txvalidationcache_tests.cpp | 2 +- src/test/util_tests.cpp | 6 +++--- src/timedata.cpp | 4 ++-- src/torcontrol.cpp | 4 ++-- src/txdb.cpp | 2 +- src/txmempool.cpp | 6 +++--- src/ui_interface.cpp | 2 +- src/uint256.cpp | 2 +- src/{utilmemory.h => util/memory.h} | 4 ++-- src/{utilmoneystr.cpp => util/moneystr.cpp} | 4 ++-- src/{utilmoneystr.h => util/moneystr.h} | 6 +++--- .../strencodings.cpp} | 2 +- .../strencodings.h} | 6 +++--- src/{util.cpp => util/system.cpp} | 4 ++-- src/{util.h => util/system.h} | 10 +++++----- src/{utiltime.cpp => util/time.cpp} | 2 +- src/{utiltime.h => util/time.h} | 6 +++--- src/validation.cpp | 6 +++--- src/validationinterface.cpp | 2 +- src/wallet/coincontrol.cpp | 2 +- src/wallet/coinselection.cpp | 4 ++-- src/wallet/crypter.cpp | 2 +- src/wallet/db.cpp | 2 +- src/wallet/db.h | 2 +- src/wallet/feebumper.cpp | 4 ++-- src/wallet/fees.cpp | 2 +- src/wallet/init.cpp | 4 ++-- src/wallet/rpcdump.cpp | 4 ++-- src/wallet/rpcwallet.cpp | 4 ++-- src/wallet/test/psbt_wallet_tests.cpp | 2 +- src/wallet/test/wallet_crypto_tests.cpp | 2 +- src/wallet/wallet.cpp | 2 +- src/wallet/wallet.h | 4 ++-- src/wallet/walletdb.cpp | 4 ++-- src/wallet/walletutil.cpp | 2 +- src/warnings.cpp | 2 +- src/zmq/zmqabstractnotifier.cpp | 2 +- src/zmq/zmqnotificationinterface.cpp | 2 +- src/zmq/zmqpublishnotifier.cpp | 2 +- test/lint/lint-circular-dependencies.sh | 2 +- test/lint/lint-format-strings.py | 4 ++-- test/lint/lint-locale-dependence.sh | 20 +++++++++---------- 152 files changed, 239 insertions(+), 239 deletions(-) rename src/{utilmemory.h => util/memory.h} (89%) rename src/{utilmoneystr.cpp => util/moneystr.cpp} (97%) rename src/{utilmoneystr.h => util/moneystr.h} (86%) rename src/{utilstrencodings.cpp => util/strencodings.cpp} (99%) rename src/{utilstrencodings.h => util/strencodings.h} (98%) rename src/{util.cpp => util/system.cpp} (99%) rename src/{util.h => util/system.h} (98%) rename src/{utiltime.cpp => util/time.cpp} (99%) rename src/{utiltime.h => util/time.h} (93%) diff --git a/build_msvc/libbitcoinconsensus/libbitcoinconsensus.vcxproj b/build_msvc/libbitcoinconsensus/libbitcoinconsensus.vcxproj index 0be7e7e43..2c6c0a8b7 100644 --- a/build_msvc/libbitcoinconsensus/libbitcoinconsensus.vcxproj +++ b/build_msvc/libbitcoinconsensus/libbitcoinconsensus.vcxproj @@ -40,7 +40,7 @@ - + diff --git a/src/Makefile.am b/src/Makefile.am index 614191900..703304ceb 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -183,10 +183,10 @@ BITCOIN_CORE_H = \ txmempool.h \ ui_interface.h \ undo.h \ - util.h \ - utilmemory.h \ - utilmoneystr.h \ - utiltime.h \ + util/system.h \ + util/memory.h \ + util/moneystr.h \ + util/time.h \ validation.h \ validationinterface.h \ versionbits.h \ @@ -377,8 +377,8 @@ libbitcoin_consensus_a_SOURCES = \ tinyformat.h \ uint256.cpp \ uint256.h \ - utilstrencodings.cpp \ - utilstrencodings.h \ + util/strencodings.cpp \ + util/strencodings.h \ version.h # common: shared between bitcoind, and bitcoin-qt and non-server tools @@ -427,10 +427,10 @@ libbitcoin_util_a_SOURCES = \ support/cleanse.cpp \ sync.cpp \ threadinterrupt.cpp \ - util.cpp \ - utilmoneystr.cpp \ - utilstrencodings.cpp \ - utiltime.cpp \ + util/system.cpp \ + util/moneystr.cpp \ + util/strencodings.cpp \ + util/time.cpp \ $(BITCOIN_CORE_H) if GLIBC_BACK_COMPAT diff --git a/src/addrdb.cpp b/src/addrdb.cpp index 3eae2b512..1590bce07 100644 --- a/src/addrdb.cpp +++ b/src/addrdb.cpp @@ -12,7 +12,7 @@ #include #include #include -#include +#include namespace { diff --git a/src/addrman.h b/src/addrman.h index 6d5780afa..b97feb6f0 100644 --- a/src/addrman.h +++ b/src/addrman.h @@ -11,7 +11,7 @@ #include #include #include -#include +#include #include #include diff --git a/src/arith_uint256.cpp b/src/arith_uint256.cpp index 791dad7a6..aa66d1310 100644 --- a/src/arith_uint256.cpp +++ b/src/arith_uint256.cpp @@ -6,7 +6,7 @@ #include #include -#include +#include #include #include diff --git a/src/base58.cpp b/src/base58.cpp index eac763394..e3d285339 100644 --- a/src/base58.cpp +++ b/src/base58.cpp @@ -6,7 +6,7 @@ #include #include -#include +#include #include #include diff --git a/src/bench/bech32.cpp b/src/bench/bech32.cpp index 8b80e1739..3c4b453a2 100644 --- a/src/bench/bech32.cpp +++ b/src/bench/bech32.cpp @@ -6,7 +6,7 @@ #include #include -#include +#include #include #include diff --git a/src/bench/bench_bitcoin.cpp b/src/bench/bench_bitcoin.cpp index 4fa516cb8..32faba86b 100644 --- a/src/bench/bench_bitcoin.cpp +++ b/src/bench/bench_bitcoin.cpp @@ -7,8 +7,8 @@ #include #include #include -#include -#include +#include +#include #include #include diff --git a/src/bench/block_assemble.cpp b/src/bench/block_assemble.cpp index bc99b8cdc..ac2299374 100644 --- a/src/bench/block_assemble.cpp +++ b/src/bench/block_assemble.cpp @@ -13,7 +13,7 @@ #include #include #include -#include +#include #include #include diff --git a/src/bench/checkqueue.cpp b/src/bench/checkqueue.cpp index 79689f6e0..6ab542067 100644 --- a/src/bench/checkqueue.cpp +++ b/src/bench/checkqueue.cpp @@ -3,7 +3,7 @@ // file COPYING or http://www.opensource.org/licenses/mit-license.php. #include -#include +#include #include #include #include diff --git a/src/bench/crypto_hash.cpp b/src/bench/crypto_hash.cpp index 5b0cf27e0..d7499a376 100644 --- a/src/bench/crypto_hash.cpp +++ b/src/bench/crypto_hash.cpp @@ -9,7 +9,7 @@ #include #include #include -#include +#include #include #include #include diff --git a/src/bench/examples.cpp b/src/bench/examples.cpp index 6d95e05ef..e7ddd5a93 100644 --- a/src/bench/examples.cpp +++ b/src/bench/examples.cpp @@ -4,7 +4,7 @@ #include #include -#include +#include // Sanity test: this should loop ten times, and // min/max/average should be close to 100ms. diff --git a/src/bitcoin-cli.cpp b/src/bitcoin-cli.cpp index f46650511..dc1b46faf 100644 --- a/src/bitcoin-cli.cpp +++ b/src/bitcoin-cli.cpp @@ -12,8 +12,8 @@ #include #include #include -#include -#include +#include +#include #include #include diff --git a/src/bitcoin-tx.cpp b/src/bitcoin-tx.cpp index 6d86581ac..bdc064b9f 100644 --- a/src/bitcoin-tx.cpp +++ b/src/bitcoin-tx.cpp @@ -18,9 +18,9 @@ #include