Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- [1/2] Compiling main.cpp
- FAILED: g++ -MMD -MF obj/main.o.d -std=c++11 -pedantic -pedantic-errors -Wextra -Wall -O2 -DNDEBUG -c main.cpp -o obj/main.o -I"."
- In file included from ./sol/state.hpp:26:0,
- from ./sol.hpp:25,
- from main.cpp:1:
- ./sol/table.hpp: In member function 'sol::table& sol::table::set_fx(std::true_type, T&&, TFx&&, TObj&&)':
- ./sol/table.hpp:148:9: error: 'memcpy' is not a member of 'std'
- std::memcpy(std::addressof(fxptrdata[ 0 ]), std::addressof(fxptr), fxptrsize);
- ^
- ./sol/table.hpp:148:9: note: suggested alternative:
- In file included from c:\mingw64\include\c++\4.8.1\cwchar:44:0,
- from c:\mingw64\include\c++\4.8.1\bits\postypes.h:40,
- from c:\mingw64\include\c++\4.8.1\bits\char_traits.h:40,
- from c:\mingw64\include\c++\4.8.1\string:40,
- from c:\mingw64\include\c++\4.8.1\stdexcept:39,
- from ./sol/error.hpp:25,
- from ./sol/state.hpp:25,
- from ./sol.hpp:25,
- from main.cpp:1:
- c:\mingw64\x86_64-w64-mingw32\include\wchar.h:957:17: note: 'memcpy'
- void *__cdecl memcpy(void * __restrict__ _Dst,const void * __restrict__ _Src,size_t _MaxCount) __MINGW_ATTRIB_DEPRECATED_SEC_WARN;
- ^
- In file included from ./sol/state.hpp:26:0,
- from ./sol.hpp:25,
- from main.cpp:1:
- ./sol/table.hpp: In instantiation of 'sol::table& sol::table::set_function(T&&, TFx&&, TObj&&) [with T = const char (&)[4]; TFx = std::basic_string<char> (member_test::*)(); TObj = member_test]':
- main.cpp:47:99: required from here
- ./sol/table.hpp:83:81: error: no matching function for call to 'sol::table::set_lvalue_fx(std::integral_constant<bool, false>, const char [4], std::basic_string<char> (member_test::*)(), member_test)'
- std::forward<T>(key), std::forward<TFx>(fx), std::forward<TObj>(obj));
- ^
- ./sol/table.hpp:83:81: note: candidates are:
- ./sol/table.hpp:120:12: note: template<class T, class TFx, class TObj> sol::table& sol::table::set_lvalue_fx(std::true_type, T&&, TFx&&, TObj&&)
- table& set_lvalue_fx(std::true_type, T&& key, TFx&& fx, TObj&& obj) {
- ^
- ./sol/table.hpp:120:12: note: template argument deduction/substitution failed:
- ./sol/table.hpp:83:81: note: cannot convert 'std::integral_constant<bool, false>()' (type 'std::integral_constant<bool, false>') to type 'std::true_type {aka std::integral_constant<bool, true>}'
- std::forward<T>(key), std::forward<TFx>(fx), std::forward<TObj>(obj));
- ^
- ./sol/table.hpp:125:12: note: sol::table& sol::table::set_lvalue_fx(std::false_type, T&&, TFx&&, TM&) [with T = const char (&)[4]; TFx = std::basic_string<char> (member_test::*)(); TM = member_test; std::false_type = std::integral_constant<bool, false>]
- table& set_lvalue_fx(std::false_type, T&& key, TFx&& fx, TM& mem) {
- ^
- ./sol/table.hpp:125:12: note: no known conversion for argument 4 from 'member_test' to 'member_test&'
- ./sol/table.hpp: In instantiation of 'sol::table& sol::table::set_fx(std::false_type, T&&, TFx&&) [with T = const char (&)[4]; TFx = std::basic_string<char> (*)(); std::false_type = std::integral_constant<bool, false>]':
- ./sol/table.hpp:94:85: required from 'sol::table& sol::table::set_isfunction_fx(std::true_type, T&&, TFx&&) [with T = const char (&)[4]; TFx = std::basic_string<char> (*)(); std::true_type = std::integral_constant<bool, true>]'
- ./sol/table.hpp:77:106: required from 'sol::table& sol::table::set_function(T&&, TFx&&) [with T = const char (&)[4]; TFx = std::basic_string<char> (*)()]'
- main.cpp:37:72: required from here
- ./sol/table.hpp:173:50: error: invalid static_cast from type 'ptr_fx {aka std::basic_string<char> (*)()}' to type 'void*'
- void* userdata = static_cast<void*>(target);
- ^
- ./sol/table.hpp:179:8: warning: missing initializer for member 'luaL_Reg::name' [-Wmissing-field-initializers]
- };
- ^
- ./sol/table.hpp:179:8: warning: missing initializer for member 'luaL_Reg::func' [-Wmissing-field-initializers]
- ./sol/table.hpp:173:14: warning: unused variable 'userdata' [-Wunused-variable]
- void* userdata = static_cast<void*>(target);
- ^
- ./sol/table.hpp: In instantiation of 'sol::table& sol::table::set_fx(std::true_type, T&&, TFx&&, TObj&&) [with T = const char (&)[4]; TFx = std::basic_string<char> (member_test::*)(); TObj = member_test&; std::true_type = std::integral_constant<bool, true>]':
- ./sol/table.hpp:121:109: required from 'sol::table& sol::table::set_lvalue_fx(std::true_type, T&&, TFx&&, TObj&&) [with T = const char (&)[4]; TFx = std::basic_string<char> (member_test::*)(); TObj = member_test&; std::true_type = std::integral_constant<bool, true>]'
- ./sol/table.hpp:83:81: required from 'sol::table& sol::table::set_function(T&&, TFx&&, TObj&&) [with T = const char (&)[4]; TFx = std::basic_string<char> (member_test::*)(); TObj = member_test&]'
- main.cpp:42:89: required from here
- ./sol/table.hpp:155:9: warning: missing initializer for member 'luaL_Reg::name' [-Wmissing-field-initializers]
- };
- ^
- ./sol/table.hpp:155:9: warning: missing initializer for member 'luaL_Reg::func' [-Wmissing-field-initializers]
- ./sol/table.hpp: In instantiation of 'sol::table& sol::table::set_fx(T&&, std::unique_ptr<sol::lua_func>) [with T = const char (&)[4]]':
- ./sol/table.hpp:116:59: required from 'sol::table& sol::table::set_isconvertible_fx(std::false_type, T&&, TFx&&) [with T = const char (&)[4]; TFx = main()::__lambda4; std::false_type = std::integral_constant<bool, false>]'
- ./sol/table.hpp:102:96: required from 'sol::table& sol::table::set_isfunction_fx(std::false_type, T&&, TFx&&) [with T = const char (&)[4]; TFx = main()::__lambda4; std::false_type = std::integral_constant<bool, false>]'
- ./sol/table.hpp:77:106: required from 'sol::table& sol::table::set_function(T&&, TFx&&) [with T = const char (&)[4]; TFx = main()::__lambda4]'
- main.cpp:62:9: required from here
- ./sol/table.hpp:208:9: warning: missing initializer for member 'luaL_Reg::name' [-Wmissing-field-initializers]
- };
- ^
- ./sol/table.hpp:208:9: warning: missing initializer for member 'luaL_Reg::func' [-Wmissing-field-initializers]
- ./sol/table.hpp: In instantiation of 'sol::table& sol::table::set_fx(std::false_type, T&&, TFx&&) [with T = const char (&)[4]; TFx = const char* (*)(); std::false_type = std::integral_constant<bool, false>]':
- ./sol/table.hpp:94:85: required from 'sol::table& sol::table::set_isfunction_fx(std::true_type, T&&, TFx&&) [with T = const char (&)[4]; TFx = const char* (*)(); std::true_type = std::integral_constant<bool, true>]'
- ./sol/table.hpp:109:107: required from 'sol::table& sol::table::set_isconvertible_fx(std::true_type, T&&, TFx&&) [with T = const char (&)[4]; TFx = main()::__lambda3; std::true_type = std::integral_constant<bool, true>]'
- ./sol/table.hpp:102:96: required from 'sol::table& sol::table::set_isfunction_fx(std::false_type, T&&, TFx&&) [with T = const char (&)[4]; TFx = main()::__lambda3; std::false_type = std::integral_constant<bool, false>]'
- ./sol/table.hpp:77:106: required from 'sol::table& sol::table::set_function(T&&, TFx&&) [with T = const char (&)[4]; TFx = main()::__lambda3]'
- main.cpp:34:9: required from here
- ./sol/table.hpp:173:50: error: invalid static_cast from type 'ptr_fx {aka const char* (*)()}' to type 'void*'
- void* userdata = static_cast<void*>(target);
- ^
- ./sol/table.hpp:179:8: warning: missing initializer for member 'luaL_Reg::name' [-Wmissing-field-initializers]
- };
- ^
- ./sol/table.hpp:179:8: warning: missing initializer for member 'luaL_Reg::func' [-Wmissing-field-initializers]
- ./sol/table.hpp:173:14: warning: unused variable 'userdata' [-Wunused-variable]
- void* userdata = static_cast<void*>(target);
- ^
- ./sol/table.hpp: In member function 'sol::table& sol::table::set_function(T&&, TFx&&, TObj&&) [with T = const char (&)[4]; TFx = std::basic_string<char> (member_test::*)(); TObj = member_test]':
- ./sol/table.hpp:84:5: warning: control reaches end of non-void function [-Wreturn-type]
- }
- ^
- ninja: build stopped: subcommand failed.
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement