GNU bug report logs - #59745
26.3; Rename `string-collate-lessp' to respect the convention

Previous Next

Package: emacs;

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

Date: Thu, 1 Dec 2022 16:20:02 UTC

Severity: wishlist

Tags: wontfix

Found in version 26.3

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

Bug is archived. No further changes may be made.

Full log


Message #10 received at 59745 <at> debbugs.gnu.org (full text, mbox):

From: Eli Zaretskii <eliz <at> gnu.org>
To: Drew Adams <drew.adams <at> oracle.com>
Cc: 59745 <at> debbugs.gnu.org
Subject: Re: bug#59745: 26.3;
 Rename `string-collate-lessp' to respect the convention
Date: Thu, 01 Dec 2022 18:50:21 +0200
tags 59745 wontfix
close 59745
thanks

> From: Drew Adams <drew.adams <at> oracle.com>
> Date: Thu, 1 Dec 2022 16:19:31 +0000
> 
> (elisp) `Coding Conventions' tells us:
> 
>    If the purpose of a function is to tell you whether a certain
>    condition is true or false, give the function a name that ends in
>    'p' (which stands for "predicate").  If the name is one word, add
>    just 'p'; if the name is multiple words, add '-p'.  Examples are
>    'framep' and 'frame-live-p'.
> 
> `string-collate-lessp' should, according to convention, be renamed to
> `string-collate-less-p', no?  Every such misnaming encourages others,
> as people tend to base new names on names they see for existing things.

We also have bufferp, stringp etc., so -lessp is not so bad,  especially
since it's modeled on string-lessp.

And anyway, it's too late now for renaming.

Closing.




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

Previous Next


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