all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Eli Zaretskii <eliz@gnu.org>
To: Gabriel <gabriel376@hotmail.com>, Karl Fogel <kfogel@red-bean.com>
Cc: 59580@debbugs.gnu.org
Subject: bug#59580: 29.0.50; [PATCH] Add new choices to bookmark-sort-flag
Date: Thu, 01 Dec 2022 10:23:41 +0200	[thread overview]
Message-ID: <83bkonilbm.fsf@gnu.org> (raw)
In-Reply-To: <SJ0PR06MB8609C2D89667AC0EBADE93E48B0E9@SJ0PR06MB8609.namprd06.prod.outlook.com> (message from Gabriel on Fri, 25 Nov 2022 15:26:49 -0300)

> From: Gabriel <gabriel376@hotmail.com>
> Date: Fri, 25 Nov 2022 15:26:49 -0300
> 
> Add new choices 'type and 'file to `bookmark-sort-flag'.  See [1].
> 
> Notes:
> 
> 1) It feels strange to have value t meaning 'name and value nil meaning
> 'creation-time, but it's better to not change how things have been
> working for many years.  A more flexible approach could offer a custom
> function as a choice of `bookmark-sort-flag'.
> 
> 2) I took the liberty to update some comments and docstrings, please
> review.
> 
> 3) I took the liberty to remove some code in `bookmark-bmenu-mode' that
> seems to be unnecessary, please review.  Everything seems to be working
> as expected according to my tests.  I can also write some tests.
> 
> 4) Used `string-collate-lessp' in `bookmark-maybe-sort-alist' to match
> `bookmark-bmenu--*-predicate' functions.

Is it really a good idea to use string-collate-lessp here?  Its effect
depends on the underlying OS and the user's locale, so it could produce
different and sometimes surprising results.  Why isn't string-lessp
sufficient?  IMO, at the very least, the fact that the sorting is
locale-dependent should be prominently stated in the doc string.  Also, see
the notes in the string-collate-lessp's doc string about MS-Windows, and
maybe do what it suggests (if we decide to keep string-collate-lessp here).

Karl, any comments?

Thanks.





  reply	other threads:[~2022-12-01  8:23 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-11-25 18:26 bug#59580: 29.0.50; [PATCH] Add new choices to bookmark-sort-flag Gabriel
2022-12-01  8:23 ` Eli Zaretskii [this message]
2022-12-19 21:00   ` bug#59580: and bug#59581 Karl Fogel
2023-12-18 23:26   ` bug#59580: 29.0.50; [PATCH] Add new choices to bookmark-sort-flag Karl Fogel
2023-12-19  0:44     ` Drew Adams
2023-12-19 12:25     ` Eli Zaretskii
2023-12-19 18:59       ` Karl Fogel

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=83bkonilbm.fsf@gnu.org \
    --to=eliz@gnu.org \
    --cc=59580@debbugs.gnu.org \
    --cc=gabriel376@hotmail.com \
    --cc=kfogel@red-bean.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

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

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.