unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
* bug#22302: 25.1.50; time-stamp ignores time-stamp-time-zone
@ 2016-01-04  0:18 Harald Hanche-Olsen
  2016-01-12  4:40 ` Glenn Morris
  0 siblings, 1 reply; 8+ messages in thread
From: Harald Hanche-Olsen @ 2016-01-04  0:18 UTC (permalink / raw)
  To: 22302

Run emacs -Q and insert this text:
Time-stamp: <>

Then do:
M-: (require 'time-stamp) RET
M-x set-variable RET time-stamp-time-zone RET "UTC" RET
M-x time-stamp

Expected result: A UTC time stamp is inserted.
Actual result: A time stamp in the local time zone is inserted.

My analysis:
time-stamp uses time-stamp-string to compute the string to insert.
And that calls:
      (format-time-string (time-stamp-string-preprocess ts-format)
                          nil time-stamp-time-zone)
However, time-stamp-string-preprocess does all the work,
leaving nothing for format-time-string to do.
And it does so without consulting time-stamp-time-zone.

Admittedly, the doc string for time-stamp (no longer?) mentions time-stamp-time-zone.
However, the variable does exist, and its doc string indicates that it will be used by time-stamp.

– Harald

In GNU Emacs 25.1.50.1 (x86_64-apple-darwin15.2.0, NS appkit-1404.34 Version 10.11.2 (Build 15C50))
 of 2015-12-17
Repository revision: 23b5c22703eeee7b4fe6608ce12ffe3b87794933
Windowing system distributor 'Apple', version 10.3.1404
Configured using:
 'configure --with-ns'

Configured features:
RSVG IMAGEMAGICK NOTIFY ACL GNUTLS LIBXML2 ZLIB TOOLKIT_SCROLL_BARS NS

Important settings:
  value of $LC_CTYPE: en_US.UTF-8
  locale-coding-system: utf-8-unix



^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2016-01-13 15:47 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-01-04  0:18 bug#22302: 25.1.50; time-stamp ignores time-stamp-time-zone Harald Hanche-Olsen
2016-01-12  4:40 ` Glenn Morris
2016-01-12 17:14   ` Paul Eggert
2016-01-12 17:47     ` Glenn Morris
2016-01-12 20:19       ` Paul Eggert
2016-01-12 20:51         ` Eli Zaretskii
2016-01-12 21:29           ` Paul Eggert
2016-01-13 15:47             ` Eli Zaretskii

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).