[libcxx-commits] [PATCH] D129195: [libc++] Implement P1423R3 (char8_t backward compatibility remediation)

Nikolas Klauser via Phabricator via libcxx-commits libcxx-commits at lists.llvm.org
Mon Jul 18 17:03:25 PDT 2022


philnik added inline comments.


================
Comment at: libcxx/test/std/input.output/iostream.format/output.streams/ostream/deleted_output_functions.verify.cpp:24
+  s << wchar_t();                      // expected-error {{overload resolution selected deleted operator '<<'}}
+  s << std::declval<const wchar_t*>(); // expected-error {{overload resolution selected deleted operator '<<'}}
+#endif
----------------
Mordante wrote:
> philnik wrote:
> > Mordante wrote:
> > > Mainly curious, but will `std::declval<wchar_t*>();` be valid? I expect it will.
> > No it isn't valid. The deleted `const wchar_t*` overload is the best match.
> How do you feel about adding explicit test cases?
Sure, I don't expect `CharT*` and `const CharT*` to ever have different behaviour. I think that would be //very// surprising.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D129195/new/

https://reviews.llvm.org/D129195



More information about the libcxx-commits mailing list