https://gcc.gnu.org/bugzilla/show_bug.cgi?id=51385
--- Comment #4 from Paolo Carlini paolo.carlini at oracle dot com ---
This is fixed in 4.9.0, I'm adding the testcase and closing the bug.
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=51385
--- Comment #5 from paolo at gcc dot gnu.org paolo at gcc dot gnu.org ---
Author: paolo
Date: Mon Sep 29 09:06:31 2014
New Revision: 215680
URL: https://gcc.gnu.org/viewcvs?rev=215680root=gccview=rev
Log:
2014-09-29 Paolo Carlini
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=51385
Paolo Carlini paolo.carlini at oracle dot com changed:
What|Removed |Added
Status|NEW |RESOLVED
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=51385
--- Comment #1 from Jonathan Wakely redi at gcc dot gnu.org 2011-12-02
10:36:14 UTC ---
Here's a version which isn't a compile-time-hog but demonstrates the
unnecessary instantiation with a static_assert (so needs -std=c++11)
template unsigned
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=51385
Paolo Carlini paolo.carlini at oracle dot com changed:
What|Removed |Added
Status|UNCONFIRMED |NEW
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=51385
--- Comment #3 from Jonathan Wakely redi at gcc dot gnu.org 2011-12-02
10:47:45 UTC ---
Interestingly G++ is happy to not instantiate the template when it's not
possible to, i.e. making this change and defining -DINCOMPLETE allows it to
compile: