Bug 35089

Summary: gcc7: internal compiler error: unexpected expression ‘I’ of kind template_parm_index -- fixed upstream
Product: Sisyphus Reporter: Pavel Nakonechnyi <zorg1331>
Component: gcc7Assignee: Nobody's working on this, feel free to take it <nobody>
Status: CLOSED FIXED QA Contact: qa-sisyphus
Severity: normal    
Priority: P3 CC: lav
Version: unstable   
Hardware: all   
OS: Linux   

Description Pavel Nakonechnyi 2018-06-26 16:22:20 MSK
В багзилле Debian https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=892719 данный баг закрыт с указанием фикса.

У меня воспроизвелось при попытки собрать проект https://github.com/avast-tl/yaramod, вывод компилятора для этого случая ниже. С gcc6 проблемы не наблюдается.

In file included from /tmp/yaramod/include/yaramod/utils/visitor_result.h:11:0,
                 from /tmp/yaramod/include/yaramod/types/expression.h:14,
                 from /tmp/yaramod/include/yaramod/builder/yara_expression_builder.h:12,
                 from /tmp/yaramod/src/builder/yara_expression_builder.cpp:7:
/tmp/yaramod/deps/variant/variant.hpp: In substitution of ‘template<long unsigned int I, class ... Ts> using type_pack_element_t = typename mpark::lib::type_pack_element_impl::type::type [with long unsigned int I = I; Ts = {std::shared_ptr<yaramod::Expression>, yaramod::VisitAction}]’:
/tmp/yaramod/deps/variant/variant.hpp:1900:9:   required by substitution of ‘template<class Arg, class Decayed, typename std::enable_if<(! std::is_same<Decayed, mpark::variant<std::shared_ptr<yaramod::Expression>, yaramod::VisitAction> >::value), int>::type <anonymous>, typename std::enable_if<(! mpark::detail::is_in_place_index<Decayed>::value), int>::type <anonymous>, typename std::enable_if<(! mpark::detail::is_in_place_type<Decayed>::value), int>::type <anonymous>, long unsigned int I, class T, typename std::enable_if<std::is_constructible<T, Arg>::value, int>::type <anonymous> > constexpr mpark::variant<std::shared_ptr<yaramod::Expression>, yaramod::VisitAction>::variant(Arg&&) [with Arg = mpark::variant<std::shared_ptr<yaramod::Expression>, yaramod::VisitAction>; Decayed = mpark::variant<std::shared_ptr<yaramod::Expression>, yaramod::VisitAction>; typename std::enable_if<(! std::is_same<Decayed, mpark::variant<std::shared_ptr<yaramod::Expression>, yaramod::VisitAction> >::value), int>::type <anonymous> = <missing>; typename std::enable_if<(! mpark::detail::is_in_place_index<Decayed>::value), int>::type <anonymous> = <missing>; typename std::enable_if<(! mpark::detail::is_in_place_type<Decayed>::value), int>::type <anonymous> = <missing>; long unsigned int I = <missing>; T = <missing>; typename std::enable_if<std::is_constructible<T, Arg>::value, int>::type <anonymous> = <missing>]’
/tmp/yaramod/include/yaramod/types/expressions.h:35:23:   required from here
/tmp/yaramod/deps/variant/variant.hpp:1900:9: internal compiler error: unexpected expression ‘I’ of kind template_parm_index
         typename T = lib::type_pack_element_t<I, Ts...>,
         ^~~~~~~~
Please submit a full bug report,
with preprocessed source if appropriate.
See <http://bugzilla.altlinux.org> for instructions.
Comment 1 Repository Robot 2018-07-14 03:01:04 MSK
gcc7-7.3.1-alt5 -> sisyphus:

Fri Jul 13 2018 Dmitry V. Levin <ldv@altlinux> 7.3.1-alt5
- Updated to redhat/gcc-7-branch r262599 (closes: #35089).
- Synced with Fedora gcc 7.3.1-6.
- Moved documentation for Fortran, Ada, and Go compilers from gcc7-doc
  to gcc7-fortran-doc, gcc7-gnat-doc, and gcc7-go-doc subpackages.