diff options
-rw-r--r-- | sal/rtl/locale.cxx | 20 | ||||
-rw-r--r-- | sal/util/sal.map | 7 |
2 files changed, 12 insertions, 15 deletions
diff --git a/sal/rtl/locale.cxx b/sal/rtl/locale.cxx index 3fb85e1b8bb7..579538f056f3 100644 --- a/sal/rtl/locale.cxx +++ b/sal/rtl/locale.cxx @@ -47,7 +47,9 @@ static RTL_HASHTABLE* g_pLocaleTable = nullptr; static rtl_Locale* g_pDefaultLocale = nullptr; -extern "C" void rtl_hashentry_destroy(RTL_HASHENTRY* entry) +namespace { + +void rtl_hashentry_destroy(RTL_HASHENTRY* entry) { rtl_uString_release(entry->Entry->Language); rtl_uString_release(entry->Entry->Country); @@ -60,7 +62,7 @@ extern "C" void rtl_hashentry_destroy(RTL_HASHENTRY* entry) free(entry); } -extern "C" void rtl_hashtable_destroy(RTL_HASHTABLE* table) +void rtl_hashtable_destroy(RTL_HASHTABLE* table) { sal_Int32 size = 0; @@ -81,7 +83,7 @@ extern "C" void rtl_hashtable_destroy(RTL_HASHTABLE* table) free(table); } -extern "C" void rtl_hashtable_init(RTL_HASHTABLE** table, sal_Int8 sizeIndex) +void rtl_hashtable_init(RTL_HASHTABLE** table, sal_Int8 sizeIndex) { sal_Int32 nSize = RTL_HASHTABLE_SIZE[sizeIndex]; @@ -102,14 +104,14 @@ extern "C" void rtl_hashtable_init(RTL_HASHTABLE** table, sal_Int8 sizeIndex) } } -extern "C" sal_Int32 rtl_hashfunc(RTL_HASHTABLE* table, sal_Int32 key) +sal_Int32 rtl_hashfunc(RTL_HASHTABLE* table, sal_Int32 key) { return (static_cast<sal_uInt32>(key) % table->Size); } -extern "C" sal_Bool rtl_hashtable_grow(RTL_HASHTABLE** table); +bool rtl_hashtable_grow(RTL_HASHTABLE** table); -extern "C" rtl_Locale* rtl_hashtable_add(RTL_HASHTABLE** table, rtl_Locale* value) +rtl_Locale* rtl_hashtable_add(RTL_HASHTABLE** table, rtl_Locale* value) { sal_Int32 key = 0; @@ -138,7 +140,7 @@ extern "C" rtl_Locale* rtl_hashtable_add(RTL_HASHTABLE** table, rtl_Locale* valu return nullptr; } -sal_Bool rtl_hashtable_grow(RTL_HASHTABLE** table) +bool rtl_hashtable_grow(RTL_HASHTABLE** table) { RTL_HASHTABLE* pNewTable = nullptr; sal_Int32 i = 0; @@ -175,7 +177,7 @@ sal_Bool rtl_hashtable_grow(RTL_HASHTABLE** table) return true; } -extern "C" sal_Bool rtl_hashtable_find(RTL_HASHTABLE * table, sal_Int32 key, sal_Int32 hashCode, rtl_Locale** pValue) +bool rtl_hashtable_find(RTL_HASHTABLE * table, sal_Int32 key, sal_Int32 hashCode, rtl_Locale** pValue) { if (!table) return false; @@ -202,6 +204,8 @@ extern "C" sal_Bool rtl_hashtable_find(RTL_HASHTABLE * table, sal_Int32 key, sal return true; } +} + void rtl_locale_init() { OSL_ASSERT(!g_pLocaleTable); diff --git a/sal/util/sal.map b/sal/util/sal.map index 86ad07525ee6..07150ab0340d 100644 --- a/sal/util/sal.map +++ b/sal/util/sal.map @@ -196,13 +196,6 @@ UDK_3_0_0 { rtl_reallocateMemory; rtl_zeroMemory; rtl_findInMemory; - rtl_hashentry_destroy; - rtl_hashfunc; - rtl_hashtable_add; - rtl_hashtable_destroy; - rtl_hashtable_find; - rtl_hashtable_grow; - rtl_hashtable_init; rtl_locale_equals; rtl_locale_getCountry; rtl_locale_getDefault; |