emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: sort-lines including non ASCII


From: Richard Stallman
Subject: Re: sort-lines including non ASCII
Date: Fri, 08 Jul 2016 09:40:59 -0400

[[[ To any NSA and FBI agents reading my email: please consider    ]]]
[[[ whether defending the US Constitution against all enemies,     ]]]
[[[ foreign or domestic, requires you to follow Snowden's example. ]]]

  > Since `sort-lines' calls `sort-subr' with a fixed second and third
  > argument, I guess we can assume that the key type the predicate must
  > accept is always the same: (#1=(beg . end) . #1#).  It would be nice if
  > `sort-lines' as a function would at least accept an arbitrary predicate,
  > and we transform it to accept the correct key type and pass it to
  > `sort-subr', so that `string-collate-lessp' would work as PREDICATE
  > argument.

Could you please show a concrete example of the code you propose ought
to be accepted?  The only way that occurs to me, to transform an
arbitrary predicate, is to write a lambda expression around it which
will handle the arguments as they are actually passed.  That doesn't
require any change in Emacs.

That is a little inconvenient, and perhaps we could provide some
more convenient interface -- but what, precsely, would it be?


-- 
Dr Richard Stallman
President, Free Software Foundation (gnu.org, fsf.org)
Internet Hall-of-Famer (internethalloffame.org)
Skype: No way! See stallman.org/skype.html.




reply via email to

[Prev in Thread] Current Thread [Next in Thread]