[libcxx-commits] [PATCH] D150015: [libc++] Consistently enable __CORRECT_ISO_CPP_WCHAR_H_PROTO in mbstate.

Jordan Rupprecht via Phabricator via libcxx-commits libcxx-commits at lists.llvm.org
Fri May 5 19:26:43 PDT 2023


rupprecht added a comment.

I can't reproduce this outside of a modules-enabled build, and unfortunately I don't know how to write a modules test case. Anyway, here's the stderr I see:

  wchar.h:316:29: error: functions that differ only in their return type cannot be overloaded
  extern "C++" const wchar_t *wmemchr (const wchar_t *__s, wchar_t __c,
                     ~~~~~~~~~^
  wchar.h:320:17: note: previous declaration is here
  extern wchar_t *wmemchr (const wchar_t *__s, wchar_t __c, size_t __n)
         ~~~~~~~~~^

Those two definitions are the difference between `__CORRECT_ISO_CPP_WCHAR_H_PROTO` being defined vs not defined.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D150015



More information about the libcxx-commits mailing list