[libcxx-commits] [PATCH] D93414: [libc++] Adds a make_string test helper function.

Mark de Wever via Phabricator via libcxx-commits libcxx-commits at lists.llvm.org
Thu Jan 28 09:56:57 PST 2021


Mordante added a comment.

In D93414#2526120 <https://reviews.llvm.org/D93414#2526120>, @mstorsjo wrote:

> Not entirely sure what that'd refer to - maybe there's some similarity to https://reviews.llvm.org/D90222#change-3lQgyuTryhdf - with the MultiStringType class that I modified for similar cases (with some char types being optionally available).

Yes it seems `MultiStringType` does something similar. I've to see how well it fits in my unit tests. Thanks for the hint!



================
Comment at: libcxx/test/support/make_string.h:25
+// facilities.
+_LIBCPP_SUPPRESS_DEPRECATED_PUSH
+// Helper function to convert a const char* string to a basic_string<CharT>.
----------------
ldionne wrote:
> That is not going to work when the test suite is run against non-libc++. Can we replace by something that doesn't depend on libc++?
I had a look and `test/std/depr/depr.c.headers/stdio_h.pass.cpp` uses
```
#if defined(__GNUC__) || defined(__clang__)
#pragma GCC diagnostic ignored "-Wformat-zero-length"
#pragma GCC diagnostic ignored "-Wdeprecated-declarations" // for tmpnam
#endif
```

But I'll first have a look at `MultiStringType`. If that suits my needs this revision seems obsolete.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D93414



More information about the libcxx-commits mailing list