<div dir="ltr">Perhaps we'd be best to just advise people to not mix this combination of compiler + standard library? GCC 6 was a pretty big step, as I understand it.<br><br>(I'm just building Clang against GCC 6, but of course realizing the Clang I'm using is ToT, so it doesn't exhibit the problem you're describing)<br><br>But I'll try to dial back to a 3.7 if I have one around & see if I can reproduce & find some better solution.<br><br><div class="gmail_quote"><div dir="ltr">On Tue, Aug 2, 2016 at 9:47 AM Frederich Munch <<a href="mailto:marsupial@users.noreply.github.com" target="_blank">marsupial@users.noreply.github.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">marsupial added a comment.<br>
<br>
Found one:<br>
<br>
  In file included from ../../lib/CodeGen/LexicalScopes.cpp:17:<br>
  In file included from ../../include/llvm/CodeGen/LexicalScopes.h:20:<br>
  In file included from ../../include/llvm/ADT/ArrayRef.h:13:<br>
  In file included from ../../include/llvm/ADT/Hashing.h:49:<br>
  In file included from ../../include/llvm/Support/Host.h:17:<br>
  In file included from ../../include/llvm/ADT/StringMap.h:18:<br>
  In file included from ../../include/llvm/Support/Allocator.h:24:<br>
  In file included from ../../include/llvm/ADT/SmallVector.h:29:<br>
  In file included from /usr/bin/../lib/gcc/x86_64-linux-gnu/6.1.1/../../../../include/c++/6.1.1/memory:79:<br>
  In file included from /usr/bin/../lib/gcc/x86_64-linux-gnu/6.1.1/../../../../include/c++/6.1.1/functional:55:<br>
  /usr/bin/../lib/gcc/x86_64-linux-gnu/6.1.1/../../../../include/c++/6.1.1/tuple:1400:14: error:<br>
        no matching constructor for initialization of 'tuple<llvm::LexicalScope<br>
        *&&, const llvm::DILocalScope *&&, nullptr_t &&, bool &&>'<br>
      { return tuple<_Elements&&...>(std::forward<_Elements>(__args)...); }<br>
               ^                     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~<br>
  ../../lib/CodeGen/LexicalScopes.cpp:155:36: note: in instantiation of function<br>
        template specialization 'std::forward_as_tuple<llvm::LexicalScope *&,<br>
        const llvm::DILocalScope *&, nullptr_t, bool>' requested here<br>
                                std::forward_as_tuple(Parent, Scope, nullptr,<br>
                                     ^<br>
  /usr/bin/../lib/gcc/x86_64-linux-gnu/6.1.1/../../../../include/c++/6.1.1/tuple:600:18: note:<br>
        candidate template ignored: disabled by 'enable_if' [with _Dummy = void]<br>
                   _TCC<_Dummy>::template<br>
                   ^<br>
  /usr/bin/../lib/gcc/x86_64-linux-gnu/6.1.1/../../../../include/c++/6.1.1/tuple:611:18: note:<br>
        candidate template ignored: disabled by 'enable_if' [with _Dummy = void]<br>
                   _TCC<_Dummy>::template<br>
                   ^<br>
  /usr/bin/../lib/gcc/x86_64-linux-gnu/6.1.1/../../../../include/c++/6.1.1/tuple:628:5: note:<br>
        candidate template ignored: disabled by 'enable_if' [with _UElements =<br>
        <llvm::LexicalScope *&, const llvm::DILocalScope *&, nullptr_t, bool>]<br>
                    _TC<sizeof...(_UElements) == 1, _Elements...>::template<br>
                    ^<br>
  /usr/bin/../lib/gcc/x86_64-linux-gnu/6.1.1/../../../../include/c++/6.1.1/tuple:641:5: note:<br>
        candidate template ignored: disabled by 'enable_if' [with _UElements =<br>
        <llvm::LexicalScope *&, const llvm::DILocalScope *&, nullptr_t, bool>]<br>
                    _TC<sizeof...(_UElements) == 1, _Elements...>::template<br>
                    ^<br>
  /usr/bin/../lib/gcc/x86_64-linux-gnu/6.1.1/../../../../include/c++/6.1.1/tuple:737:19: note:<br>
        candidate template ignored: disabled by 'enable_if' [with _Alloc = const<br>
        llvm::DILocalScope *, _UElements = <nullptr_t, bool>]<br>
          enable_if<_TMC<_UElements...>::template<br>
                    ^<br>
  /usr/bin/../lib/gcc/x86_64-linux-gnu/6.1.1/../../../../include/c++/6.1.1/tuple:748:19: note:<br>
        candidate template ignored: disabled by 'enable_if' [with _Alloc = const<br>
        llvm::DILocalScope *, _UElements = <nullptr_t, bool>]<br>
          enable_if<_TMC<_UElements...>::template<br>
                    ^<br>
  /usr/bin/../lib/gcc/x86_64-linux-gnu/6.1.1/../../../../include/c++/6.1.1/tuple:579:17: note:<br>
        candidate constructor template not viable: requires 0 arguments, but 4<br>
        were provided<br>
        constexpr tuple()<br>
                  ^<br>
  /usr/bin/../lib/gcc/x86_64-linux-gnu/6.1.1/../../../../include/c++/6.1.1/tuple:589:26: note:<br>
        candidate constructor template not viable: requires 0 arguments, but 4<br>
        were provided<br>
        explicit constexpr tuple()<br>
                           ^<br>
  /usr/bin/../lib/gcc/x86_64-linux-gnu/6.1.1/../../../../include/c++/6.1.1/tuple:670:19: note:<br>
        candidate constructor template not viable: requires single argument<br>
        '__in', but 4 arguments were provided<br>
          constexpr tuple(const tuple<_UElements...>& __in)<br>
                    ^<br>
  /usr/bin/../lib/gcc/x86_64-linux-gnu/6.1.1/../../../../include/c++/6.1.1/tuple:682:28: note:<br>
        candidate constructor template not viable: requires single argument<br>
        '__in', but 4 arguments were provided<br>
          explicit constexpr tuple(const tuple<_UElements...>& __in)<br>
                             ^<br>
  /usr/bin/../lib/gcc/x86_64-linux-gnu/6.1.1/../../../../include/c++/6.1.1/tuple:694:19: note:<br>
        candidate constructor template not viable: requires single argument<br>
        '__in', but 4 arguments were provided<br>
          constexpr tuple(tuple<_UElements...>&& __in)<br>
                    ^<br>
  /usr/bin/../lib/gcc/x86_64-linux-gnu/6.1.1/../../../../include/c++/6.1.1/tuple:705:28: note:<br>
        candidate constructor template not viable: requires single argument<br>
        '__in', but 4 arguments were provided<br>
          explicit constexpr tuple(tuple<_UElements...>&& __in)<br>
                             ^<br>
  /usr/bin/../lib/gcc/x86_64-linux-gnu/6.1.1/../../../../include/c++/6.1.1/tuple:721:2: note:<br>
        candidate constructor template not viable: requires 6 arguments, but 4<br>
        were provided<br>
          tuple(allocator_arg_t __tag, const _Alloc& __a,<br>
          ^<br>
  /usr/bin/../lib/gcc/x86_64-linux-gnu/6.1.1/../../../../include/c++/6.1.1/tuple:732:11: note:<br>
        candidate constructor template not viable: requires 6 arguments, but 4<br>
        were provided<br>
          explicit tuple(allocator_arg_t __tag, const _Alloc& __a,<br>
                   ^<br>
  /usr/bin/../lib/gcc/x86_64-linux-gnu/6.1.1/../../../../include/c++/6.1.1/tuple:711:2: note:<br>
        candidate constructor template not viable: requires 2 arguments, but 4<br>
        were provided<br>
          tuple(allocator_arg_t __tag, const _Alloc& __a)<br>
          ^<br>
  /usr/bin/../lib/gcc/x86_64-linux-gnu/6.1.1/../../../../include/c++/6.1.1/tuple:759:2: note:<br>
        candidate constructor template not viable: requires 3 arguments, but 4<br>
        were provided<br>
          tuple(allocator_arg_t __tag, const _Alloc& __a, const tuple& __in)<br>
          ^<br>
  /usr/bin/../lib/gcc/x86_64-linux-gnu/6.1.1/../../../../include/c++/6.1.1/tuple:763:2: note:<br>
        candidate constructor template not viable: requires 3 arguments, but 4<br>
        were provided<br>
          tuple(allocator_arg_t __tag, const _Alloc& __a, tuple&& __in)<br>
          ^<br>
  /usr/bin/../lib/gcc/x86_64-linux-gnu/6.1.1/../../../../include/c++/6.1.1/tuple:772:2: note:<br>
        candidate constructor template not viable: requires 3 arguments, but 4<br>
        were provided<br>
          tuple(allocator_arg_t __tag, const _Alloc& __a,<br>
          ^<br>
  /usr/bin/../lib/gcc/x86_64-linux-gnu/6.1.1/../../../../include/c++/6.1.1/tuple:784:11: note:<br>
        candidate constructor template not viable: requires 3 arguments, but 4<br>
        were provided<br>
          explicit tuple(allocator_arg_t __tag, const _Alloc& __a,<br>
                   ^<br>
  /usr/bin/../lib/gcc/x86_64-linux-gnu/6.1.1/../../../../include/c++/6.1.1/tuple:796:2: note:<br>
        candidate constructor template not viable: requires 3 arguments, but 4<br>
        were provided<br>
          tuple(allocator_arg_t __tag, const _Alloc& __a,<br>
          ^<br>
  /usr/bin/../lib/gcc/x86_64-linux-gnu/6.1.1/../../../../include/c++/6.1.1/tuple:808:11: note:<br>
        candidate constructor template not viable: requires 3 arguments, but 4<br>
        were provided<br>
          explicit tuple(allocator_arg_t __tag, const _Alloc& __a,<br>
                   ^<br>
  /usr/bin/../lib/gcc/x86_64-linux-gnu/6.1.1/../../../../include/c++/6.1.1/tuple:654:17: note:<br>
        candidate constructor not viable: requires 1 argument, but 4 were provided<br>
        constexpr tuple(tuple&&) = default;<br>
                  ^<br>
  /usr/bin/../lib/gcc/x86_64-linux-gnu/6.1.1/../../../../include/c++/6.1.1/tuple:652:17: note:<br>
        candidate constructor not viable: requires 1 argument, but 4 were provided<br>
        constexpr tuple(const tuple&) = default;<br>
                  ^<br>
  /usr/bin/../lib/gcc/x86_64-linux-gnu/6.1.1/../../../../include/c++/6.1.1/tuple:1400:14: error:<br>
        no matching constructor for initialization of 'tuple<llvm::LexicalScope<br>
        *&&, const llvm::DILocalScope *&&, const llvm::DILocation *&&, bool &&>'<br>
      { return tuple<_Elements&&...>(std::forward<_Elements>(__args)...); }<br>
               ^                     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~<br>
  ../../lib/CodeGen/LexicalScopes.cpp:186:43: note: in instantiation of function<br>
        template specialization 'std::forward_as_tuple<llvm::LexicalScope *&,<br>
        const llvm::DILocalScope *&, const llvm::DILocation *&, bool>' requested<br>
        here<br>
                                       std::forward_as_tuple(Parent, Scope,<br>
                                            ^<br>
  /usr/bin/../lib/gcc/x86_64-linux-gnu/6.1.1/../../../../include/c++/6.1.1/tuple:600:18: note:<br>
        candidate template ignored: disabled by 'enable_if' [with _Dummy = void]<br>
                   _TCC<_Dummy>::template<br>
                   ^<br>
  /usr/bin/../lib/gcc/x86_64-linux-gnu/6.1.1/../../../../include/c++/6.1.1/tuple:611:18: note:<br>
        candidate template ignored: disabled by 'enable_if' [with _Dummy = void]<br>
                   _TCC<_Dummy>::template<br>
                   ^<br>
  /usr/bin/../lib/gcc/x86_64-linux-gnu/6.1.1/../../../../include/c++/6.1.1/tuple:628:5: note:<br>
        candidate template ignored: disabled by 'enable_if' [with _UElements =<br>
        <llvm::LexicalScope *&, const llvm::DILocalScope *&, const<br>
        llvm::DILocation *&, bool>]<br>
                    _TC<sizeof...(_UElements) == 1, _Elements...>::template<br>
                    ^<br>
  /usr/bin/../lib/gcc/x86_64-linux-gnu/6.1.1/../../../../include/c++/6.1.1/tuple:641:5: note:<br>
        candidate template ignored: disabled by 'enable_if' [with _UElements =<br>
        <llvm::LexicalScope *&, const llvm::DILocalScope *&, const<br>
        llvm::DILocation *&, bool>]<br>
                    _TC<sizeof...(_UElements) == 1, _Elements...>::template<br>
                    ^<br>
  /usr/bin/../lib/gcc/x86_64-linux-gnu/6.1.1/../../../../include/c++/6.1.1/tuple:737:19: note:<br>
        candidate template ignored: disabled by 'enable_if' [with _Alloc = const<br>
        llvm::DILocalScope *, _UElements = <const llvm::DILocation *&, bool>]<br>
          enable_if<_TMC<_UElements...>::template<br>
                    ^<br>
  /usr/bin/../lib/gcc/x86_64-linux-gnu/6.1.1/../../../../include/c++/6.1.1/tuple:748:19: note:<br>
        candidate template ignored: disabled by 'enable_if' [with _Alloc = const<br>
        llvm::DILocalScope *, _UElements = <const llvm::DILocation *&, bool>]<br>
          enable_if<_TMC<_UElements...>::template<br>
                    ^<br>
  /usr/bin/../lib/gcc/x86_64-linux-gnu/6.1.1/../../../../include/c++/6.1.1/tuple:579:17: note:<br>
        candidate constructor template not viable: requires 0 arguments, but 4<br>
        were provided<br>
        constexpr tuple()<br>
                  ^<br>
  /usr/bin/../lib/gcc/x86_64-linux-gnu/6.1.1/../../../../include/c++/6.1.1/tuple:589:26: note:<br>
        candidate constructor template not viable: requires 0 arguments, but 4<br>
        were provided<br>
        explicit constexpr tuple()<br>
                           ^<br>
  /usr/bin/../lib/gcc/x86_64-linux-gnu/6.1.1/../../../../include/c++/6.1.1/tuple:670:19: note:<br>
        candidate constructor template not viable: requires single argument<br>
        '__in', but 4 arguments were provided<br>
          constexpr tuple(const tuple<_UElements...>& __in)<br>
                    ^<br>
  /usr/bin/../lib/gcc/x86_64-linux-gnu/6.1.1/../../../../include/c++/6.1.1/tuple:682:28: note:<br>
        candidate constructor template not viable: requires single argument<br>
        '__in', but 4 arguments were provided<br>
          explicit constexpr tuple(const tuple<_UElements...>& __in)<br>
                             ^<br>
  /usr/bin/../lib/gcc/x86_64-linux-gnu/6.1.1/../../../../include/c++/6.1.1/tuple:694:19: note:<br>
        candidate constructor template not viable: requires single argument<br>
        '__in', but 4 arguments were provided<br>
          constexpr tuple(tuple<_UElements...>&& __in)<br>
                    ^<br>
  /usr/bin/../lib/gcc/x86_64-linux-gnu/6.1.1/../../../../include/c++/6.1.1/tuple:705:28: note:<br>
        candidate constructor template not viable: requires single argument<br>
        '__in', but 4 arguments were provided<br>
          explicit constexpr tuple(tuple<_UElements...>&& __in)<br>
                             ^<br>
  /usr/bin/../lib/gcc/x86_64-linux-gnu/6.1.1/../../../../include/c++/6.1.1/tuple:721:2: note:<br>
        candidate constructor template not viable: requires 6 arguments, but 4<br>
        were provided<br>
          tuple(allocator_arg_t __tag, const _Alloc& __a,<br>
          ^<br>
  /usr/bin/../lib/gcc/x86_64-linux-gnu/6.1.1/../../../../include/c++/6.1.1/tuple:732:11: note:<br>
        candidate constructor template not viable: requires 6 arguments, but 4<br>
        were provided<br>
          explicit tuple(allocator_arg_t __tag, const _Alloc& __a,<br>
                   ^<br>
  /usr/bin/../lib/gcc/x86_64-linux-gnu/6.1.1/../../../../include/c++/6.1.1/tuple:711:2: note:<br>
        candidate constructor template not viable: requires 2 arguments, but 4<br>
        were provided<br>
          tuple(allocator_arg_t __tag, const _Alloc& __a)<br>
          ^<br>
  /usr/bin/../lib/gcc/x86_64-linux-gnu/6.1.1/../../../../include/c++/6.1.1/tuple:759:2: note:<br>
        candidate constructor template not viable: requires 3 arguments, but 4<br>
        were provided<br>
          tuple(allocator_arg_t __tag, const _Alloc& __a, const tuple& __in)<br>
          ^<br>
  /usr/bin/../lib/gcc/x86_64-linux-gnu/6.1.1/../../../../include/c++/6.1.1/tuple:763:2: note:<br>
        candidate constructor template not viable: requires 3 arguments, but 4<br>
        were provided<br>
          tuple(allocator_arg_t __tag, const _Alloc& __a, tuple&& __in)<br>
          ^<br>
  /usr/bin/../lib/gcc/x86_64-linux-gnu/6.1.1/../../../../include/c++/6.1.1/tuple:772:2: note:<br>
        candidate constructor template not viable: requires 3 arguments, but 4<br>
        were provided<br>
          tuple(allocator_arg_t __tag, const _Alloc& __a,<br>
          ^<br>
  /usr/bin/../lib/gcc/x86_64-linux-gnu/6.1.1/../../../../include/c++/6.1.1/tuple:784:11: note:<br>
        candidate constructor template not viable: requires 3 arguments, but 4<br>
        were provided<br>
          explicit tuple(allocator_arg_t __tag, const _Alloc& __a,<br>
                   ^<br>
  /usr/bin/../lib/gcc/x86_64-linux-gnu/6.1.1/../../../../include/c++/6.1.1/tuple:796:2: note:<br>
        candidate constructor template not viable: requires 3 arguments, but 4<br>
        were provided<br>
          tuple(allocator_arg_t __tag, const _Alloc& __a,<br>
          ^<br>
  /usr/bin/../lib/gcc/x86_64-linux-gnu/6.1.1/../../../../include/c++/6.1.1/tuple:808:11: note:<br>
        candidate constructor template not viable: requires 3 arguments, but 4<br>
        were provided<br>
          explicit tuple(allocator_arg_t __tag, const _Alloc& __a,<br>
                   ^<br>
  /usr/bin/../lib/gcc/x86_64-linux-gnu/6.1.1/../../../../include/c++/6.1.1/tuple:654:17: note:<br>
        candidate constructor not viable: requires 1 argument, but 4 were provided<br>
        constexpr tuple(tuple&&) = default;<br>
                  ^<br>
  /usr/bin/../lib/gcc/x86_64-linux-gnu/6.1.1/../../../../include/c++/6.1.1/tuple:652:17: note:<br>
        candidate constructor not viable: requires 1 argument, but 4 were provided<br>
        constexpr tuple(const tuple&) = default;<br>
                  ^<br>
  ../../lib/CodeGen/LexicalScopes.cpp:208:32: error: no matching function for call<br>
        to 'forward_as_tuple'<br>
                                 std::forward_as_tuple(Parent, Scope,<br>
                                 ^~~~~~~~~~~~~~~~~~~~~<br>
  /usr/bin/../lib/gcc/x86_64-linux-gnu/6.1.1/../../../../include/c++/6.1.1/tuple:1399:5: note:<br>
        candidate template ignored: substitution failure [with _Elements =<br>
        <llvm::LexicalScope *&, const llvm::DILocalScope *&, nullptr_t, bool>]<br>
      forward_as_tuple(_Elements&&... __args) noexcept<br>
<br>
<br>
Repository:<br>
  rL LLVM<br>
<br>
<a href="https://reviews.llvm.org/D22797" rel="noreferrer" target="_blank">https://reviews.llvm.org/D22797</a><br>
<br>
<br>
<br>
</blockquote></div></div>