Skip to content

Commit

Permalink
[libcxx] Add missing _LIBCPP_FUNC_VIS on a few win32 locale functions
Browse files Browse the repository at this point in the history
These functions are called directly from the public installed
headers, and thus need to be exported in DLL builds, just like
some other functions in the same header (e.g. snprintf_l).

This fixes e.g. test/std/localization/locale.categories/category.numeric/locale.num.get/facet.num.get.members/get_float.pass.cpp
in mingw configurations.

Differential Revision: https://reviews.llvm.org/D91328
  • Loading branch information
mstorsjo committed Nov 18, 2020
1 parent 2fa38fa commit 83a0386
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions libcxx/include/support/win32/locale_win32.h
Expand Up @@ -201,8 +201,8 @@ decltype(MB_CUR_MAX) MB_CUR_MAX_L( locale_t __l );
#define strtof_l _strtof_l
#define strtold_l _strtold_l
#else
float strtof_l(const char*, char**, locale_t);
long double strtold_l(const char*, char**, locale_t);
_LIBCPP_FUNC_VIS float strtof_l(const char*, char**, locale_t);
_LIBCPP_FUNC_VIS long double strtold_l(const char*, char**, locale_t);
#endif
inline _LIBCPP_INLINE_VISIBILITY
int
Expand Down

0 comments on commit 83a0386

Please sign in to comment.