is_void<const void>

Jonathan Wakely jwakely.gcc@gmail.com
Fri Mar 23 14:23:00 GMT 2012


>From 3.9.3 [basic.type.qualifier] cv-qualified void types are distinct
from void itself, and from 20.9.4.1 [meta.unary.cat] says is_void<T>
is true if T is void, so by my reading is_void<const void> should be
false, meaning we have a bug.

Should we remove the remove_cv in the definition of std::is_void?

It could be simplified to be just:

template<typename T>
struct is_void : __is_void_helper<T>
{ };



More information about the Libstdc++ mailing list