GNU bug report logs - #32252
[PATCH] %o and %x now format signed numbers

Previous Next

Package: emacs;

Reported by: Paul Eggert <eggert <at> cs.ucla.edu>

Date: Mon, 23 Jul 2018 19:14:02 UTC

Severity: normal

Tags: patch

Done: Paul Eggert <eggert <at> cs.ucla.edu>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: Helmut Eller <eller.helmut <at> gmail.com>
To: 32252 <at> debbugs.gnu.org
Subject: bug#32252: [PATCH] %o and %x now format signed numbers
Date: Mon, 23 Jul 2018 21:48:06 +0200
>  Replace the specification with the base-eight representation of an
> -unsigned integer.  The object can also be a nonnegative floating-point
> +integer.  The object can also be a floating-point
>  number that is formatted as an integer, dropping any fraction, if the
>  integer does not exceed machine limits.

Why breaking longstanding behavior instead of introducing this with a
different format specifier.  Like %a.

> +  DEFVAR_BOOL ("binary-as-unsigned",
> +	       binary_as_unsigned,
> +	       doc: /* Non-nil means `format' %x and %o treat numbers as unsigned.
 
This is the same crap as text-quoting-style.  Nil should mean treat
numbers in the tradtional way.

Helmut





This bug report was last modified 2 years and 322 days ago.

Previous Next


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