unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
* (0 <= i && i < N) is not "backwards"
@ 2013-03-24 23:14 Paul Eggert
  2013-03-24 23:53 ` Pascal J. Bourguignon
                   ` (2 more replies)
  0 siblings, 3 replies; 13+ messages in thread
From: Paul Eggert @ 2013-03-24 23:14 UTC (permalink / raw)
  To: Andreas Schwab; +Cc: Emacs Development

Emacs trunk bzr 112126, installed with the commit log
"Reorder conditions that are written backwards",
changed a lot of Emacs code, typically to replace expressions
like "0 < i" with expressions like "i > 0".

This sort of stylistic change shouldn't be introduced without
discussion.  I often prefer "<", as it causes textual
order to reflect numeric order.  This is not just a personal
preference; it's a common style used in other GNU projects.
Removing this style en masse is not called for, particularly
in places where the code is checking for values in range.

In one or two places the change may have introduced a bug,
as "! (0 < X)" is not equivalent to "X <= 0" when
X is floating point, because of NaNs.

I suggest reverting the change and discussing it before
applying.



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

end of thread, other threads:[~2013-03-30 21:45 UTC | newest]

Thread overview: 13+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-03-24 23:14 (0 <= i && i < N) is not "backwards" Paul Eggert
2013-03-24 23:53 ` Pascal J. Bourguignon
2013-03-25 14:23   ` Stefan Monnier
2013-03-25 14:59     ` Andreas Schwab
2013-03-25  8:20 ` Eli Zaretskii
2013-03-25 14:35   ` Paul Eggert
2013-03-25 14:53     ` Eli Zaretskii
2013-03-25 14:58       ` Noah Lavine
2013-03-25 15:09         ` Eli Zaretskii
2013-03-25 15:28           ` Noah Lavine
2013-03-25 16:49       ` Paul Eggert
2013-03-25 16:59         ` Eli Zaretskii
2013-03-30 21:45 ` Jim Meyering

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).