| OLD | NEW | 
|---|
| 1 // Copyright 2013 the V8 project authors. All rights reserved. | 1 // Copyright 2013 the V8 project authors. All rights reserved. | 
| 2 // Redistribution and use in source and binary forms, with or without | 2 // Redistribution and use in source and binary forms, with or without | 
| 3 // modification, are permitted provided that the following conditions are | 3 // modification, are permitted provided that the following conditions are | 
| 4 // met: | 4 // met: | 
| 5 // | 5 // | 
| 6 //     * Redistributions of source code must retain the above copyright | 6 //     * Redistributions of source code must retain the above copyright | 
| 7 //       notice, this list of conditions and the following disclaimer. | 7 //       notice, this list of conditions and the following disclaimer. | 
| 8 //     * Redistributions in binary form must reproduce the above | 8 //     * Redistributions in binary form must reproduce the above | 
| 9 //       copyright notice, this list of conditions and the following | 9 //       copyright notice, this list of conditions and the following | 
| 10 //       disclaimer in the documentation and/or other materials provided | 10 //       disclaimer in the documentation and/or other materials provided | 
| (...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
| 43 #define ICU_UTIL_DATA_STATIC 2 | 43 #define ICU_UTIL_DATA_STATIC 2 | 
| 44 | 44 | 
| 45 #define ICU_UTIL_DATA_SYMBOL "icudt" U_ICU_VERSION_SHORT "_dat" | 45 #define ICU_UTIL_DATA_SYMBOL "icudt" U_ICU_VERSION_SHORT "_dat" | 
| 46 #define ICU_UTIL_DATA_SHARED_MODULE_NAME "icudt.dll" | 46 #define ICU_UTIL_DATA_SHARED_MODULE_NAME "icudt.dll" | 
| 47 #endif | 47 #endif | 
| 48 | 48 | 
| 49 namespace v8 { | 49 namespace v8 { | 
| 50 | 50 | 
| 51 namespace internal { | 51 namespace internal { | 
| 52 | 52 | 
| 53 #if ICU_UTIL_DATA_IMPL == ICU_UTIL_DATA_FILE | 53 #if defined(V8_I18N_SUPPORT) && (ICU_UTIL_DATA_IMPL == ICU_UTIL_DATA_FILE) | 
| 54 namespace { | 54 namespace { | 
| 55 char* g_icu_data_ptr = NULL; | 55 char* g_icu_data_ptr = NULL; | 
| 56 | 56 | 
| 57 void free_icu_data_ptr() { | 57 void free_icu_data_ptr() { | 
| 58   delete[] g_icu_data_ptr; | 58   delete[] g_icu_data_ptr; | 
| 59 } | 59 } | 
| 60 | 60 | 
| 61 }  // namespace | 61 }  // namespace | 
| 62 #endif | 62 #endif | 
| 63 | 63 | 
| (...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
| 103   atexit(free_icu_data_ptr); | 103   atexit(free_icu_data_ptr); | 
| 104 | 104 | 
| 105   UErrorCode err = U_ZERO_ERROR; | 105   UErrorCode err = U_ZERO_ERROR; | 
| 106   udata_setCommonData(reinterpret_cast<void*>(g_icu_data_ptr), &err); | 106   udata_setCommonData(reinterpret_cast<void*>(g_icu_data_ptr), &err); | 
| 107   return err == U_ZERO_ERROR; | 107   return err == U_ZERO_ERROR; | 
| 108 #endif | 108 #endif | 
| 109 #endif | 109 #endif | 
| 110 } | 110 } | 
| 111 | 111 | 
| 112 } }  // namespace v8::internal | 112 } }  // namespace v8::internal | 
| OLD | NEW | 
|---|