Sync changes from upstream repository

This commit is contained in:
Bozo the Builder
2024-06-17 02:22:39 -07:00
parent 6dce0c19e7
commit a14564cf09
27 changed files with 233 additions and 54 deletions

View File

@@ -32,7 +32,7 @@ static ON_CRT_locale_t ON_CRT_C_locale()
ON_C_locale = _create_locale(LC_ALL, "C");
#elif defined(ON_RUNTIME_APPLE)
ON_C_locale = _c_locale;
#elif defined(ON_RUNTIME_ANDROID) || defined(ON_RUNTIME_LINUX)
#elif defined(ON_RUNTIME_ANDROID) || defined(ON_RUNTIME_LINUX) || defined(ON_RUNTIME_WASM)
ON_C_locale = 0;
#else
ON_C_locale = _create_locale(category, locale);
@@ -101,7 +101,7 @@ static ON_CRT_locale_t ON_CRT_create_locale_ALL( const char * locale )
}
}
return newlocale(LC_ALL_MASK, apple_name, ON_CRT_C_locale() );
#elif defined(ON_RUNTIME_ANDROID) || defined(ON_RUNTIME_LINUX)
#elif defined(ON_RUNTIME_ANDROID) || defined(ON_RUNTIME_LINUX) || defined(ON_RUNTIME_WASM)
return 0;
#else
return _create_locale(category, locale);
@@ -1345,7 +1345,7 @@ public:
static bool Validate_sprintf_l()
{
#if defined(ON_COMPILER_CLANG) || defined(ON_COMPILER_GNU)
#if defined(ON_RUNTIME_ANDROID) || defined(ON_RUNTIME_LINUX)
#if defined(ON_RUNTIME_ANDROID) || defined(ON_RUNTIME_LINUX) || defined(ON_RUNTIME_WASM)
// Test formatted printing
char buffer[64] = { 0 };
// Testing C-runtime - do not using ON_String::FormatIntoBuffer
@@ -1370,7 +1370,7 @@ public:
static bool Validate_sprintf_s_l()
{
#if defined(ON_COMPILER_CLANG) || defined(ON_COMPILER_GNU)
#if defined(ON_RUNTIME_ANDROID) || defined(ON_RUNTIME_LINUX)
#if defined(ON_RUNTIME_ANDROID) || defined(ON_RUNTIME_LINUX) || defined(ON_RUNTIME_WASM)
// Test formatted printing
char buffer[64] = { 0 };
size_t buffer_capacity = (sizeof(buffer) / sizeof(buffer[0])) - 1;
@@ -1424,7 +1424,7 @@ public:
static bool Validate_sscanf_l()
{
#if defined(ON_COMPILER_CLANG) || defined(ON_COMPILER_GNU)
#if defined(ON_RUNTIME_ANDROID) || defined(ON_RUNTIME_LINUX)
#if defined(ON_RUNTIME_ANDROID) || defined(ON_RUNTIME_LINUX) || defined(ON_RUNTIME_WASM)
// Test formatted scanning
double a = ON_UNSET_VALUE;
// Testing C-runtime - do not using ON_String::Scan
@@ -1449,7 +1449,7 @@ public:
static bool Validate_sscanf_s_l()
{
#if defined(ON_COMPILER_CLANG) || defined(ON_COMPILER_GNU)
#if defined(ON_RUNTIME_ANDROID) || defined(ON_RUNTIME_LINUX)
#if defined(ON_RUNTIME_ANDROID) || defined(ON_RUNTIME_LINUX) || defined(ON_RUNTIME_WASM)
// Test formatted scanning
double a = ON_UNSET_VALUE;
// Testing C-runtime - do not using ON_String::Scan