This page is a snapshot from the LWG issues list, see theLibrary Active Issues List for more information and the meaning ofResolved status.
is_constructible<int*,void*> reports trueSection: 21.3.6.4[meta.unary.prop]Status:ResolvedSubmitter: Peter DimovOpened: 2009-11-07Last modified: 2016-01-28
Priority:Not Prioritized
View otheractive issues in [meta.unary.prop].
View all otherissues in [meta.unary.prop].
View all issues withResolved status.
Discussion:
The specification ofis_constructible<T,Args...> inN3000uses
static_cast<T>(create<Args>()...)
for the one-argument case, butstatic_cast also permitsunwanted conversions such asvoid* toT* andBase* toDerived*.
[Post-Rapperswil:]
Moved to
NAD EditorialResolved, this issue is addressed by papern3047
Proposed resolution:
Change 21.3.6.4[meta.unary.prop], p6:
the predicate condition for a template specialization
is_constructible<T, Args>shall be satisfied, if and onlyif the followingexpressionCEvariabledefinition would be well-formed:
if
sizeof...(Args) ==01, the expression:static_cast<T>(create<Args>()...)T t;otherwise
the expression:T t(create<Args>()...);