On Fri, 11 Jun 2004, Matt Sisk wrote: > Quoting Dave Rolsky <[EMAIL PROTECTED]>: > > > With DateTime::Span: > > > > > > $mid_point = > > > $span->start->add_duration( > > > seconds => $span->duration->seconds / 2 > > > ); > > > > > > With DateTime: > > > > > > $mid_point = > > > $start->add_duration( > > > seconds => $end->subtract_datetime_absolute( > > > $start > > > )->seconds / 2 > > > ); > > > > Oh, duh! Why didn't I think of that. That's nice & simple. > > If the operator overloads did that sort of thing behind the scene (and yes, with > spans also), then it would be nicer and simpler. :)
Uh, exactly what operator would you overload for DateTime? I certainly don't see and obvious candidate. -dave /*======================= House Absolute Consulting www.houseabsolute.com =======================*/
