[llvm-bugs] [Bug 25857] New: Clang hangs in template instantiation after diagnosing C++11 narrowing in NTTP.
llvm-bugs at lists.llvm.org
Wed Dec 16 14:54:29 PST 2015
Bug ID: 25857
Summary: Clang hangs in template instantiation after diagnosing
C++11 narrowing in NTTP.
Assignee: unassignedclangbugs at nondot.org
Reporter: eric at efcs.ca
CC: dgregor at apple.com, llvm-bugs at lists.llvm.org
Created attachment 15474
The attached reproducer causes clang to hang after in instantiates the `__make`
template with `-3`. Clang will emit a C++11 narrowing error before silently
hanging. My guess is that clang trys to instantiate the base class of
`__parity` with the converted value 4294967293.
metaprogramming often uses an integer NTTP to control the number of
instantiations. If clang instantiates a template with a narrowed NTTP it could
be in for a long ride.
I would be willing to work on a fix if somebody could offer direction on the
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the llvm-bugs