From: Jonghyun Park Date: Mon, 5 Dec 2016 07:35:52 +0000 (+0900) Subject: [x86/Linux] Fix dangling DoubleToNumber and NumberToDouble (dotnet/coreclr#8446) X-Git-Tag: submit/tizen/20210909.063632~11030^2~8734 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=d01e1646a6af2eda0d8cabf5c0f619eb72f28105;p=platform%2Fupstream%2Fdotnet%2Fruntime.git [x86/Linux] Fix dangling DoubleToNumber and NumberToDouble (dotnet/coreclr#8446) This commit enables portable DoubleToNumber and NumberToDouble for x86/Linux. Commit migrated from https://github.com/dotnet/coreclr/commit/933073140a0a7ca1f83084943e7516015f7e2ae8 --- diff --git a/src/coreclr/src/classlibnative/bcltype/number.cpp b/src/coreclr/src/classlibnative/bcltype/number.cpp index 349bffb..6ca24d8 100644 --- a/src/coreclr/src/classlibnative/bcltype/number.cpp +++ b/src/coreclr/src/classlibnative/bcltype/number.cpp @@ -82,7 +82,7 @@ static const char* const negNumberFormats[] = { static const char posNumberFormat[] = "#"; -#if defined(_TARGET_X86_) +#if defined(_TARGET_X86_) && !defined(FEATURE_PAL) extern "C" void _cdecl /*__stdcall*/ DoubleToNumber(double value, int precision, NUMBER* number); extern "C" void _cdecl /*__stdcall*/ NumberToDouble(NUMBER* number, double* value); @@ -132,7 +132,7 @@ unsigned int Int64DivMod1E9(unsigned __int64* value) #pragma warning(default:4035) -#else // !(defined(_TARGET_X86_) +#else // _TARGET_X86_ && !FEATURE_PAL #pragma warning(disable:4273) extern "C" char* __cdecl _ecvt(double, int, int*, int*); @@ -607,7 +607,7 @@ unsigned int Int64DivMod1E9(unsigned __int64* value) -#endif // !(defined(_TARGET_X86_) +#endif // _TARGET_X86_ && !FEATURE_PAL #if defined(_MSC_VER) && defined(_TARGET_X86_) #pragma optimize("y", on) // Small critical routines, don't put in EBP frame