http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48735
Summary: [C++0x][SFINAE] Hard errors with array list-construction and deleted default c'tor Product: gcc Version: 4.7.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: c++ AssignedTo: unassig...@gcc.gnu.org ReportedBy: daniel.krueg...@googlemail.com CC: ja...@redhat.com gcc 4.7.0 20110422 (experimental) in C++0x mode rejects the following code: //------------------------- template<class T, class = decltype(T{}) > char f(int); template<class> char (&f(...))[2]; struct ND { ND() = delete; }; static_assert(sizeof(f<ND[1]>(0)) != 1, "Error"); //------------------------- "error: use of deleted function ‘ND::ND()’" The code should be accepted.