[libcxx-commits] [PATCH] D114813: [SystemZ][z/OS] ASCII/EBCDIC support with no coexistence

Louis Dionne via Phabricator via libcxx-commits libcxx-commits at lists.llvm.org
Fri Jan 14 07:48:08 PST 2022


ldionne requested changes to this revision.
ldionne added inline comments.
This revision now requires changes to proceed.


================
Comment at: libcxx/include/regex:1314
+inline _LIBCPP_INLINE_VISIBILITY
+bool is_07(unsigned char c)
+{
----------------
If you look at the surrounding code, we uglify everything with double underscores. The reason is that names starting with double underscores are reserved for the implementation, so users wouldn't be allowed to define a macro like `is_07` that would (in the status quo) break our implementation. You'll need to do that here.


================
Comment at: libcxxabi/CMakeLists.txt:272
 # Configure target flags
+add_target_flags_if_supported("-fzos-le-char-mode=ebcdic")
+
----------------
muiez wrote:
> ldionne wrote:
> > What does this flag do? Isn't it necessary only when building using EBCDIC?
> This flag ensures that our default encoding is ebcdic. In a subsequent patch, we build the ascii version as a separate library and override this flag.
I think this should be enclosed in `if (MVS)` or whatever the CMake check is, then. Otherwise, if another compiler supports that flag (I assume Clang will support that flag at some point?), we'd start using it everywhere.


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

https://reviews.llvm.org/D114813



More information about the libcxx-commits mailing list