diff --git a/include/fc/crypto/ripemd160.hpp b/include/fc/crypto/ripemd160.hpp index 6e73917..389d677 100644 --- a/include/fc/crypto/ripemd160.hpp +++ b/include/fc/crypto/ripemd160.hpp @@ -45,7 +45,7 @@ class ripemd160 ripemd160 result(); private: - struct impl; + class impl; fc::fwd my; }; diff --git a/include/fc/exception/exception.hpp b/include/fc/exception/exception.hpp index 1c1e7dc..ec100f4 100644 --- a/include/fc/exception/exception.hpp +++ b/include/fc/exception/exception.hpp @@ -446,11 +446,11 @@ namespace fc catch( fc::exception& er ) { \ FC_RETHROW_EXCEPTION( er, LOG_LEVEL, FORMAT, __VA_ARGS__ ); \ } catch( const std::exception& e ) { \ - fc::exception fce( \ + throw fc::exception( \ FC_LOG_MESSAGE( LOG_LEVEL, "${what}: " FORMAT,__VA_ARGS__("what",e.what())), \ fc::std_exception_code,\ typeid(e).name(), \ - e.what() ) ; throw fce;\ + e.what() ) ;\ } catch( ... ) { \ throw fc::unhandled_exception( \ FC_LOG_MESSAGE( LOG_LEVEL, FORMAT,__VA_ARGS__), \ @@ -461,11 +461,11 @@ namespace fc catch( fc::exception& er ) { \ FC_RETHROW_EXCEPTION( er, warn, "", FC_FORMAT_ARG_PARAMS(__VA_ARGS__) ); \ } catch( const std::exception& e ) { \ - fc::exception fce( \ + throw fc::exception( \ FC_LOG_MESSAGE( warn, "${what}: ",FC_FORMAT_ARG_PARAMS(__VA_ARGS__)("what",e.what())), \ fc::std_exception_code,\ typeid(e).name(), \ - e.what() ) ; throw fce;\ + e.what() ) ;\ } catch( ... ) { \ throw fc::unhandled_exception( \ FC_LOG_MESSAGE( warn, "",FC_FORMAT_ARG_PARAMS(__VA_ARGS__)), \ diff --git a/include/fc/log/log_message.hpp b/include/fc/log/log_message.hpp index a320b66..e9e1a68 100644 --- a/include/fc/log/log_message.hpp +++ b/include/fc/log/log_message.hpp @@ -147,7 +147,7 @@ FC_REFLECT_TYPENAME( fc::log_message ); * @param LOG_LEVEL - a valid log_level::Enum name. */ #define FC_LOG_CONTEXT(LOG_LEVEL) \ - fc::log_context( fc::log_level::LOG_LEVEL, __FILE__, __LINE__, __func__ ) + fc::log_context( fc::log_level::LOG_LEVEL, (const char*)__FILE__, __LINE__, (const char*)__func__ ) /** * @def FC_LOG_MESSAGE(LOG_LEVEL,FORMAT,...) diff --git a/tests/crypto/bigint_test.cpp b/tests/crypto/bigint_test.cpp index 5473b7a..833c5f4 100644 --- a/tests/crypto/bigint_test.cpp +++ b/tests/crypto/bigint_test.cpp @@ -46,8 +46,6 @@ BOOST_AUTO_TEST_CASE(bigint_test_2) BOOST_CHECK( bi_accu >= a_1 ); } while ( bi_accu.log2() <= 128 ); - bi_accu = bi_accu; - BOOST_CHECK( bi_accu && !bi_accu.is_negative() && bi_accu != bi_1 ); BOOST_CHECK( bi_3.exp( bi_accu.log2() ) > bi_accu ); diff --git a/tests/io/json_tests.cpp b/tests/io/json_tests.cpp index d56f801..7f0369e 100644 --- a/tests/io/json_tests.cpp +++ b/tests/io/json_tests.cpp @@ -171,7 +171,7 @@ static bool equal( const fc::variant& a, const fc::variant& b ) return true; case fc::variant::type_id::blob_type: default: - FC_THROW_EXCEPTION( fc::invalid_arg_exception, "Unsupported variant type: " + a.get_type() ); + FC_THROW_EXCEPTION( fc::invalid_arg_exception, "Unsupported variant type: " + std::to_string( a.get_type() ) ); } } @@ -348,7 +348,7 @@ BOOST_AUTO_TEST_CASE(rethrow_test) } FC_RETHROW_EXCEPTIONS( warn, "Argh! ${biggie}", ("biggie",biggie) ) }; BOOST_CHECK_THROW( test_r(), fc::unknown_host_exception ); - auto test_lr = [&biggie](){ + auto test_lr = [](){ try { FC_THROW_EXCEPTION( fc::unknown_host_exception, "WTF?" ); } FC_LOG_AND_RETHROW() };