Re: Data::Juxtapose 0.01 [Re: patch: DateTime::TimeZone PP redundant structures]

2005-07-19 Thread Matt Sisk
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]

2005-07-19 Thread Daisuke Maki

 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]

2005-07-18 Thread Daisuke Maki
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


Re: patch: DateTime::TimeZone PP redundant structures

2005-07-16 Thread Matt Sisk
Daisuke Maki wrote:

I like this...  but I'd like to generalize this juxtapose thing into a
separate package and release it, if it's okay with you guys (especially
Matt)?
  


That's fine with me. How about Data::Juxtapose ? You'd probably want to
design it so that you can plug in different fingerprinting methods (as
opposed to limiting it to md5_hex(Dumper()) ).

Matt


Re: patch: DateTime::TimeZone PP redundant structures

2005-07-15 Thread Daisuke Maki
Matt, Dave,

I like this...  but I'd like to generalize this juxtapose thing into a
separate package and release it, if it's okay with you guys (especially
Matt)?

Something as simple as this:

   my $j = Juxtapose-new;
   @data = $j-juxtapose(@data);

If ok, do you guys have any suggestions for the name of the module?

Meanwhile I did a massive update of the XS code, so I need to integrate
all that with this. whoof.

--d