Closed the-nic closed 7 years ago
Hi although this is not a bug in the code itself, gcc 4.7.3 crashes with the building test_implicit_cast:
[100%] Building CXX object test/CMakeFiles/test_implicit_cast.dir/test_implicit_cast.cpp.o In file included from /home/nhoeft/projects/luabind/luabind/detail/policy.hpp:29:0, from /home/nhoeft/projects/luabind/luabind/detail/convert_to_lua.hpp:28, from /home/nhoeft/projects/luabind/luabind/detail/object.hpp:40, from /home/nhoeft/projects/luabind/luabind/make_function.hpp:9, from /home/nhoeft/projects/luabind/luabind/function.hpp:8, from /home/nhoeft/projects/luabind/luabind/class.hpp:81, from /home/nhoeft/projects/luabind/luabind/luabind.hpp:28, from /home/nhoeft/projects/luabind/test/test_implicit_cast.cpp:24: /home/nhoeft/projects/luabind/luabind/detail/decorate_type.hpp: In instantiation of ‘static int luabind::detail::match_struct<StackIndexList, SignatureList, End, Index>::match(lua_State*, TupleType&) [with TupleType = std::tuple<luabind::default_converter<LBENUM_t, void> >; StackIndexList = meta::index_list<1u>; SignatureList = meta::type_list<LBENUM_t, LBENUM_t>; unsigned int End = 2u; unsigned int Index = 1u; lua_State = lua_State]’: /home/nhoeft/projects/luabind/luabind/detail/call.hpp:489:6: required from ‘static int luabind::detail::invoke_struct<PolicyList, Signature, F>::invoke(lua_State*, const luabind::detail::function_object&, luabind::detail::invoke_context&, F&) [with PolicyList = meta::type_list<>; Signature = meta::type_list<LBENUM_t, LBENUM_t>; F = LBENUM_t (*)(LBENUM_t); lua_State = lua_State]’ /home/nhoeft/projects/luabind/luabind/detail/call.hpp:532:76: required from ‘int luabind::detail::invoke(lua_State*, const luabind::detail::function_object&, luabind::detail::invoke_context&, F&) [with PolicyList = meta::type_list<>; Signature = meta::type_list<LBENUM_t, LBENUM_t>; F = LBENUM_t (*)(LBENUM_t); lua_State = lua_State]’ /home/nhoeft/projects/luabind/luabind/make_function.hpp:58:6: required from ‘static bool luabind::detail::function_object_impl<F, Signature, InjectorList>::invoke_defer(lua_State*, luabind::detail::function_object_impl<F, Signature, InjectorList>*, luabind::detail::invoke_context&, F&, int&) [with F = LBENUM_t (*)(LBENUM_t); Signature = meta::type_list<LBENUM_t, LBENUM_t>; InjectorList = meta::type_list<>; lua_State = lua_State; luabind::detail::function_object_impl<F, Signature, InjectorList> = luabind::detail::function_object_impl<LBENUM_t (*)(LBENUM_t), meta::type_list<LBENUM_t, LBENUM_t>, meta::type_list<> >]’ /home/nhoeft/projects/luabind/luabind/make_function.hpp:79:72: required from ‘static int luabind::detail::function_object_impl<F, Signature, InjectorList>::entry_point(lua_State*) [with F = LBENUM_t (*)(LBENUM_t); Signature = meta::type_list<LBENUM_t, LBENUM_t>; InjectorList = meta::type_list<>; lua_State = lua_State]’ /home/nhoeft/projects/luabind/luabind/make_function.hpp:33:41: required from ‘luabind::detail::function_object_impl<F, Signature, InjectorList>::function_object_impl(F) [with F = LBENUM_t (*)(LBENUM_t); Signature = meta::type_list<LBENUM_t, LBENUM_t>; InjectorList = meta::type_list<>]’ /home/nhoeft/projects/luabind/luabind/make_function.hpp:107:161: required from ‘luabind::adl::object luabind::make_function(lua_State*, F, meta::type_list<Types2 ...>, meta::type_list<TailTypes ...>) [with F = LBENUM_t (*)(LBENUM_t); SignatureElements = {LBENUM_t, LBENUM_t}; PolicyInjectors = {}; lua_State = lua_State]’ /home/nhoeft/projects/luabind/luabind/make_function.hpp:113:119: required from ‘luabind::adl::object luabind::make_function(lua_State*, F, meta::type_list<Types2 ...>) [with F = LBENUM_t (*)(LBENUM_t); PolicyInjectors = {}; lua_State = lua_State]’ /home/nhoeft/projects/luabind/luabind/function.hpp:27:61: required from ‘void luabind::detail::function_registration<F, PolicyInjectors>::register_(lua_State*) const [with F = LBENUM_t (*)(LBENUM_t); PolicyInjectors = meta::type_list<>; lua_State = lua_State]’ /home/nhoeft/projects/luabind/test/test_implicit_cast.cpp:139:1: required from here /home/nhoeft/projects/luabind/luabind/detail/decorate_type.hpp:76:81: internal compiler error: Segmentation fault
The rest builds fine. Any idea?
By the way, this error seems to be caused in "def("enum_by_val", &enum_by_val)" in test_implicit_cast.cpp
Closing this as it's getting outdated. Hopefully you were in a position to bump the compiler version.
Hi although this is not a bug in the code itself, gcc 4.7.3 crashes with the building test_implicit_cast:
The rest builds fine. Any idea?