Kevin Cernekee [off-list ref] writes:
One might reasonably expect a function named parse_date() to be used
for something along these lines:
$unix_time_t = parse_date("2011-03-19");
But instead, gitweb's parse_date works more like:
&parse_date(1300505805) = {
'hour' => 3,
'minute' => 36,
...
'rfc2822' => 'Sat, 19 Mar 2011 03:36:45 +0000',
...
}
Rename the function to improve clarity. No change to functionality.
Except for a small detail that the function also takes the "-0800"
timezone string, I think this is a good change.
The word "parse" makes the readers expect that its input is something
"format" would have produced for use by others (often humans, but there
are functions that parse xml ;-).