[cfe-dev] [PATCH] Libc++ Windows fixes
Howard Hinnant
hhinnant at apple.com
Thu Oct 20 05:52:20 PDT 2011
Committed revision 142578.
Thanks!
Howard
On Oct 19, 2011, at 12:10 PM, Ruben Van Boxem wrote:
> 2011/10/17 Howard Hinnant <hhinnant at apple.com>
> Committed revision 142235.
>
> I modified the alignas support a little bit. If I messed it up, let me know.
>
> It looks okay, and compiles fine. Thanks for the continued commit support!
>
> Hi,
>
> Attached is a new patch for libc++ and msvc interoperability.
>
> I added a new MSVC only support header for <limits>, and implemented it as platform-specifically as I could/should :).
> I renamed a "__value" variable to "__value_"; "__value" is a CLR (MSVC's Managed C++) keyword, and it produces an error in non-CLR mode.
> The notable changes are at the bottom of the patch file.
>
> It gets me as far as this undecipherable error (which is in a _LIBCPP_HAS_NO_VARIADICS section, this will not change in the near future; MSVC 11.0 will not have variadic templates... grrrr):
>
> M:\Development\Source\libc++\include\type_traits(1192) : error C2516: 'std::common_type<_Tp>::type' : is not a legal base class
> with
> [
> _Tp=
> ]
> M:\Development\Source\libc++\include\type_traits(1122) : see declaration of 'std::common_type<_Tp>::type'
> with
> [
> _Tp=
> ]
> M:\Development\Source\libc++\include\type_traits(1192) : see reference to class template instantiation 'std::__is_assignable_imp<_Tp,_Arg,__formal>' being compiled
> M:\Development\Source\libc++\include\type_traits(1244) : error C2516: 'std::common_type<_Tp>::type' : is not a legal base class
> with
> [
> _Tp=
> ]
> M:\Development\Source\libc++\include\type_traits(1122) : see declaration of 'std::common_type<_Tp>::type'
> with
> [
> _Tp=
> ]
> M:\Development\Source\libc++\include\type_traits(1244) : see reference to class template instantiation 'std::__destructible_imp<_Tp,__formal>' being compiled
> M:\Development\Source\libc++\include\type_traits(2013) : error C2516: 'std::common_type<_Tp>::type' : is not a legal base class
> with
> [
> _Tp=
> ]
> M:\Development\Source\libc++\include\type_traits(1122) : see declaration of 'std::common_type<_Tp>::type'
> with
> [
> _Tp=
> ]
> M:\Development\Source\libc++\include\type_traits(2013) : see reference to class template instantiation 'std::__is_constructible0_imp<__formal,_Tp>' being compiled
> M:\Development\Source\libc++\include\type_traits(2021) : error C2516: 'std::common_type<_Tp>::type' : is not a legal base class
> with
> [
> _Tp=
> ]
> M:\Development\Source\libc++\include\type_traits(1122) : see declaration of 'std::common_type<_Tp>::type'
> with
> [
> _Tp=
> ]
> M:\Development\Source\libc++\include\type_traits(2021) : see reference to class template instantiation 'std::__is_constructible1_imp<__formal,_Tp,_A0>' being compiled
> M:\Development\Source\libc++\include\type_traits(2029) : error C2516: 'std::common_type<_Tp>::type' : is not a legal base class
> with
> [
> _Tp=
> ]
> M:\Development\Source\libc++\include\type_traits(1122) : see declaration of 'std::common_type<_Tp>::type'
> with
> [
> _Tp=
> ]
> M:\Development\Source\libc++\include\type_traits(2029) : see reference to class template instantiation 'std::__is_constructible2_imp<__formal,_Tp,_A0,_A1>' being compiled
> M:\Development\Source\libc++\include\utility(264) : error C4519: default template arguments are only allowed on a class template
> M:\Development\Source\libc++\include\utility(352) : see reference to class template instantiation 'std::pair<_T1,_T2>' being compiled
>
> There's two different errors here: C2516 and C4519. I hope these aren't insurmountable unimplemented template features. I'm sure you could shed more light on what feature or implementation detail is being relied on here. The second error does seem to be caused by the first.
>
> Comments and commits welcome!
>
> Ruben
> <msvc.patch.txt>
More information about the cfe-dev
mailing list