Fix a type error that would not compile on OSX. #8513

pull JeremyRubin wants to merge 1 commits into bitcoin:master from JeremyRubin:fix-osx-break changing 1 files +1 −1
  1. JeremyRubin commented at 12:48 AM on August 15, 2016: contributor

    I was unable to compile on OSX without having the proper type here.

  2. Fix a type error that would not compile on Apple LLVM version 6.1.0 (clang-602.0.53) (based on LLVM 3.6.0svn) 8194a6e525
  3. paveljanik commented at 11:08 AM on August 15, 2016: contributor

    @JeremyRubin can you please paste exact error message?

  4. jonasschnelli added the label MacOSX on Aug 15, 2016
  5. JeremyRubin commented at 7:17 AM on August 16, 2016: contributor
    httprpc.cpp:234:5: error: no matching function for call to 'RegisterHTTPHandler'
        RegisterHTTPHandler("/", true, HTTPReq_JSONRPC);
        ^~~~~~~~~~~~~~~~~~~
    ./httpserver.h:41:6: note: candidate function not viable: no known conversion from 'bool (HTTPRequest *, const std::string &)' to 'const HTTPRequestHandler'
          (aka 'const function<void (HTTPRequest *, const std::string &)>') for 3rd argument
    void RegisterHTTPHandler(const std::string &prefix, bool exactMatch, const HTTPRequestHandler &handler);
         ^
    1 error generated.
    make[1]: *** [libbitcoin_server_a-httprpc.o] Error 1
    make: *** [all-recursive] Error 1
    
  6. paveljanik commented at 7:38 PM on August 16, 2016: contributor

    Interesting. Can't reproduce here, but the change is obviously correct.

    ACK https://github.com/bitcoin/bitcoin/pull/8513/commits/8194a6e525514d5cda85ac08273a6ffb6d5b6cac

  7. JeremyRubin commented at 12:41 AM on August 17, 2016: contributor

    @paveljanik

    you have:

    Apple LLVM version 6.1.0 (clang-602.0.53) (based on LLVM 3.6.0svn)
    Target: x86_64-apple-darwin14.5.0
    Thread model: posix
    

    on master?

  8. paveljanik commented at 7:10 AM on August 17, 2016: contributor

    My clang is:

    Apple LLVM version 7.0.2 (clang-700.1.81)
    Target: x86_64-apple-darwin14.5.0
    Thread model: posix
    
  9. jonasschnelli commented at 7:47 AM on August 17, 2016: contributor

    Can't reproduce either, but utACK.

    Apple LLVM version 7.3.0 (clang-703.0.31)
    Target: x86_64-apple-darwin15.6.0
    Thread model: posix
    
  10. laanwj commented at 10:32 AM on August 17, 2016: member

    This is safe: all functions that are registered with RegisterHTTPHandler return a bool. ACK 8194a6e

  11. laanwj merged this on Aug 17, 2016
  12. laanwj closed this on Aug 17, 2016

  13. laanwj referenced this in commit 65e6444181 on Aug 17, 2016
  14. luke-jr referenced this in commit 4e5fc31ae6 on Sep 21, 2016
  15. codablock referenced this in commit 9c17dddf84 on Sep 19, 2017
  16. codablock referenced this in commit 6f15ef3c4b on Dec 29, 2017
  17. codablock referenced this in commit 6b8160ba20 on Jan 8, 2018
  18. andvgal referenced this in commit 8ff30014d2 on Jan 6, 2019
  19. 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-15 21:16 UTC

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