remove unneeded cast in rpcmisc.cpp #4882

pull Diapolo wants to merge 1 commits into bitcoin:master from Diapolo:rem_cast changing 1 files +2 −2
  1. Diapolo commented at 8:10 AM on September 9, 2014: none

    No description provided.

  2. sipa commented at 2:37 PM on September 9, 2014: member

    Untested ACK, but you have 2 typo's in the commit/pull title :)

  3. laanwj commented at 3:45 PM on September 9, 2014: member

    Why were these added in the first place? Sometimes I have the feelling that we're adding, removing, re-adding these all the time.

  4. sipa commented at 4:01 PM on September 9, 2014: member

    @laanwj Seems the getinfo() function was moved four times, with some small modifications etc,... git blame digging eventually leads me to 69d605f4... but that seems a dead end.

  5. remove unneeded cast in rpcmisc.cpp faadbe1733
  6. Diapolo renamed this:
    remove unneded cast in pcmisc.cpp
    remove unneeded cast in rpcmisc.cpp
    on Sep 9, 2014
  7. Diapolo commented at 5:31 PM on September 9, 2014: none

    @sipa Yeah 2 typos in such a short commit-msg is ouch, fixed now.

  8. BitcoinPullTester commented at 5:38 PM on September 9, 2014: none

    Automatic sanity-testing: PASSED, see http://jenkins.bluematt.me/pull-tester/p4882_faadbe17333a41fc1c15551f74a6ae5dcbd6aedc/ 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.

  9. sipa commented at 11:33 PM on September 9, 2014: member

    @laanwj To conclude: in Bitcoin v0.3.10 (over 4 years ago), the following line was added:

        obj.push_back(Pair("version",       (int)VERSION));
    

    while VERSION was a static const int already. Since then, the line seems to have been moved and copied many times, but the cast was always kept...

  10. sipa merged this on Sep 9, 2014
  11. sipa closed this on Sep 9, 2014

  12. sipa referenced this in commit 4ebd80298d on Sep 9, 2014
  13. laanwj commented at 7:55 AM on September 10, 2014: member

    OK, I'm confused with other RPC casts then. At a certain point someone introduced a lot of them to silence compiler warnings.

    Ideally we wouldn't need casts at all by making the JSON value type accept only one integer type (there's no actual need to distinguish them besides possibly signed/unsigned). But it's not worth spending time on that as this will go away when switching to univalue.

  14. Diapolo deleted the branch on Sep 10, 2014
  15. MarcoFalke locked this on Sep 8, 2021

github-metadata-mirror

This is a metadata mirror of the GitHub repository bitcoin/bitcoin. This site is not affiliated with GitHub. Content is generated from a GitHub metadata backup.
generated: 2026-04-21 18:15 UTC

This site is hosted by @0xB10C
More mirrored repositories can be found on mirror.b10c.me