Skip to content

Commit 16a04e0

Browse files
committed
Remove duplicate definitions, fix callconv build failure. Disable warning on GCC that catches more cases than Clang, at least for now
1 parent 108f83d commit 16a04e0

File tree

3 files changed

+2
-11
lines changed

3 files changed

+2
-11
lines changed

eng/native/configurecompiler.cmake

-1
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,6 @@ if (CLR_CMAKE_HOST_UNIX)
2929
add_compile_options(-Wno-null-arithmetic)
3030
add_compile_options(-glldb)
3131
else()
32-
add_compile_options($<$<COMPILE_LANGUAGE:CXX>:-Werror=conversion-null>)
3332
add_compile_options(-g)
3433
endif()
3534
endif()

src/coreclr/pal/inc/pal.h

+1-9
Original file line numberDiff line numberDiff line change
@@ -3882,21 +3882,13 @@ PAL_GetCurrentThreadAffinitySet(SIZE_T size, UINT_PTR* data);
38823882
/* For backwards compatibility */
38833883
#define _WConst_return _CONST_RETURN
38843884

3885-
/* Locale categories */
3886-
#define LC_ALL 0
3887-
#define LC_COLLATE 1
3888-
#define LC_CTYPE 2
3889-
#define LC_MONETARY 3
3890-
#define LC_NUMERIC 4
3891-
#define LC_TIME 5
3892-
38933885
/* _TRUNCATE */
38943886
#if !defined(_TRUNCATE)
38953887
#define _TRUNCATE ((size_t)-1)
38963888
#endif
38973889

38983890
// errno_t is only defined when the Secure CRT Extensions library is available (which no standard library that we build with implements anyway)
3899-
typedef error_t errno_t;
3891+
typedef int errno_t;
39003892

39013893
PALIMPORT DLLEXPORT errno_t __cdecl memcpy_s(void *, size_t, const void *, size_t) THROW_DECL;
39023894
PALIMPORT errno_t __cdecl memmove_s(void *, size_t, const void *, size_t);

src/coreclr/utilcode/clrconfig.cpp

+1-1
Original file line numberDiff line numberDiff line change
@@ -202,7 +202,7 @@ namespace
202202
SString nameToConvert(name);
203203

204204
#ifdef HOST_WINDOWS
205-
CLRConfigNoCache nonCache = CLRConfigNoCache::Get(nameToConvert.GetUTF8(), noPrefix, &getenv);
205+
CLRConfigNoCache nonCache = CLRConfigNoCache::Get(nameToConvert.GetUTF8(), noPrefix);
206206
#else
207207
CLRConfigNoCache nonCache = CLRConfigNoCache::Get(nameToConvert.GetUTF8(), noPrefix, &PAL_getenv);
208208
#endif

0 commit comments

Comments
 (0)