ydhms_tm_diff (int year, int yday, int hour, int min, int sec,
ydhms_tm_diff (long int year, int yday, int hour, int min, int sec,
ydhms_tm_diff (int year, int yday, int hour, int min, int sec,	       const struct tm *tp){  if (!tp)    return 1;  else    {      verify (C99_integer_division, -1 / 2 == 0);      /* Compute intervening leap days correctly even if year is negative.	 Take care to avoid int overflow.  time_t overflow is OK, since	 only the low order bits of the correct time_t answer are needed.	 Don't convert to time_t until after all divisions are done, since	 time_t might be unsigned.  */      int a4 = (year >> 2) + (TM_YEAR_BASE >> 2) - ! (year & 3);      int b4 = (tp->tm_year >> 2) + (TM_YEAR_BASE >> 2) - ! (tp->tm_year & 3);      int a100 = a4 / 25 - (a4 % 25 < 0);      int b100 = b4 / 25 - (b4 % 25 < 0);      int a400 = a100 >> 2;      int b400 = b100 >> 2;      int intervening_leap_days = (a4 - b4) - (a100 - b100) + (a400 - b400);      time_t years = year - (time_t) tp->tm_year;      time_t days = (365 * years + intervening_leap_days		     + (yday - tp->tm_yday));      return (60 * (60 * (24 * days + (hour - tp->tm_hour))		    + (min - tp->tm_min))	      + (sec - tp->tm_sec));    }}