Status: New Owner: ---- New issue 180 by [email protected]: toLocaleDateString and toLocaleTimeString do not honor the current locale http://code.google.com/p/v8/issues/detail?id=180
This is spun off issue 135, which was , in turn, spun off Chromium bug ( http://crbug.com/3607). Currently, the formats used in toLocaleDateString and toLocaleTimeString are hard-coded, but they should be locale-dependent. I haven't looked up the ECMA standard to figure out which locale to use: 1. the UI locale (if embedded inside a brower), 2. the platform locale or platform date/time settting 3. the locale corresponding to the language of a referring document I guess none of JS engines inside a browser does 3. In Firefox, it's #1 and I think V8 inside a Chrome should do the same. As for how to format date/time in a locale-dependent manner, I scribbled some thoughts below: Would it be possible for V8 to delegate the date/time formatting to "its embedder"? In case of V8 inside a Chrome, it'd be Chrome. Otherwise, V8 needs to implement its own date/time formatting that honors the locale. Alternatively, can V8 be built to depend on ICU conditionally? For instance, when built to be used with Chrome, add ICU dependency. -- You received this message because you are listed in the owner or CC fields of this issue, or because you starred this issue. You may adjust your issue notification preferences at: http://code.google.com/hosting/settings --~--~---------~--~----~------------~-------~--~----~ v8-dev mailing list [email protected] http://groups.google.com/group/v8-dev -~----------~----~----~----~------~----~------~--~---
