GNU bug report logs - #641
format-time-string %Z does not work, starting with Emacs 22.2

Previous Next

Packages: emacs, w32;

Reported by: "Drew Adams" <drew.adams <at> oracle.com>

Date: Fri, 1 Aug 2008 16:55:06 UTC

Severity: wishlist

Merged with 9794

Found in versions 22.2, 23.0.60, 24.0.90

Done: Eli Zaretskii <eliz <at> gnu.org>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: help-debbugs <at> gnu.org (GNU bug Tracking System)
To: "Drew Adams" <drew.adams <at> oracle.com>
Subject: bug#9794: closed (Re: bug#9794: 24.0.90; `format-time-string' no
 good for %Z)
Date: Sat, 22 Oct 2011 09:24:02 +0000
[Message part 1 (text/plain, inline)]
Your bug report

#641: 24.0.90; `format-time-string' no good for %Z

which was filed against the emacs,w32 package, has been closed.

The explanation is attached below, along with your original report.
If you require more details, please reply to 9794 <at> debbugs.gnu.org.

-- 
641: http://debbugs.gnu.org/cgi/bugreport.cgi?bug=641
GNU Bug Tracking System
Contact help-debbugs <at> gnu.org with problems
[Message part 2 (message/rfc822, inline)]
From: Eli Zaretskii <eliz <at> gnu.org>
To: Jason Rumney <jasonr <at> gnu.org>
Cc: eggert <at> cs.ucla.edu, 641-done <at> debbugs.gnu.org, drew.adams <at> oracle.com,
	9794-done <at> debbugs.gnu.org
Subject: Re: bug#9794: 24.0.90; `format-time-string' no good for %Z
Date: Sat, 22 Oct 2011 11:21:57 +0200
> From: Jason Rumney <jasonr <at> gnu.org>
> Cc: Paul Eggert <eggert <at> cs.ucla.edu>,  drew.adams <at> oracle.com,  9794 <at> debbugs.gnu.org
> Date: Fri, 21 Oct 2011 23:40:20 +0800
> 
> So Paul is probably correct - we should not worry about RFC / POSIX or
> whatever compliance for %Z.

Thanks.  So, since everybody agrees, I committed as revision 106162
the changes to nt/config.nt that make current-time-zone and the
strftime's %Z format return a non-empty string on MS-Windows.

[Message part 3 (message/rfc822, inline)]
From: "Drew Adams" <drew.adams <at> oracle.com>
To: <bug-gnu-emacs <at> gnu.org>
Subject: 24.0.90; `format-time-string' no good for %Z
Date: Tue, 18 Oct 2011 23:44:15 -0700
emacs -Q
 
M-: (format-time-string "Started: %a %b %e %T %Y (%Z)" (current-time))
 
For me that produces this:
 
"Started: Tue Oct 18 23:40:28 2011 ()"
 
The %Z doesn't work at all.  This is a regression that started in Emacs
22.  In Emacs 20 and 21 (emacs -Q) it works correctly, displaying this:
 
"Started: Tue Oct 18 23:40:28 2011 (Pacific Daylight Time)"

If Emacs 20 can pick up the name Pacific Daylight Time correctly, from wherever
it gets it, then so should Emacs 24 be able to do so.  No user config (e.g.
setting env vars) should be necessary.  (That doesn't preclude user config - the
point is that even without it %Z should DTRT.)

In GNU Emacs 24.0.90.1 (i386-mingw-nt5.1.2600)
 of 2011-10-18 on MARVIN
Windowing system distributor `Microsoft Corp.', version 5.1.2600
configured using `configure --with-gcc (4.6) --no-opt --cflags -I"C:/Program
Files (x86)/GnuWin32/include" -ID:/devel/emacs/libXpm-3.5.8/include
-ID:/devel/emacs/libXpm-3.5.8/src -ID:/devel/emacs/gnutls-2.10.5-x86/include
--ldflags -LD:/devel/emacs/gnutls-2.10.5-x86/lib'
 
Important settings:
  value of $LC_ALL: nil
  value of $LC_COLLATE: nil
  value of $LC_CTYPE: nil
  value of $LC_MESSAGES: nil
  value of $LC_MONETARY: nil
  value of $LC_NUMERIC: nil
  value of $LC_TIME: nil
  value of $LANG: ENU
  value of $XMODIFIERS: nil
  locale-coding-system: cp1252
  default enable-multibyte-characters: t
 




This bug report was last modified 13 years and 270 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.