Re: Data::Juxtapose 0.01 [Re: patch: DateTime::TimeZone PP redundant structures]
The basic format seems good. I'm not sure about using weak_ref, though -- what if an object or structure falls out of scope, yet there's still a key in the data registry? If another ref comes along whose fingerprint matches that key, does it end up getting replaced with undef ? (I'm kind of sleepy at the moment, so I could be misreading the code). Also, as originally implemented in the context of DateTime::TimeZone, I was using class structures and class methods. You've moved it into object mode, which is fine, but I'm curious as to how you utilize the shared object. I'm assuming it's a single object in the DT::TZ base class? Cheers, Matt
Re: Data::Juxtapose 0.01 [Re: patch: DateTime::TimeZone PP redundant structures]
The basic format seems good. I'm not sure about using weak_ref, though -- what if an object or structure falls out of scope, yet there's still a key in the data registry? If another ref comes along whose fingerprint matches that key, does it end up getting replaced with undef ? (I'm kind of sleepy at the moment, so I could be misreading the code). I had a reason why I did that, but I can't seem to come up with a good reason now. Hmm. I suppose it won't hurt to *not* have it, I guess I can just remove it. Also, as originally implemented in the context of DateTime::TimeZone, I was using class structures and class methods. You've moved it into object mode, which is fine, but I'm curious as to how you utilize the shared object. I'm assuming it's a single object in the DT::TZ base class? Yeah, that's what I was planning to do. just hold a class variable that points to a D::J object. --d
Data::Juxtapose 0.01 [Re: patch: DateTime::TimeZone PP redundant structures]
Here's the repackaged Data-Juxtapose. I added the use of Scalar::Util (if available) just in case. http://www.wafu.ne.jp/~daisuke/Data-Juxtapose-0.01.tar.gz Let me know if there are any problems. If I don't hear anything, I'll probably upload it to CPAN tomorrow. --d