diff --git a/contracts/test_api/test_action.cpp b/contracts/test_api/test_action.cpp index 22d3f59c5d20dd159b823d80ddebae662833b5d2..adc517453fa19994e9aa36a2e08c56583f531cb3 100644 --- a/contracts/test_api/test_action.cpp +++ b/contracts/test_api/test_action.cpp @@ -152,7 +152,7 @@ void test_action::test_cf_action() { publication_time(); eosio_assert( false, "system_api should not be allowed" ); } else if ( cfa.payload == 210 ) { - send_inline( "hello", 6 ); + send_inline( (char*)"hello", 6 ); eosio_assert( false, "transaction_api should not be allowed" ); } else if ( cfa.payload == 211 ) { send_deferred( N(testapi), N(testapi), "hello", 6 ); diff --git a/contracts/test_api/test_datastream.cpp b/contracts/test_api/test_datastream.cpp index 23fc769d2f861e55d6b67cbb4dd0a4945f646b00..3ad663ec48ac821c688a1b8494fe1ffeff70203c 100644 --- a/contracts/test_api/test_datastream.cpp +++ b/contracts/test_api/test_datastream.cpp @@ -74,13 +74,13 @@ void test_datastream::test_basic() int a[2]; bool operator==(const StaticArray &o) const { return a[0] == o.a[0] && a[1] == o.a[1]; } }; - testtype::run({10,20}, "StaticArray"); + testtype::run({{10,20}}, "StaticArray"); testtype::run("hello", "string"); testtype >::run({10,20,30}, "vector"); testtype >::run({}, "empty vector"); - testtype >::run({10,20,30}, "std::array"); + testtype >::run({{10,20,30}}, "std::array"); testtype >::run({{1,"apple"}, {2,"cat"}, {3,"panda"}}, "map"); testtype >::run({1, "abc", 3.3333}, "tuple"); } diff --git a/contracts/test_api_db/test_db.cpp b/contracts/test_api_db/test_db.cpp index c342c514c50a75dce853a5391397615e054543e6..d9ded6e233c9a8c7d0b2940f86937171fbe5aa95 100644 --- a/contracts/test_api_db/test_db.cpp +++ b/contracts/test_api_db/test_db.cpp @@ -536,6 +536,9 @@ void test_db::idx_double_nan_lookup_fail(uint64_t receiver, uint64_t, uint64_t) } } +#pragma clang diagnostic push +#pragma clang diagnostic ignored "-Wcast-align" + void test_db::misaligned_secondary_key256_tests(uint64_t /* receiver */, uint64_t, uint64_t) { auto key = eosio::key256::make_from_word_sequence(0ULL, 0ULL, 0ULL, 42ULL); char* ptr = (char*)(&key); @@ -545,3 +548,5 @@ void test_db::misaligned_secondary_key256_tests(uint64_t /* receiver */, uint64_ // test that find_primary doesn't crash on unaligned data db_idx256_find_primary( N(testapi), N(testtable), N(testapi), (eosio::key256*)(ptr), 2, 0); } + +#pragma clang diagnostic pop diff --git a/libraries/fc/src/io/json.cpp b/libraries/fc/src/io/json.cpp index 57c6462aa0c87c515b6e8e2881e5dd31b1207589..1ef8c78624550f7c0d36205e1f474ff50151eefc 100644 --- a/libraries/fc/src/io/json.cpp +++ b/libraries/fc/src/io/json.cpp @@ -657,7 +657,7 @@ namespace fc return; } default: - FC_THROW_EXCEPTION( fc::invalid_arg_exception, "Unsupported variant type: " + v.get_type() ); + FC_THROW_EXCEPTION( fc::invalid_arg_exception, "Unsupported variant type: " + std::to_string( v.get_type() ) ); } } diff --git a/programs/eosio-applesedemo/main.cpp b/programs/eosio-applesedemo/main.cpp index ca0018c532db5a9c8a27d6b4f905c9b20b4326f5..f43d83c3805d866268a9c8018fbaaaa46680f6bb 100644 --- a/programs/eosio-applesedemo/main.cpp +++ b/programs/eosio-applesedemo/main.cpp @@ -34,7 +34,7 @@ CFDictionaryRef CopyOurKeyInfo() { CFDictionaryRef keyAttrDic = CFDictionaryCreate(nullptr, keyAttrKeys, keyAttrValues, sizeof(keyAttrKeys)/sizeof(keyAttrKeys[0]), &kCFTypeDictionaryKeyCallBacks, &kCFTypeDictionaryValueCallBacks); CFDictionaryRef attributes = nullptr; - OSStatus ret = SecItemCopyMatching(keyAttrDic, (CFTypeRef*)&attributes); + SecItemCopyMatching(keyAttrDic, (CFTypeRef*)&attributes); CFRelease(keyAttrDic); return attributes; @@ -296,4 +296,4 @@ int main(int argc, char* argv[]) { cout << all_desc << endl; return 0; -} \ No newline at end of file +}