1 new commit in XEmacs:
https://bitbucket.org/xemacs/xemacs/changeset/aa5f38ecb804/
changeset: aa5f38ecb804
user: kehoea
date: 2012-09-16 22:43:21
summary: Accept GNU's UNIVERSAL argument to #'format-time-string.
src/ChangeLog addition:
2012-09-16 Aidan Kehoe <kehoea(a)parhasard.net>
* editfns.c (Fformat_time_string):
Accept GNU's UNIVERSAL argument, which means we call gmtime()
instead of localtime(). Thanks for the report of org-mode
incompatibility, Matsl!
affected #: 2 files
diff -r 0eb4e96fd261faa9079b4b6fef400815d660883a -r
aa5f38ecb804ee655969c0f617ff5c50415ae3f7 src/ChangeLog
--- a/src/ChangeLog
+++ b/src/ChangeLog
@@ -1,3 +1,10 @@
+2012-09-16 Aidan Kehoe <kehoea(a)parhasard.net>
+
+ * editfns.c (Fformat_time_string):
+ Accept GNU's UNIVERSAL argument, which means we call gmtime()
+ instead of localtime(). Thanks for the report of org-mode
+ incompatibility, Matsl!
+
2012-09-07 Aidan Kehoe <kehoea(a)parhasard.net>
* file-coding.c:
diff -r 0eb4e96fd261faa9079b4b6fef400815d660883a -r
aa5f38ecb804ee655969c0f617ff5c50415ae3f7 src/editfns.c
--- a/src/editfns.c
+++ b/src/editfns.c
@@ -998,11 +998,13 @@
static long difftm (const struct tm *a, const struct tm *b);
-DEFUN ("format-time-string", Fformat_time_string, 1, 2, 0, /*
+DEFUN ("format-time-string", Fformat_time_string, 1, 3, 0, /*
Use FORMAT-STRING to format the time TIME.
TIME is specified as (HIGH LOW . IGNORED) or (HIGH . LOW), as from
`current-time' and `file-attributes'. If TIME is not specified it
defaults to the current time.
+The third, optional, argument UNIVERSAL, if non-nil, means describe TIME
+as Universal Time; nil means describe TIME in the local time zone.
FORMAT-STRING may contain %-sequences to substitute parts of the time.
%a is replaced by the abbreviated name of the day of week.
%A is replaced by the full name of the day of week.
@@ -1047,7 +1049,7 @@
The number of options reflects the `strftime' function.
*/
- (format_string, time_))
+ (format_string, time_, universal))
{
time_t value;
Bytecount size;
@@ -1065,7 +1067,7 @@
Extbyte *buf = alloca_extbytes (size);
Extbyte *formext;
/* make a copy of the static buffer returned by localtime() */
- struct tm tm = *localtime (&value);
+ struct tm tm = NILP (universal) ? *localtime (&value) : *gmtime (&value);
*buf = 1;
Repository URL:
https://bitbucket.org/xemacs/xemacs/
--
This is a commit notification from
bitbucket.org. You are receiving
this because you have the service enabled, addressing the recipient of
this email.
_______________________________________________
XEmacs-Patches mailing list
XEmacs-Patches(a)xemacs.org
http://lists.xemacs.org/mailman/listinfo/xemacs-patches