Skip to content

Conversation

@laanwj
Copy link
Member

@laanwj laanwj commented Aug 20, 2014

Remove unused print()s and change the instance on CBlock to ToString().
Breaks dependency from core.o on util.o.

Before:

src/libbitcoin_common_a-core.o
  src/crypto/crypto_libbitcoin_crypto_a-sha2.o
    CSHA256::Reset(...)
    CSHA256::Write(...)
    CSHA256::Finalize(...)
    CSHA256::CSHA256(...)
  src/libbitcoin_common_a-script.o
    GetOpName(...)
  src/libbitcoin_util_a-uint256.o
    base_uint<256u>::EqualTo(...)
    base_uint<256u>::ToString(...)
  src/libbitcoin_util_a-util.o
    FormatMoney(...)
    LogPrintStr(...)
    LogAcceptCategory(...)

After:

src/libbitcoin_common_a-core.o
  src/crypto/crypto_libbitcoin_crypto_a-sha2.o
    CSHA256::Reset(...)
    CSHA256::Write(...)
    CSHA256::Finalize(...)
    CSHA256::CSHA256(...)
  src/libbitcoin_common_a-script.o
    GetOpName(...)
  src/libbitcoin_util_a-uint256.o
    base_uint<256u>::EqualTo(...)
    base_uint<256u>::ToString(...)

laanwj added 2 commits August 20, 2014 10:43
Break dependency on util.
This avoids a dependency on util.h if just tinyformat is needed.
@BitcoinPullTester
Copy link

Automatic sanity-testing: PASSED, see http://jenkins.bluematt.me/pull-tester/p4735_380222411038cb4f74cbb109984c4b855b4799f6/ for binaries and test log.
This test script verifies pulls every time they are updated. It, however, dies sometimes and fails to test properly. If you are waiting on a test, please check timestamps to verify that the test.log is moving at http://jenkins.bluematt.me/pull-tester/current/
Contact BlueMatt on freenode if something looks broken.

@TheBlueMatt
Copy link
Contributor

ut ACK

1 similar comment
@sipa
Copy link
Member

sipa commented Aug 20, 2014

ut ACK

@laanwj laanwj merged commit 3802224 into bitcoin:master Aug 21, 2014
laanwj added a commit that referenced this pull request Aug 21, 2014
3802224 Remove all other print() methods (Wladimir J. van der Laan)
9b6d4c5 Move strprintf define to tinyformat.h (Wladimir J. van der Laan)
8121258 Remove print() from core functions (Wladimir J. van der Laan)
@jgarzik
Copy link
Contributor

jgarzik commented Aug 21, 2014

posthumous ut ACK

laanwj added a commit to laanwj/bitcoin that referenced this pull request Jun 27, 2016
Updates `tinyformat.h` to commit
c42f/tinyformat@3a33bbf upstream.

Makes sure that our local changes are kept:

- bitcoin#3767 1b8fd35 Make tinyformat errors raise an exception instead of assert()ing
- bitcoin#4735 9b6d4c5 Move strprintf define to tinyformat.h
- bitcoin#4748 6e5fd00 include stdexcept (for std::exception)
- bitcoin#8000 9eaa0af force USE_VARIADIC_TEMPLATES
- Add `std::string format(const std::string &fmt...` added this
  at the time, as we want to be able to do `strprintf(_(...), ...)`

Inspired by bitcoin#8264.
@laanwj laanwj mentioned this pull request Jun 27, 2016
zkbot pushed a commit to zcash/zcash that referenced this pull request Oct 25, 2016
util: Update tinyformat

Updates `tinyformat.h` to commit
c42f/tinyformat@3a33bbf upstream.

Makes sure that our local changes are kept:

- bitcoin/bitcoin#3767 1b8fd35 Make tinyformat errors raise an exception instead of assert()ing
- bitcoin/bitcoin#4735 9b6d4c5 Move strprintf define to tinyformat.h
- bitcoin/bitcoin#4748 6e5fd00 include stdexcept (for std::exception)
- bitcoin/bitcoin#8000 9eaa0af force USE_VARIADIC_TEMPLATES
- Add `std::string format(const std::string &fmt...` added this
  at the time, as we want to be able to do `strprintf(_(...), ...)`

Inspired by bitcoin/bitcoin#8264.

For Zcash: ref #1349
protonn pushed a commit to argentumproject/argentum that referenced this pull request May 7, 2017
Updates `tinyformat.h` to commit
c42f/tinyformat@3a33bbf upstream.

Makes sure that our local changes are kept:

- bitcoin#3767 1b8fd35 Make tinyformat errors raise an exception instead of assert()ing
- bitcoin#4735 9b6d4c5 Move strprintf define to tinyformat.h
- bitcoin#4748 6e5fd00 include stdexcept (for std::exception)
- bitcoin#8000 9eaa0af force USE_VARIADIC_TEMPLATES
- Add `std::string format(const std::string &fmt...` added this
  at the time, as we want to be able to do `strprintf(_(...), ...)`

Inspired by bitcoin#8264.
lateminer pushed a commit to lateminer/bitcoin that referenced this pull request Jan 3, 2019
Updates `tinyformat.h` to commit
c42f/tinyformat@3a33bbf upstream.

Makes sure that our local changes are kept:

- bitcoin#3767 1b8fd35 Make tinyformat errors raise an exception instead of assert()ing
- bitcoin#4735 9b6d4c5 Move strprintf define to tinyformat.h
- bitcoin#4748 6e5fd00 include stdexcept (for std::exception)
- bitcoin#8000 9eaa0af force USE_VARIADIC_TEMPLATES
- Add `std::string format(const std::string &fmt...` added this
  at the time, as we want to be able to do `strprintf(_(...), ...)`

Inspired by bitcoin#8264.
@bitcoin bitcoin locked as resolved and limited conversation to collaborators Sep 8, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants