Clang bugs affecting MSVC's STL (and vice versa?)

Hi Clang devs,

Now that Clang 6 has branched for release, I want to:

* Thank you for fixing many bugs that affected MSVC's STL! (These were 31944, 33235, 34942, 34970, 34988, and 35356.)

* Ask whether MSVC's STL or any other MS libraries are doing anything nonconformant, causing you headaches, that we could avoid. I recently removed the use of a non-standard extension in the STL (in-class specializations) and we're compiling the STL cleanly with Clang 5.0.0 (soon 5.0.1) -fno-ms-compatibility -fno-delayed-template-parsing, but Clang still tolerates some things in this mode (another example: include directives with incorrect casing, which we fixed a bunch of). We're making progress on removing __if_exists usage from ATL, and also note that we've reported a bunch of conformance issues to the WinSDK team which are being fixed.

* Ask whether any of the following bugs can be fixed for Clang 6 - we have product or test workarounds for them:

https://bugs.llvm.org/show_bug.cgi?id=33230 "Clang on Windows should define __STDCPP_THREADS__ to be 1"
https://bugs.llvm.org/show_bug.cgi?id=33236 "clang-cl emits bogus error: cannot decompose this type; 'std::tuple_size<const S>::value' is not a valid integral constant expression"
https://bugs.llvm.org/show_bug.cgi?id=33550 "Clang rejects deleted defaulted noexcept default constructor"
https://bugs.llvm.org/show_bug.cgi?id=35028 "Clang does not use the strictest alignas in templates"
https://bugs.llvm.org/show_bug.cgi?id=35045 "Class template argument deduction mishandles std::chrono::time_point"
https://bugs.llvm.org/show_bug.cgi?id=35165 "Consider providing string builtins for char16_t"

Thanks,
STL

It seems quite a few of those require some CWG/LWG discussion, right?

I'm taking a look at 35028 at the moment, and might do something on 35165 if my target-mv patch keeps being stuck :slight_smile:

[Keane, Erich]

It seems quite a few of those require some CWG/LWG discussion, right?

Only one.

33236 (tuple_size) is the CWG/LWG issue.

33230 (__STDCPP_THREADS__) is just a bug.

33550 (default constructor) is CWG 1778 which was voted into C++14.

35028 (alignas) is just a bug, with clear Standardese.

35045 (CTAD time_point) is also just a bug AFAICT, and GCC accepts this.

35165 (string builtins for char16_t) is a compiler builtin request.

I'm taking a look at 35028 at the moment, and might do something on 35165 if my target-mv patch keeps being stuck :slight_smile:

Thanks!

STL

[Keane, Erich]
> It seems quite a few of those require some CWG/LWG discussion, right?

Only one.

33236 (tuple_size) is the CWG/LWG issue.

33230 (__STDCPP_THREADS__) is just a bug.

Yes, but an annoying one :frowning:

33550 (default constructor) is CWG 1778 which was voted into C++14.

... and appears unimplementable :frowning:

35028 (alignas) is just a bug, with clear Standardese.

35045 (CTAD time_point) is also just a bug AFAICT, and GCC accepts this.

Both now fixed.

35165 (string builtins for char16_t) is a compiler builtin request.

> I'm taking a look at 35028 at the moment, and might do something on
35165 if my target-mv patch keeps being stuck :slight_smile:

Ugh, sorry for the duplication of effort on PR35028, Erich.

Richard, Erich: are there any patches here that need merging that I
don't know about?

Thanks,
Hans