[llvm-bugs] [Bug 30519] New: Compilation using std::map fails with gcc's STL 6.2.0.
via llvm-bugs
llvm-bugs at lists.llvm.org
Sun Sep 25 14:44:40 PDT 2016
https://llvm.org/bugs/show_bug.cgi?id=30519
Bug ID: 30519
Summary: Compilation using std::map fails with gcc's STL 6.2.0.
Product: clang
Version: 3.6
Hardware: PC
OS: Linux
Status: NEW
Severity: normal
Priority: P
Component: C++11
Assignee: unassignedclangbugs at nondot.org
Reporter: ruben.lapauw at cs.kuleuven.be
CC: dgregor at apple.com, llvm-bugs at lists.llvm.org
Classification: Unclassified
Created attachment 17345
--> https://llvm.org/bugs/attachment.cgi?id=17345&action=edit
Minimal unworking example
The error occurs for clang versions (tested 3.6.1 and 3.8.1) with the
gcc-toolchain (6.2.0) only when C++11 is enabled.
With gcc-toolchain version 5.4.0 or 4.8.5 the error does not occur.
Without C++11 the error does not occur, yet there is no C++11 specific header
code (that I can see).
With gcc of any version (4.8.5, 5.4.0, 6.2.0) the error does not occur.
I ran the attached file with the following commands:
clang++ --std=c++11 -c test.cpp
clang++ -c test.cpp
g++ --std=c++11 -c test.cpp
g++ -c test.cpp
The difference can be traced back to changes to the following lines:
620 // Shortcut for the cases where constructors taking _UElements...
621 // need to be constrained.
622 template<typename... _UElements> using _TMC =
623 _TC<(sizeof...(_Elements) == sizeof...(_UElements)),
624 _Elements...>;
625
626 template<typename... _UElements, typename
627 enable_if<
x 628 _TC<sizeof...(_UElements) == 1,
_Elements...>::template
x 629 _NotSameTuple<_UElements...>()
x 630 && _TMC<_UElements...>::template
x 631 _MoveConstructibleTuple<_UElements...>()
x 632 && _TMC<_UElements...>::template
x 633 _ImplicitlyMoveConvertibleTuple<_UElements...>()
x 634 && (sizeof...(_Elements) >= 1),
x 635 bool>::type=true>
636 constexpr tuple(_UElements&&... __elements)
637 : _Inherited(std::forward<_UElements>(__elements)...) { }
638
639 template<typename... _UElements, typename
640 enable_if<
x 641 _TC<sizeof...(_UElements) == 1,
_Elements...>::template
x 642 _NotSameTuple<_UElements...>()
x 643 && _TMC<_UElements...>::template
x 644 _MoveConstructibleTuple<_UElements...>()
x 645 && !_TMC<_UElements...>::template
x 646 _ImplicitlyMoveConvertibleTuple<_UElements...>()
x 647 && (sizeof...(_Elements) >= 1),
x 648 bool>::type=false>
649 explicit constexpr tuple(_UElements&&... __elements)
650 : _Inherited(std::forward<_UElements>(__elements)...) { }
--
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20160925/8a65eff5/attachment.html>
More information about the llvm-bugs
mailing list