pike.git / lib / modules / Calendar.pmod / TimeRanges.pmod

version» Context lines:

pike.git/lib/modules/Calendar.pmod/TimeRanges.pmod:493:   //!   //! </pre>      //- internal method   //- returns [-1,0,1] for comparison between   //- (in order) begin/begin,begin/end,end/begin and end/end      // virtual, default    array(int(-1..1)) _compare(TimeRange what)    { -  if (what->is_supertimerange) +  if (objectp(what) && what->is_supertimerange)    {    array(int(-1..1)) cmp=what->_compare(this_object());       return ({-cmp[0],    -cmp[2],    -cmp[1],    -cmp[3]});    } -  error("_compare: incompatible classes %O <-> %O\n", -  object_program(this_object()),object_program(what)); +  return ({-1,-1,-1,-1}); + // error("_compare: incompatible classes %O <-> %O\n", + // object_program(this_object()),object_program(what));    }       string _describe_compare(array(int(-1..1)) c,TimeRange a,TimeRange b)    {    mapping desc=([-1:"<",0:"=",1:">"]);    return sprintf("%O start %s %O start\n"    "%O start %s %O end\n"    "%O end %s %O start\n"    "%O end %s %O end\n",    a,desc[c[0]],b,