-J -- On Sat, Jul 23, 2005 at 11:06:23PM -1000, Joshua Hoblitt wrote: > On Sun, Jul 24, 2005 at 02:30:54PM +0900, Daisuke Maki wrote: > > - Is there any reason why the locales are not singletons? > > None that I can think of. > > > - Can I make them singleton? > > Locale objects are cached during 'load' so that the same object may be > shared between multiple DTs. This cache gets dumped when: a new locale > is registered, an alias is added, an alias is removed. So it may very > well be a win to make DateTime::Locale objects true singletons but you > probably won't notice a difference unless your screwing around with > custom locales. > > You might want to seek Dave's opinion before putting effort into a > patch. > > > - Can I make parameters like en_language, en_territory, > > en_complete_name, et al class variables, and do away with any instance > > variables? > > That data needs to be unique per locale object.
Err, I ment to say that data needs to be unique per locale class but is this really a win if there is only one instance per class? -J --
pgpEC2J6D2VIs.pgp
Description: PGP signature
